Explain public key cryptography to me…

A breakdown of what public key cryptography is

Public key cryptography is a field of cryptography which solves the key distribution problem involved with the symmetrical encryption. It is a type of cryptosystem that separates the dual functionalities of a traditional cipher key into two seperate keys. Okay, let’s talk about what that exactly means…

Encryption is a mathematical algorithm that renders information unusable. This output known as a cipher text can be unscrambled or decrypted to produce the original input known as the plain-text.

1. encryption(Plain-text) = Cipher-text,
2. decryption(Cipher-text) = Plain-text

The inner workings and mechanics of these algorithms are public knowledge… Wait? So if the algorithms are known, can’t anyone decrypt the encrypted information?

Encryption algorithms uses a secret key or ‘password’ to secure the information. Unless someone has the key, they cannot decrypt the information. There are two types of encryption algorithms which manage keys differently: symmetrical and asymmetrical algorithms.

Symmetric algorithms secure their information during encryption with a key which is also used for the decryption of cipher-texts as described in notation below:

1. encryption(key1, Plain-text) = Cipher-text
2. decryption(key1, Cipher-text) = Plain-text

The problem with symmetrical encryption is that if person A wants to use the encryption algorithm to communicate with person B, they both have to have the secret key to decrypt the encrypted messages. Only once their key has been exchanged, will they be able to communicate in secret. The problem is that this ‘key exchange’ cannot be done in open public or through compromised communication channels where a eavesdropper might be listening in on. This is known as the key exchange problem.

Public key algorithms or asymmetrical encryption algorithms, solve the problem of sharing sensitive information. With public key cryptography, encryption and decryption functions of the key are separated into two keys as opposed to being a single key with dual functionality.

Since, there are two keys with their respective encryption and decryption capabilities separated, person A can simply share their encryption key or public key to person B over insecure communications without fear of compromising the condfidentiality of the message. Anyone with the public key can encrypt messages but this is relatively useless without the decryption key. Person B receives person A’s public key and now can use that to encrypt his own message to produce a cipher-text. Person B sends back the ciphertext back to person A where Person A then decrypts the ciphertext using their own decryption key or private key. Person A’s private key is at no point at risk of compromise as opposed to the symmetrical key exchange.

Public key encryption is used for sending secure messages over insecure communications.

Leave a Reply