16.01.2015 Views

Hacking

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

0x712<br />

One-Time Pads<br />

One example of an unconditionally secure cryptosystem is the one-time pad.<br />

A one-time pad is a very simple cryptosystem that uses blocks of random data<br />

called pads. The pad must be at least as long as the plaintext message that is<br />

to be encoded, and the random data on the pad must be truly random, in<br />

the most literal sense of the word. Two identical pads are made: one for the<br />

recipient and one for the sender. To encode a message, the sender simply<br />

XORs each bit of the plaintext message with the corresponding bit of the<br />

pad. After the message is encoded, the pad is destroyed to ensure that it is<br />

only used once. Then the encrypted message can be sent to the recipient without<br />

fear of cryptanalysis, since the encrypted message cannot be broken<br />

without the pad. When the recipient receives the encrypted message, he also<br />

XORs each bit of the encrypted message with the corresponding bit of his<br />

pad to produce the original plaintext message.<br />

While the one-time pad is theoretically impossible to break, in reality it’s<br />

not really all that practical to use. The security of the one-time pad hinges<br />

on the security of the pads. When the pads are distributed to the recipient<br />

and the sender, it is assumed that the pad transmission channel is secure.<br />

To be truly secure, this could involve a face-to-face meeting and exchange,<br />

but for convenience, the pad transmission may be facilitated via yet another<br />

cipher. The price of this convenience is that the entire system is now only<br />

as strong as the weakest link, which would be the cipher used to transmit<br />

the pads. Since the pad consists of random data of the same length as the<br />

plaintext message, and since the security of the whole system is only as<br />

good as the security of pad transmission, it usually makes more sense to just<br />

send the plaintext message encoded using the same cipher that would have<br />

been used to transmit the pad.<br />

0x713<br />

Quantum Key Distribution<br />

The advent of quantum computation brings many interesting things to the<br />

field of cryptology. One of these is a practical implementation of the onetime<br />

pad, made possible by quantum key distribution. The mystery of quantum<br />

entanglement can provide a reliable and secret method of sending a random<br />

string of bits that can be used as a key. This is done using nonorthogonal<br />

quantum states in photons.<br />

Without going into too much detail, the polarization of a photon is the<br />

oscillation direction of its electric field, which in this case can be along the<br />

horizontal, vertical, or one of the two diagonals. Nonorthogonal simply means<br />

the states are separated by an angle that isn’t 90 degrees. Curiously enough,<br />

it’s impossible to determine with certainty which of these four polarizations a<br />

single photon has. The rectilinear basis of the horizontal and vertical polarizations<br />

is incompatible with the diagonal basis of the two diagonal polarizations,<br />

so, due to the Heisenberg uncertainty principle, these two sets of polarizations<br />

cannot both be measured. Filters can be used to measure the polarizations—<br />

one for the rectilinear basis and one for the diagonal basis. When a photon<br />

passes through the correct filter, its polarization won’t change, but if it passes<br />

Cryptology 395

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!