Wednesday, March 11, 2009

Simon Singh's Security Illustration

The most elegant and simple discussion of the Diffie/Hellman key exchange and Public Key encryption I have ever seen was in a book by Simon Singh, pejoratively called "The Code Book." The case for the Diffie/Hellman key exchange was made as follows: (I have substituted the keyless Combination lock in place of the more commonplace lock of the book.) I have a lock. I place my message in a box, and lock it. I send it to Alice. She uses her own lock, and locks the box and returns it to me. I unlock my lock, and send it back to her. She now unlocks the lock, and reads my message, with the message un-intercepted by the messenger. The case for Public Key encryption was made as follows: I license a combination, and provide the Public Key repository with any number of copies of my lock, all open. Mathematically this is trivial to do, although it might be complicated. Alice goes to the Public Key repository and picks up an open "Bob" lock. She signs her message and locks it in the box, and sends it to me, and I open it, because I know my own combination. The case for Eve and the man in the middle attack is laid out with equal clarity. I lock my box, and Eve takes it around the corner and locks it with her own lock. After an appropriate amount of time she comes back, and I unlock my lock all unsuspecting. She then "delivers" it on the other end with similar deception, having spied out the message in the interim. The question is this: With Public Key Encryption available why would anyone ever use anything else? My contribution to the discussion enters in with a discussion of Cell phone text messages. Let's suppose we are selling an encrypted Text messaging system. If we use the Public Key system, law enforcement CANNOT break the encryption. However, if we use the Diffie/Hellman key exchange, it falls to the man in the middle attack, by having the phone forwarded to another number in the middle. This is different from someone with a radio and no other number merely picking up the signal off the ether. The signal off the ether cannot negotiate a key exchange, and therefore cannot accomplish the "man in the middle attack." So a person not under investigation would have expectation of privacy, and his messages would not be breakable, whereas upon issue of a warrant, a person under investigation, like a pirate or a spy, would have their nefarious message intercepted by the man in the middle attack. This is a legitimate reason for using the Diffie/Hellman key exchange. I would personally like to offer secure Text Messaging, using Vignere which is secure for short messages at a commercial grade. This would broach the discussion in public as to whether we have the Constitutional right to a secure Text Message. We have a paradoxical view in the public, that a 2GB database should be securable if it is sensitive, but that a 160 char text message represents a pirate threat because it can be used to send the instruction to start an attack.

No comments:

Post a Comment