Encryption techniques
As you know the encryption is the process of encoding information in such a way that only the who has the decoder key is decode is by using this key which is one type of algorithm.
Most computer encryption systems belong in one of two categories:
Most computer encryption systems belong in one of two categories:
>> Symmetric-key encryption
>> Public-key encryption
2.1 Symmetric-key encryption
>> In symmetric-key encryption, each computer has a secret key (code) that it can use to encrypt a packet of information before it is sent over the network to another computer.
>> Symmetric-key requires that you know which computers will be talking to each other so you can install the key on each one.
>> Symmetric-key encryption is essentially the same as a secret code that each of the two computers must know in order to decode the information.
>> The code provides the key to decoding the message. Think of it like this: You create a coded message to send to a friend in which each letter is substituted with the letter that is two down from it in the alphabet.
>> So "A" becomes "C," and "B" becomes "D". You have already told a trusted friend that the code is "Shift by 2". Your friend gets the message and decodes it. Anyone else who sees the message will see only nonsense.
Figure:- Symmetric key encryption
You can see in the figure that if sender want to send a secure message to recipient than sender and use private key to encrypt the message and same key used to decrypt the message. The basic requirement is that sender and recipient use same key for encryption and decryption which we can see in the figure.
2.2 Asymmetric key encryption
>> Public-key encryption uses a combination of a private key and a public key.
>> The private key is known only to your computer, while the public key is given by your computer to any computer that wants to communicate securely with it.
>> To decode an encrypted message, a computer must use the public key, provided by the originating computer, and its own private key.
>> A very popular public-key encryption utility is called Pretty Good Privacy (PGP), which allows you to encrypt almost anything.
>> To implement public-key encryption on a large scale, such as a secure Web server might need, requires a different approach. This is where digital certificates come in.
>> A digital certificate is basically a bit of information that says that the Web server is trusted by an independent source known as a certificate authority.
>> The certificate authority acts as a middleman that both computers trust. It confirms that each computer is in fact who it says it is, and then provides the public keys of each computer to the other.
Figure:- Asymmetric key encryption
You can see in the figure that if sender want to send secure message to recipient than sender use public key of recipient for encrypt the message. Now, at the recipient side recipient use it’s own private key to decrypt the message. By this way only the recipient can get the original message or secure information.
2.2.1 Pretty Good Privacy Encryption
>> PGP combines some of the best features of both conventional and public key cryptography; it’s a hybrid cryptosystem.
>> When a user encrypts plaintext with PGP, PGP first compresses the plaintext.
>> Data compression saves transmission time and disk space and, more importantly, strengthens cryptographic security.
>> Most cryptanalysis techniques exploit patterns found in the plaintext to crack the cipher. Compression reduces these patterns in the plaintext, thereby greatly enhancing resistance to cryptanalysis.
PGP then creates a session key, which is a one-time-only secret key.
>> This key is a random number generated from the random movements of your mouse and the keystrokes you type.
>> This session key works with a very secure, fast conventional encryption algorithm to encrypt the plaintext; the result is cipher text.
>> Once the data is encrypted, the session key is then encrypted to the recipient's public key. This public key-encrypted session key is transmitted along with the cipher text to the recipient.
2.2.2 Pretty Good Privacy Decryption
>> Decryption works in the reverse. The recipient's copy of PGP the private key to recover the temporary session key, which PGP then uses to decrypt the conventionally-encrypted cipher text.
>> The combination of the two encryption methods combines the convenience of public key encryption with the speed of conventional encryption. Conventional encryption is about 1, 000 times faster than public key encryption. Public key encryption in turn provides a solution to key distribution and data transmission issues. Used together, performance and key distribution are improved without any sacrifice in security.
2.3 Difference between Symmetric and Asymmetric
Conventional Encryption | Public key Encryption |
Needed to Work The same algorithm with the same key is used for encryption and decryption. The sender and receiver must share the algorithm and the key. Needed for security The key must be kept secret It must be impossible or at least impractical to decipher a message if no other information is available. Knowledge of algorithm plus sample of the cipher text must be insufficient to determine the key. | Needed to Work 1. One algorithm is used for encryption and one algorithm for decryption 2. The sender and receiver must each have one of the matched pair of keys. Needed for security One of the two keys must be kept secret. It must be impossible to decipher a message if no other information is available. Knowledge of algorithm plus one of the key plus sample of the cipher text must be insufficient to determine the key. |