Cryptography is a technique or protocol that secures information from any third party during communication.

  • Encryption: encryption is the process of encoding information. This process converts the original representation of the information, known as plaintext, into an alternative form known as ciphertext.
  • Key: A key is a piece of information, usually a string of numbers or letters that are stored in a file, which, when processed through a cryptographic algorithm, can encode or decode cryptographic data

Decryption: The inverse process of encryption, converting a random sequence of bits into plain text.

Cipher:

Types of Cryptography

Cryptography can be broken down into three different types:

Secret Key Cryptography

Public Key Cryptography

Hash Functions

Use in Blockchain

Most of the time blockchain uses public-key cryptography, also known as asymmetric-key cryptography.

Public key cryptography uses both public key and private key in order to encrypt and decrypt data. The public key can be distributed commonly but the private key can not be shared with anyone.

The public key is used as the address of the wallet and is visible globally, i.e. it is visible to any participant.

The private key is a secret value and is used to access that address data and authorize any of the actions for the ‘address’, which are generally transactions.