During World War Two, Germans used a device called an Enigma machine to encrypt messages that were sent to and from their U-boats. With a simple key, they could turn readable messages (written in plaintext) into unreadable messages (ciphertext). These messages could then be decrypted with a reversal process, so they could be read by Germans.
IMAGE – Enigma Machine uses electricity and gears to encrypt messages
The United States was able to intercept the encrypted messages and understood how to decrypt them, but when the Germans began changing out the cipher system daily, it became nearly impossible to do all the calculations to decipher the messages within a day. Since these machines could be set up in 158 Sextillion (158,962,555,217,826,360,000 to be precise) different combinations, the Germans figured that it was an unbreakable code.
So, in 1939, the United States government hired Alan Turing to decipher the Enigma code. In order to solve the problem before the war ended, Turing built a machine known as the Bombe, which was able to find a flaw in the Enigma machine.
VIDEO – Finding the flaw in the Enigma machine.
After years of work, the machine was finally able to break the Enigma code and help the allies to victory. This machine is sometimes referred to as the first computer.
IMAGE – A reproduction of Turing’s Bombe machine built from his blueprints
Now, a team at Google is trying to create a new kind of enigma machine using a very different device: their artificial intelligence (AI) program. The team has already shown that they can make an advanced encryption, which becomes more difficult to crack the more times a hacker attempts to break the code.
These days, encryption involves using a complex algorithm as a key, but with Google Brain is actually using an artificial neural network (ANN) to decide how to handle each and every step of the encryption. These neural networks are specifically designed to simulate the structure of a human brain by using silicon and wires in the same way that our brains use neurons and dendrites. With this structure, ANNs have been shown to learn from their past mistakes.
The Google Brain team began their encryption experiment with three separate neural networks, which they called Alice, Bob, and Eve. Each of the neural networks was given a different objective (depicted in the image below)
IMAGE – A diagram that details the tests that Google’s ANNs were put through
First, Alice would be given a 16 digit code written in plaintext [P], which it would then encrypt into a ciphertext [C]. Alice would then send the encrypted message [C] to Bob, and Eve, who are both trying to decrypt that message and bring it back to the original plaintext [P].
Alice and Bob started out with an advantage over Eve, because they both shared a secret key [K] with each other. This key is similar to the one used with the enigma machine; it allowed Germans on either side of a communication to decrypt messages without a third party being able to decipher them.
In these tests, Eve was only a “passive attacker,” which means it could only intercept the message, without the ability to initiate, inject, or modify any messages. Eve’s only goal in the experiment was to minimize the error between the original message [P] and its deciphered guess [PEve]. While Bob’s goal was to minimize the error between [P] and [PBob] but, at the same time, Bob was also trying to stop Eve from achieving her goal. If Eve’s guess was better than Bob’s decryption, it would be considered a loss. Or, if Eve was able to guess better than random, it was also considered a loss.
That is all the experiment consisted of. There were no other instructions given to any of the ANNs. And since the team did not provide any specific instructions or even any indication on how to apply algorithms to encrypt the messages, they showed that their neural networks were able to learn how to encrypt and decrypt messages without any further supervision. They also showed that ANNs can learn how to encrypt messages that other ANNs cannot learn to decrypt. Basically, they have made an enigma machine that cannot be cracked.
If you look at the first tests that were performed, Eve was able to decrypt the messages with the same rate of accuracy as Bob. After a period of time, Alice and Bob were able to refine their methods until Eve could not decrypt any messages at all.
IMAGE – The evolution of the ANNs errors over thousands of tests.
Each point in the graph above shows the error rate over thousands of different tests. Since the messages were written in binary, the average error rate from Bob and Eve is 8 right and 8 wrong. That is that is the same success rate you would expect from the flip of a coin. But, then, somewhere before step 10,000, Alice and Bob begin to learn from each other.
Soon, they are able to find an encryption that dropped Bob’s error rate to 0, while still keeping Eve’s error rate stable. Then, by step 15,000, Alice and Bob were able to achieve a perfect score consistently.
The dynamics of this test do not look like they were the result of a human engineer, they are, instead, more reminiscent of evolutionary processes. As they got more practice, Alice slowly developed a unique encryption strategy, and Bob worked out how to decrypt it.
In some tests, Eve was able to show an improvement over, but Alice and Bob were able to quickly improve their encryption technique until Eve’s success rate went down to 0 again.
By using this approach, it means that communication can eventually be secured without a prescribed set of algorithms. This means that two computers working together can self-generate encryptions that are so difficult that no human or machine would ever be able to crack them. Then, those machines could instantly discard that encryption for another one.
WHAT IT MEANS FOR FUTURE APPLICATIONS
Encryption is not only used for warfare anymore, it has become a part of our everyday life. Hackers and other criminals have been able to steal information from anyone.
That is why it is so important to use encryption to keep your communications and other data safe. Soon, we may start to see ANNs being able to protect all sorts of data with unbreakable encryptions, which would allow for a sense of regained privacy.
If you are worried about protecting your data, you can always a colocation provider, they will usually encrypt your data to keep it safe from any interceptions.