Education logo

Public Key Cryptography

Cryptography

By Daniel Joseph Published 2 years ago 4 min read
1
Public Key Cryptography
Photo by AronPW on Unsplash



The Caesar cypher just described is known as a symmetric cypher because the same key is used to encrypt and decrypt the message. In public key cryptography, the key used to decrypt a message is different (but mathematically linked) to the key used to encrypt the message.
Public key cryptography is described as an asymmetric scheme, because the key used to decrypt the message is not the same as the key used to encrypt it. This makes it more secure.
Using asymmetric cryptography, if you want to receive encrypted messages you create two mathematically linked keys: a public key and a private key. Together they are called a key pair. You can share your public key with the world, and anyone can use it to encrypt messages for you.
You use your private key, known only to you, to decrypt those messages. Anyone who sends you encrypted messages using your public key knows that only you can decrypt them.

As we have seen, one of the biggest problems of symmetric cryptography is how to share a key in the first place when all forms of communication are tapped. It is hard to be sure that you can share a decryption key with your friend without the eavesdroppers also getting that key. With public key cryptography, you broadcast your public key to everyone, not caring if the eavesdroppers can see it or not. Your friend then encrypts the message and sends it to you. Only you can decrypt it because only you have the private key. If an eavesdropper gets the encrypted message, they can’t decrypt it because they don’t have your private key. It is a beautiful system and a huge improvement over symmetric schemes because you never need to communicate a shared or common key.

What do keys look like? There are number of different schemes. PGP (Pretty Good Privacy) is a scheme originally developed in the 1990’s for encrypting, decrypting and digitally signing messages such as emails. This scheme was so powerful that the US Government didn’t like it and had it classified as Munitions, an ‘Auxiliary Military Equipment,’ meaning that anyone found exporting it from the US would be in deep trouble. Phil Zimmermann, the creator of PGP, found a way around this by publishing the source code as a hardback book using First Amendment protection of the export of books68. This marked the height of tensions between the US Government and individuals who are passionate, quite rightly so, about privacy. To learn about this story in depth, I recommend Steven Levy’s book Crypto which documents the history of PGP and the revolution of cryptography.

encrypting, decrypting and digitally signing messages such as emails. This scheme was so powerful that the US Government didn’t like it and had it classified as Munitions, an ‘Auxiliary Military Equipment,’ meaning that anyone found exporting it from the US would be in deep trouble. Phil Zimmermann, the creator of PGP, found a way around this by publishing the source code as a hardback book using First Amendment protection of the export of books68. This marked the height of tensions between the US Government and individuals who are passionate, quite rightly so, about privacy. To learn about this story in depth, I recommend Steven Levy’s book Crypto which documents the history of PGP and the revolution of cryptography.

Back to public and private keys. I downloaded GPG Suite69, an open source and free set of tools that conforms to the OpenPGP standards, and I created a new keypair.

As we have seen, one of the biggest problems of symmetric cryptography is how to share a key in the first place when all forms of communication are tapped. It is hard to be sure that you can share a decryption key with your friend without the eavesdroppers also getting that key. With public key cryptography, you broadcast your public key to everyone, not caring if the eavesdroppers can see it or not. Your friend then encrypts the message and sends it to you. Only you can decrypt it because only you have the private key. If an eavesdropper gets the encrypted message, they can’t decrypt it because they don’t have your private key. It is a beautiful system and a huge improvement over symmetric schemes because you never need to communicate a shared or common key.
What do keys look like? There are number of different schemes. PGP (Pretty Good Privacy) is a scheme originally developed in the 1990’s for

encrypting, decrypting and digitally signing messages such as emails. This scheme was so powerful that the US Government didn’t like it and had it classified as Munitions, an ‘Auxiliary Military Equipment,’ meaning that anyone found exporting it from the US would be in deep trouble. Phil Zimmermann, the creator of PGP, found a way around this by publishing the source code as a hardback book using First Amendment protection of the export of books68. This marked the height of tensions between the US Government and individuals who are passionate, quite rightly so, about privacy. To learn about this story in depth, I recommend Steven Levy’s book Crypto which documents the history of PGP and the revolution of cryptography.
Back to public and private keys. I downloaded GPG Suite69, an open source and free set of tools that conforms to the OpenPGP standards, and I created a new keypair.

how to
1

About the Creator

Daniel Joseph

Reader insights

Be the first to share your insights about this piece.

How does it work?

Add your insights

Comments

There are no comments for this story

Be the first to respond and start the conversation.

Sign in to comment

    Find us on social media

    Miscellaneous links

    • Explore
    • Contact
    • Privacy Policy
    • Terms of Use
    • Support

    © 2024 Creatd, Inc. All Rights Reserved.