What Is Cryptography?

Leonardo Da Vinci is known to be the foremost proponent of privacy and a pioneer in ensuring it. Fearing that his messengers might be inclined to sell his confidential information if they were paid a higher sum, he began to develop containers that could only be unlocked with a unique code.

One such mechanical cipher featured in the controversial mystery novel The Da Vinci Code, where the protagonist Robert Langdon, a Harvard symbologist (a fictional field dedicated to the study of iconic religious symbols), attempts to unlock a cipher designed by the maestro himself. The portable container is scaled with thin, white dials that are divided into alphabets. Langdon must rotate the dials and align alongide the knob just the right combination of alphabets to generate the secret code that will unlock the gilded container.

Cryptex in The Da Vinci Code (Photo Credit : The Da Vinci Code / Imagine Entertainment)

To ensure that an intruder doesn’t try to break it open, Da Vinci inscribed the information on a scroll that rolled around a glass vial filled with vinegar. Thrashing it against the ground would cause the vial to shatter, such that the rivulets of acid would dissolve the entire scroll and the information along with it. Genius. This meant that the scroll could only be accessed by those who possessed this secret key – preferably only the sender and the receiver. Today, this type of secrecy is implemented by encryption and the art of keeping secrets in this manner is known as cryptography.

What Is Encryption?

Cryptography wasn’t just particular to Da Vinci; its origins can be dated back to around 400 CE to Egyptian hieroglyphs. The use of mechanical ciphers can be dated to the 1400s, when Ahmad al-Qalqashandi published a 14-volume encyclopedia that included a brief section on cryptography. Though it had been long applied before the book was published, it was the first time a textbook described its conduct in detail.

Cryptography is the study of techniques for scrambling or remolding data in order to disguise it. The concealed data can only be accessed by people capable of unscrambling it and restoring it to its original form. Scrambling enables secrecy, as it makes the data appear highly non-sensical or unintelligible to an external, probably malicious actor who has no idea how to unscramble it.

Ibn Wahshiyya's 985 CE translation of the Ancient Egyptian hieroglyph alphabet

(Photo Credit: Aḥmad ibn ʿAlī Ibn Waḥšiyya / Wikimedia Commons)

Condensing an intelligible piece of plaintext information into an entirely new, unintelligible word is formally known as encryption. On the other hand, converting back the encrypted string and recovering the precious data is known as decryption. The two processes are implemented by the sender and receiver, respectively, with the help of an algorithm.  An algorithm acts as a set of rules that establish a relationship between the symbols in the plaintext and the ciphertext. Without the key, it is not possible to either drop or lift the veil.

The algorithm can either be a really simple relationship, such as A-(1), B-(2) to Z-(26), which would transform “SCIENCEABC” into “(19)(3)(9)(5)(14)(3)(5)(1)(2)(3)”. This technique is employed by substitution ciphers. The most famous substitution cipher was used by Julius Caesar to communicate furtively with his generals. He encrypted his commands by replacing each of its alphabets with alphabets three places to their immediate left. This would cause A to become X, B – Y, C – Z, D – A and so on.

Lock key image and Caesar's cipher

Another type of cipher is a transposition cipher, which manipulates the position of symbols within the text itself according to a known set of rules, avoiding a reference to external ciphertexts. One of the simplest rules is to reverse the order in which the symbols are penned. For instance, “SCIENCEABC” can be disguised as “CBAECNEICS”. To seek the key is to determine how the algorithm works.

How Computers Changed The Game

However, confidential messages secured with such trivial algorithms can be deciphered with barely any effort. In fact, in the two cases above, one could simply guess the algorithms and access the private information. Starting right from scratch, without any predispositions about the nature of the algorithm, the only way to discover a hidden identity is to compute probabilities.

There is no question that the human brain can compute, although what is questionable is its efficiency. The efficiency is dauntingly poor when it is asked to compute frighteningly large probabilities, such as the ones involved in modern cryptography. What can carry out such an extensive computation effortlessly is a computer. A computer that boasts sufficient computational strength can investigate every nook and cranny to hunt down the right key.

Encryption digital lock

(Photo Credit : Pixabay)

Computers achieve this by gathering statistics, which may primarily include the frequency of symbols in the encrypted text. This is exactly what Alan Turing, played by Benedict Cumberbatch, does in the film The Imitation Game. Alan Turing leads a team of brilliant mathematicians who spy on the Nazis by intercepting their communication lines. Their objective is to decrypt the transmitted codes encrypted by the adroitly designed ENIGMA machine. Aware of the possibility of such an intervention, the Nazis changed their algorithm every 24 hours.

Turing knew that despite his side’s mathematical rigor, cracking the code in a single day would be impossible, unless, you have a machine that could execute the tedious task for you – but more importantly, at a much faster rate! The machine Turing builds is essentially a primitive computer. Turing’s unprecedented contributions led him to be crowned as the father of computer science. The advent of computers has enabled the deciphering of data that once seemed undecipherable, data whose encryption relied on complex mathematical functions.

Alan turing machine

In the film, Alan Turing uses a machine he names ‘Victory’ to decrypt the ENIGMA codes. (Photo Credit: The Imitation Game / Black Bear Pictures)

However, what ensued mimicked the evolution of a certain species of bacteria. The potency of computers urged computer scientists to develop and redevelop encryption techniques with algorithms that would eventually grow resistant to detection. Even supercomputers find it difficult to decrypt codes encrypted with 100-digit prime numbers generated by Fermat’s Theorem. Or, consider the hash values used to encrypt digital currencies, such as Bitcoin, which make peeking at confidential content or data almost impossible.

Is Encryption Justified?

The Internet has turned out to be one of the greatest facilities mankind has ever devised. Being indisputably social animals, communication has been our foremost predilection, and it has never been faster. Be it a friend or a bank across the ocean, the Internet’s dense network of computers allows you to transmit words, audio, picture and video almost instantaneously.

However, when we talk about a network so thoroughly distributed, rigorous security becomes obligatory. If digital signatures, so ubiquitous in digital banking, weren’t encrypted, any hacker could access them with little effort and forge his way to wealth. On a public network, such as the Internet, two keys are generated to enable encryption – one is a public key that can be accessed by any user accessing the domain, whereas the other key is a private key that can only be accessed by the sender and receiver, without which decryption could not be achieved. Encrypting digital signatures with private keys not only ensures authenticity, but also integrity, ensuring that the user’s data can neither be accessed nor be altered by an unwarranted individual.

The four google facebook amazon apple logo's

Currently, the Internet is dominated by ‘the big four’.

But what about social media? Aren’t the digital oligarchs essentially data-mongers whose functional models based on targeted advertisements require them to trade their users’ privacy for money? (Ever wonder why these applications are free…?) Facebook Inc. who currently oversees the operations of The Messenger, Instagram and WhatsApp, has assured its users that messaging on the former two is encrypted, albeit not fully. The messages are encrypted by a private key; however, Facebook can generate these keys themselves and access the private data anytime it wants.

On the other hand, Facebook abruptly decided to take a step further and implement full or, as it’s called, end-to-end encryption on WhatsApp, something it had been developing for years. With 1 billion users logging in daily, WhatsApp initially implemented perfect forward secrecy, a technique where the conversation is divided into sessions, such that each session is encrypted with a different private key. Even if one key is compromised, only a small portion of the conversation is revealed. Still, like its voluble cousins, WhatsApp could also generate those individual keys themselves.

whatsapp end to end encryption 1

Subsequently, WhatsApp adopted end-to-end encryption, an encryption technique that required WhatsApp to dump the keys, as well as their blueprints. The messages are so secure that WhatsApp itself cannot decrypt them! Or at least, that’s what it assures us. This encryption was condemned by a fair share of government officials, as it denies them the opportunity to spy on potential or confirmed terrorists.

A compromise can be made – WhatsApp can install what is called a Backdoor – software that subverts security constraints and furtively gains access to all private keys that the users generate. Proponents argue that such an installment could curtail terrorism. They assure users that spying would commence only after a warrant regarding suspicious activity is obtained. However, backdoors represent a vulnerability, an opportunity for hackers to exploit and access private information. Privacy has never been so threatened.


  1. Science4all.org
  2. The Conversation
  3. IMB.com


The short URL of the present article is: http://sciabc.us/ccm70
Help us make this article better
About the Author:

Akash Peshin is an Electronic Engineer from the University of Mumbai, India and a science writer at ScienceABC. Enamored with science ever since discovering a picture book about Saturn at the age of 7, he believes that what fundamentally fuels this passion is his curiosity and appetite for wonder.

Science ABC YouTube Videos

  1. Coefficient Of Restitution: Why Certain Objects Are More Bouncy Than Others?
  2. Jump From Space: What Happens If You Do A Space Jump?
  3. Does Earth Come Back To The Same Spot In Space Every Year On Your Birthday?
  4. Bird Strike: What Happens When A Bird Strikes An Aircraft?
  5. Google Maps Secrets: How Exactly Does Google Maps Work?
  6. 10 Things About The Solar System Your Teachers Never Told You
  7. Cherenkov Radiation: What If Something Travels Faster Than The Speed Of Light?
  8. Entropy: Why is it Predicted to Cause the Heat Death of the Universe?

Get more stuff like this
in your inbox

Subscribe to our mailing list and get interesting stuff and updates to your email inbox.