Electronic Codebook (ECB):
As compared to other modes of operation electronic Codebook is the easy one and involves block cipher coding. Every block is linked to the next block to avoid the simplicity. Each plaintext is sent in form of a block having a ciphertext value.
A large amount of plaintext is divided into different blocks of data which are ciphered individually. Thus in the electronic codebook, every block has its own separate encryption key. A codebook of ciphertext is created with the given key for all the possible plaintext blocks. This operation is corresponding to the consignment of codewords in a codebook.
· Advantages:
· Advantages:
i. The advantage of the electronic codebook is that it is easy to encrypt.
ii. Its security can be increased by adding in each block a pad bit but the larger code blocks say 64-bit or more have distinctive characteristics which make them difficult to attack.
· Disadvantages:
i. Also, the codebook is not good to use if block sizes are small and encryption modes are similar. In case of error correction, only that particular ciphertext block is effected which contains the bit errors.
i. Also, the codebook is not good to use if block sizes are small and encryption modes are similar. In case of error correction, only that particular ciphertext block is effected which contains the bit errors.
ii. It can be guessed by an attacker using trial and error method because in the real world every data has information somewhat which can be guessed.
Cipher Block Chaining (CBC):
In cipher block chaining the blocks are not encrypted separated but they are chained together which means that every block is XOR’ed with the output of the previous one and then the feedback register is then used to save the output of the encrypted block. Decryption is just straightforward, the cipher block is decrypted and then use the feedback register to store the decryption and then it is XOR’ed with the next decrypted block. It is the reverse of encryption.
A certain length of initialization vector (IV) is used by cipher block chaining.
· Advantages:
Plaintext pattern is hidden because of chaining process thus adding an advantage of cipher block chaining over the electronic codebook. It forms a base of a mechanism known as data origin authentication.
· Disadvantages:
The drawback of cipher block chaining is that in decryption process the error is transmitted to next blocks because of chaining process (known as limited error-propagation). During encryption, the effects of error in first are not limited only to that block but the next block also because the next block is created from the output of the previous block.
Comments
Post a Comment