Fundamentals of Cryptography

Symmetric Key Cryptography

Symmetric key cryptography is based on the concept of a shared secret. That is two identities share a key that is common and known only to them. This key provides authentication and privacy. Since we can only decrypt data by using a key that only one other person has, the key also provides a means of authenticating that other person.

Symmetric algorithms come in two general formats – stream and block. A stream cipher does not encrypt data directly with the key. Instead, it uses the key as the basis for generating a keystream. Generation of the keystream is an expensive operation and results in the bulk of the processing overhead required in stream cipher encryption. For every bit in the plaintext, there is one corresponding bit in the keystream. The plaintext is encrypted bit by bit by performing an operation such as an XOR, which is not computationally expensive. RC4 (Rivest cipher 4) is the most common stream cipher, as it is the default cipher used by a technology called Microsoft Point to Point Encryption (MPPE). MPPE has many uses on the Windows platform. Block ciphers on the other hand, directly use the key to encrypt data. The plaintext is divided into blocks whose size is directly related to the size of the key. Each block is then encrypted using the key to produce cyphertext. DES is perhaps the most common example of a block cipher.