Monthly Archives: February 2010

This weekend I reformatted my system. I took the opportunity to give Vista a shot. So far I have been quite pleasantly surprised, considering how old my hardware is. We’ll see how it goes. In any event, I was in the middle of reinstalling all the software that I’m used to having, and when I got to Winamp, I was taken aback by the experience. Winamp suddenly does not like Cyrillic, takes up tons of CPU during playback of MP3s, and has very annoying graphical glitches. Any one of these would normally leave me with a bad aftertaste.

I wanted to see if the CPU issue would present itself in another music player, and seeing as how Windows comes with Windows Media Player, I tried that. It didn’t have the problem, so I kept listening to music with it. Then I noticed that, of course, it doesn’t work with Snarl, and I was surprised to find that no plugin with that functionality exists. I set out to see what it would take to write such a plugin, and boy is it hairy! There are a lot of ins and outs to it, and I spent approximately 5 hours Googling, reading and piecing together information just so I can set up a build environment with which I can write the plugin. I think I am basically done at this point, but I have no idea if I’ll figure out how to listen to the right events and forward them to Snarl. More to come.

Truthfully, while WMP is not a very full-featured player, and its international text support for tags is not compatible with any other player (though it does support writing non-Latin characters), it looks awesome in Vista with Aero enabled. It also has a very nice view of albums. I don’t think I’ll be able to handle it for long, but I’ll keep it around for a while. Let’s try the full Vista experience, I say.

Here's what I meant when I said I liked the album view.

Some time ago I had this idea on the subject of cryptography. Imagine a spy behind enemy lines who uses some sort of cipher to encrypt the data on his computer. Now, of course, if that computer was to fall into the wrong hands, we can reasonably assume that the data will remain safe if the password is not ‘Love’, ‘Secret’, ‘Sex’ or ‘God’,  like in the movie Hackers – at least that’s what cryptographers will have us believe. However, in the event that the spy is captured along with the computer, the captors would not even bother to do a brute-force attack. They will simply beat the living soul out of the poor spy until he or she turns over the password. I don’t think people stand up well under torture, no matter their training.

So here’s where my idea comes in. What if a single contiguous file representing a virtual hard disk volume could be encrypted in such a way as to allow two passwords to decrypt it? One password would reveal the true data, and the other would reveal harmless or, better yet, misleading information. If this were possible, the spy would feel free to reveal the dummy password somewhere into the 24th hour of torture (so that he or she doesn’t arouse suspicion). I don’t know if this makes good tactical sense, but it is certainly a clever way to get off the hook and buy yourself some time.

When I came up with this, I had no idea if it was technically possible. It is crucial that such double encryption be undetectable and that the knowledge of the dummy password is not enough to give you access to the true data. Well, it turns out that not only is this scheme possible, but it has already been implemented. I just found out about it. You can get your very own kit for buying time under torture by downloading, installing and setting up TrueCrypt — open-source encryption software. It can encrypt whole partitions, even the ones where your OS resides, and it works on Windows.

By the way, I’m not playing with TrueCrpyt because I’m afraid I’ll find myself at the receiving end of torture. I just think cryptography is really cool.

For the past few days I’ve been hacking on Tomboy. For those of you who don’t know, Tomboy is a note-taking application from the land of Linux. It’s extremely well done because it has a very minimalist user interface and does exactly what it advertises. I just press Ctrl + Shift + N, and a new note appears on my screen. I type whatever I have to jot down and then close the window. There is no need to press save or to say where you want the note to be stored. That’s what the program is for. There are tons of really nice features that you don’t even notice at first. I highly recommend it for people who are looking for something like this.

It was written using Mono C# and was, for the most part, gracefully ported over to Windows. However, the UI toolkit it uses is GTK+, which I have found to be very subtly broken on Windows, with bugs that are difficult to reproduce. I’ll just give one example. Tomboy has a tray icon which you can click on, and a menu pops up with a list of your recent notes. If you decide against opening any notes, you might want to click elsewhere on the screen to make the menu go away. You’ll be out of luck though. It won’t go away. This bug was reported to the GTK+ team in November 2006, and it’s still not fixed.

Thankfully, a knowledgeable figure by the name of Raphaël Godart found a way to work around this bug. I tested his patch yesterday, debugged a couple of issues with it, and turned it back in to the Tomboy team. Hopefully it will be included in the next stable release. I, however, can take advantage of the patch straight away, which is awesome.

One last cool thing about Tomboy.

An addin that lets you type math equations in Tomboy using LaTeX.

What you see here is a note where I have typed a bit of math. You input it by writing LaTeX code surrounded by \[  \], and when you move away from the code, Tomboy automagically turns the code into a picture. Placing the cursor over the picture turns it back into code for you to modify. It took a bit of effort on my part to get this addin to work on Windows. I hope to finish it up and send my work back to the author, so others can use this.

I used to take notes in math class using LaTeX. At the end of one semester of class, I had 39 pages of notes in a pdf file. Having the notes in Tomboy would have been much cooler though. And more organized.

https://bugzilla.gnome.org/show_bug.cgi?id=377416