Brief History of Cryptography

Cryptography is believed to have been used in Egyptian times, as early as 4000 B.C. The Egyptians used Hieroglyphics to create complex pictures which only a small number of people at that time could understand.

The Greeks allowed passing of secret information using basic transposition ciphers, one such tool they used was called a Scytale (pronounced rhyming like Italy).

The Scytale involved wrapping a piece of fabric around a dowel. The sender of the message then wrote across the dowel the message they wanted to hide. When the fabric was unraveled from the dowel the original message becomes un-readable, unless you wrap it around the same size dowel. In practice this therefore meant that the sender and receiver of the message needed to have pre-agreed which size dowel to use when writing or reading the hidden text. This agreement is still a problem today in modern cryptography. How do you exchange the "key" to unlock the message securely? This agreement has to be done using a separate secure method , sometimes referred to as an "out of band channel".

Transposition Cipher

A transposition cipher works when the characters within the original text are moved to another place within the text. An anagram is a transposition cipher.

The Romans advanced society in a number of ways, bringing many new methods to solving problems. When it came to Cryptography it is believed Caesar himself used one of the earliest forms of substitution cipher.

The substitution cipher that Caesar used became known as the Caesar cipher. The cipher worked by replacing the character with another character 3 positions along within the alphabet. This "sliding" cipher was very effective, especially as many citizens could not read. The Caesar cipher is not used in modern day cryptography as it is easy to reverse the ciphertext (encrypted message) back to the plaintext (original message). Some internet forums though do use a form of Caesar cipher called ROT13 (exactly the same but move the characters 13 places along) to hide spoilers when discussing films, among other things. This was a simple way for people to avoid accidentally reading a spoiler, but easy enough to work out the message if they wanted.

As society advanced, the need for better protection of hidden messages was needed. In 1553 Bellaso invented a simple polyalphabetic substitution cipher known as the Vigenère cipher. The basis is the same as the Caesar cipher but contains many alphabets that have been "shifted" a number of different places.

Knowing which alphabet to use for each character is set by a chosen keyword, this keyword repeats until the message has been hidden (turned into cipher text).

For example if the original message to be encrypted is "Please like this linked in pulse post if you enjoyed reading it", the person sending the message would choose a keyword, for example "redwine". This keyword would be repeated until it matches the length of characters in the message to be encrypted.

To

encrypt we use the first letter from the original message matched against the row of the table and the first letter from the key against the column on the table. Using the grid above this would look like below

Message | p l e a s e l i...
Key | r e d w i n e r...
Result | g p h w a r p z...

Vigenère Cipher

The idea of the Vigenère cipher was to mitigate the repetition of the same character each time it was replaced. This character repetition can be attacked using frequency analysis - comparing how often a character is used.

Although the Vigenère ciphe is harder to conduct frequency analysis against the cipher text compared to the Caesar cipher, if the key length of the Vigenère is known then it makes it a lot easier to break.

The Jefferson disk, first invented in 1795, is a tool used to cipher text using disks on a cylinder. Each disk contains the 26 letters of the alphabet. The order of the letters on each disk varies. The ordering of the disks becomes the key to encrypt and decrypt. The Jefferson disk suffers from frequency analysis if the text to be ciphered is longer than the total number of disks being used. Especially if the key is kept the same across multiple messages. Jefferson's device originally used 36 disks.

In 1854, Charles Wheatsone developed the Playfair Cipher which was seen as the first usable digraph substitution cipher. The cipher encrypts pairs of characters (digraphs), which is different to traditional simple substitution ciphers. This makes the frequency analysis attacks used on simple substitution ciphers ineffective as more of the cipher text is needed to start seeing patterns. The Playfair cipher was used by the British in the Second Board War and the First World War in the trenches, and was ideal for use in combat as it was quick to use. The cipher could protect the messages long enough that by the time the enemy could decrypt the message, it was of no tactical use - the troops may have already moved on.

The One-time pad, co created by Frank Miller (originally in 1882) and Gilbert Vernam (the patent was issued to Vernam in 1919). The one-time pad pairs each character from the plaintext with a character from a completely random key (known as a one-time pad). The one-time pad and the message must be of equal length in characters. The one-time pad must be unique, not repeat, and must only ever by used once. The one-time pad is considered, when implemented correctly, the only unbreakable encryption algorithm to exist. As long as the one-time pad is never used again crypt analysis becomes impossible.

A modern day example of this using binary is as follows. If the message is to be transmitted in binary, the ASCII character "V" would equal the binary value of 01010110. If we create a random one-time pad binary value equal to the same number of digits as the binary value of "V" we can then XOR the value to create the cipher text value of "V". XOR (Exclusive or) is a truth table, that returns true if both values are different, false if they are the same.

Message | 0 1 0 1 0 1 1 0
one-time pad | 1 1 0 1 0 0 0 1
ciphertext | 1 0 0 0 0 1 1 0 (resulting XOR values)

The Black Chamber was founded in 1919 following the first world war. The Black Chamber was the first U.S. cryptanalytic peacetime organisation. In the 1920 the Black Chamber was closed down to a lack of funding. The then Secretary of State Henry L. Stimson made the decision to close. His comment "Gentlemen do not read each other's mail" at the time was considered proper form - The modern day NSA has clearly moved on from that opinion.

The Bombe developed in 1939 at Bletchley Park was designed to discover the Enigma settings, which changed daily at midnight. The settings for the Enigma is the encryption/decryption key. The bombe would rotate each drum until the bombe detected a suitable position. The operator would note the position and restart the machine. The Bombe could check many more possible combinations than human crypt-analysis' ever could.

Throughout history cryptography, especially encryption, has developed and continued to create more sophisticated protection algorithms. These are then attacked when better methods to break the encryption are developed. Cryptography may have been used for many years to protect government and military data. As modern society is demanding their data instantly from anywhere in the world, our everyday lives depend on all forms of cryptography more than ever before.

The Greeks allowed passing of secret information using basic transposition ciphers, one such tool they used was called a Scytale (pronounced rhyming like Italy).

The Scytale involved wrapping a piece of fabric around a dowel. The sender of the message then wrote across the dowel the message they wanted to hide. When the fabric was unraveled from the dowel the original message becomes un-readable, unless you wrap it around the same size dowel. In practice this therefore meant that the sender and receiver of the message needed to have pre-agreed which size dowel to use when writing or reading the hidden text. This agreement is still a problem today in modern cryptography. How do you exchange the "key" to unlock the message securely? This agreement has to be done using a separate secure method , sometimes referred to as an "out of band channel".

Transposition Cipher

A transposition cipher works when the characters within the original text are moved to another place within the text. An anagram is a transposition cipher.

The Romans advanced society in a number of ways, bringing many new methods to solving problems. When it came to Cryptography it is believed Caesar himself used one of the earliest forms of substitution cipher.

The substitution cipher that Caesar used became known as the Caesar cipher. The cipher worked by replacing the character with another character 3 positions along within the alphabet. This "sliding" cipher was very effective, especially as many citizens could not read. The Caesar cipher is not used in modern day cryptography as it is easy to reverse the ciphertext (encrypted message) back to the plaintext (original message). Some internet forums though do use a form of Caesar cipher called ROT13 (exactly the same but move the characters 13 places along) to hide spoilers when discussing films, among other things. This was a simple way for people to avoid accidentally reading a spoiler, but easy enough to work out the message if they wanted.

As society advanced, the need for better protection of hidden messages was needed. In 1553 Bellaso invented a simple polyalphabetic substitution cipher known as the Vigenère cipher. The basis is the same as the Caesar cipher but contains many alphabets that have been "shifted" a number of different places.

Knowing which alphabet to use for each character is set by a chosen keyword, this keyword repeats until the message has been hidden (turned into cipher text).

For example if the original message to be encrypted is "Please like this linked in pulse post if you enjoyed reading it", the person sending the message would choose a keyword, for example "redwine". This keyword would be repeated until it matches the length of characters in the message to be encrypted.

To encrypt we use the first letter from the original message matched against the row of the table and the first letter from the key against the column on the table. Using the grid above this would look like below

Message | p l e a s e l i...
Key | r e d w i n e r...
Result | g p h w a r p z...

The idea of the Vigenère cipher was to mitigate the repetition of the same character each time it was replaced. This character repetition can be attacked using frequency analysis - comparing how often a character is used.

Although the Vigenère ciphe is harder to conduct frequency analysis against the cipher text compared to the Caesar cipher, if the key length of the Vigenère is known then it makes it a lot easier to break.

The Jefferson disk, first invented in 1795, is a tool used to cipher text using disks on a cylinder. Each disk contains the 26 letters of the alphabet. The order of the letters on each disk varies. The ordering of the disks becomes the key to encrypt and decrypt. The Jefferson disk suffers from frequency analysis if the text to be ciphered is longer than the total number of disks being used. Especially if the key is kept the same across multiple messages. Jefferson's device originally used 36 disks.

In 1854, Charles Wheatsone developed the Playfair Cipher which was seen as the first usable digraph substitution cipher. The cipher encrypts pairs of characters (digraphs), which is different to traditional simple substitution ciphers. This makes the frequency analysis attacks used on simple substitution ciphers ineffective as more of the cipher text is needed to start seeing patterns. The Playfair cipher was used by the British in the Second Board War and the First World War in the trenches, and was ideal for use in combat as it was quick to use. The cipher could protect the messages long enough that by the time the enemy could decrypt the message, it was of no tactical use - the troops may have already moved on.

The One-time pad, co created by Frank Miller (originally in 1882) and Gilbert Vernam (the patent was issued to Vernam in 1919). The one-time pad pairs each character from the plaintext with a character from a completely random key (known as a one-time pad). The one-time pad and the message must be of equal length in characters. The one-time pad must be unique, not repeat, and must only ever by used once. The one-time pad is considered, when implemented correctly, the only unbreakable encryption algorithm to exist. As long as the one-time pad is never used again crypt analysis becomes impossible.

A modern day example of this using binary is as follows. If the message is to be transmitted in binary, the ASCII character "V" would equal the binary value of 01010110. If we create a random one-time pad binary value equal to the same number of digits as the binary value of "V" we can then XOR the value to create the cipher text value of "V". XOR (Exclusive or) is a truth table, that returns true if both values are different, false if they are the same.

Message | 0 1 0 1 0 1 1 0
one-time pad | 1 1 0 1 0 0 0 1
ciphertext | 1 0 0 0 0 1 1 0 (resulting XOR values)

The Black Chamber was founded in 1919 following the first world war. The Black Chamber was the first U.S. cryptanalytic peacetime organisation. In the 1920 the Black Chamber was closed down to a lack of funding. The then Secretary of State Henry L. Stimson made the decision to close. His comment "Gentlemen do not read each other's mail" at the time was considered proper form - The modern day NSA has clearly moved on from that opinion.

The Bombe developed in 1939 at Bletchley Park was designed to discover the Enigma settings, which changed daily at midnight. The settings for the Enigma is the encryption/decryption key. The bombe would rotate each drum until the bombe detected a suitable position. The operator would note the position and restart the machine. The Bombe could check many more possible combinations than human crypt-analysis' ever could.

Throughout history cryptography, especially encryption, has developed and continued to create more sophisticated protection algorithms. These are then attacked when better methods to break the encryption are developed. Cryptography may have been used for many years to protect government and military data. As modern society is demanding their data instantly from anywhere in the world, our everyday lives depend on all forms of cryptography more than ever before.