Page 221 - DCAP406_DCAP_207_Computer Networks
P. 221

Computer Networks/Networks




                    Notes          includes Abstract Syntax Notation 1 (ASN.1) is recommended by OSI. This method takes care of
                                   formatting, diverse nature of data such as text, programs, etc. and the diversity in data storage
                                   format.

                                   14.4.2 Encryption/Decryption

                                   It deals with security and privacy issues. Encryption is used to scramble the data so that only
                                   authorized persons can unscramble the data of a conversation. Decryption reverses the encryption
                                   process to translate the message back into its original form. To encrypt the data, the sender in the
                                   source machine uses an encryption algorithm and a key to transform the plaintext (original
                                   message) into a ciphertext (encrypted message). At the destination machine, the reverse process
                                   takes place. The receiver has a key and decryption algorithm to translate back the ciphertext into
                                   the original plaintext.
                                   Authentication refers to keep a secret of two persons secure from the third person. However, the
                                   non-repudiation requires to prove that even the sender could not have generated the message.
                                   To implement security issues as given above, a technique called cryptography is applied.
                                   Encryption is of two types:

                                   1.  Asymmetric Encryption: Two mathematically related keys namely public key and private
                                       keys are generated to encrypt and decrypt the message. Asymmetric encryption is
                                       considered more secure than symmetric encryption. Asymmetric key encryption that
                                       involves a key pair as public and private keys involves six major steps:

                                       (a)  Plaintext: Plaintext is the text message to which an algorithm is applied.
                                       (b)  Encryption Algorithm: It provides mathematical operations to conduct substitutions
                                            and transformations to the plaintext.

                                       (c)  Public and Private Keys: They constitute a pair of keys which are used for encryption
                                            and decryption of the message.
                                       (d)  Ciphertext:  Application of algorithm on plaintext produces the encrypted or
                                            scrambled message.
                                       (e)  Decryption Algorithm: This algorithm is applied to generate the ciphertext and the
                                            matching key to produce the plaintext.

                                       The encryption process converts the text message to a hash code by using a mathematical
                                       formula. This hash code is then encrypted with the help of the sender’s private key. The
                                       private key is generated with the help of the algorithm.
                                       The encrypted hash code and the message are encrypted again using the sender’s private
                                       key. Subsequent to this, the sender encrypts the secret key with the recipient’s public key,
                                       so only the recipient can decrypt it with his or her private key.
                                       In the decryption process, the recipient using his or her private key long with the secret
                                       key to decipher the encrypted hash code and the encrypted message. The recipient then
                                       uses the sender’s public key to decrypt the hash code and to verify the sender’s identity.
                                       The recipient generates a hash code from the message. If thus generated hash code equals
                                       the hash code forwarded by sender, then this verifies that the message has not been
                                       changed on the way.
                                   2.  Symmetric Encryption: Symmetric encryption also referred to as conventional or single-
                                       key encryption is based on a secret key, which is shared by both communicating parties.
                                       The sending party encrypts the plain text to cipher text message using the secret key. The
                                       receiving party on receipt of the cipher text message uses the same secret key to decrypt it




          214                               LOVELY PROFESSIONAL UNIVERSITY
   216   217   218   219   220   221   222   223   224   225   226