As mentioned before, there are two main cryptographic algorithms applied in blockchain: one is the hash algorithm, and the other is asymmetric encryption. Today, we will discuss what "asymmetric encryption" is in blockchain cryptography.
Simply put, asymmetric encryption is a special method used to encrypt content. However, before diving into the specifics of asymmetric encryption, let’s first cover some other key concepts in cryptography:
Currently, encryption and decryption methods in cryptography can be divided into two categories: symmetric encryption and asymmetric encryption. Both encryption systems share the same components, including encryption/decryption algorithms, encryption keys, and decryption keys.
For example, in our daily lives, we often use keys and locks. The key we use to open a door is analogous to the "secret key" in cryptography, while the lock itself represents the encryption/decryption algorithm.
In an encryption/decryption system, the algorithms themselves are fixed and usually publicly visible, while the keys are more private. During encryption, we use the encryption algorithm and encryption key to encrypt plaintext (the content to be encrypted) and obtain ciphertext (the encrypted content). The decryption process is the opposite: we use the decryption algorithm and decryption key to decrypt the ciphertext and retrieve the plaintext.
When a single key is used for both encryption and decryption—like a lock and key—it is called symmetric encryption.
Conversely, when different keys are used for encryption and decryption, it is called asymmetric encryption. Asymmetric encryption is unique in that it generates two keys: the most crucial one is called the private key, which is kept secret by the user, while the other is made public and called the public key.
They have a special characteristic: content encrypted with the private key can be decrypted and read using the public key, and vice versa—content encrypted with the public key can be decrypted with the private key. It’s almost like the telepathic connection between twins.
In blockchain, the primary purpose of asymmetric encryption is not to protect the privacy of content but to prevent identity impersonation.
For example, when conducting a transaction on the blockchain network, there’s no way to verify whether the transaction is genuinely initiated by you. In this case, you can send a digital signature (which is a piece of content encrypted with your private key), and the recipient can decrypt it using your publicly available public key.
Since the private key is only held by you, if the recipient can successfully decrypt it with the corresponding public key, it confirms that the transaction was initiated by you. If decryption fails, it indicates that someone else is impersonating you. This solves the problem of proving "I am me, and this is my transaction."
In summary, cryptography is the most fundamental aspect of blockchain networks. It not only safeguards the security of the entire network but also resolves many verification issues in transactions. With the emergence of new technologies like quantum computing, some may question its security. However, it’s important to remember that cryptography also evolves with the times. By the time quantum computing becomes commercially viable, blockchain cryptography will undoubtedly advance to become even more secure.