Showing posts with label Block Cipher. Show all posts
Showing posts with label Block Cipher. Show all posts

Wednesday, March 22, 2017

Cryptography: Stream Cipher Vs Block Cipher

Block Ciphers vs Stream Ciphers

The below section will illustrate the main advantages and disadvantages of stream and block ciphers.
  • Since stream ciphers work bit by bit, stream ciphers are faster than block ciphers.
  • Since block cipher work on block of data, so it requires more memory for computation than stream cipher.
  • One of the biggest advantage of stream ciphers over block ciphers is that they do not require padding.
  • Because block ciphers encrypt a whole block at a time (and furthermore have “feedback” modes which are most recommended), they are more susceptible to noise in transmission, that is if you mess up one part of the data, all the rest is probably unrecoverable. Whereas with stream ciphers are bytes are individually encrypted with not connection to other chunks of data (in most ciphers/modes), and often have support for interruptions on the line.
  • stream ciphers do not provide integrity protection or authentication, whereas some block ciphers (depending on mode) can provide integrity protection, in addition to confidentiality.
Step forward in 2017: Build in-demand career skills with Coursera Start your future with a Data Analysis Certificate. Step forward in 2017: Build in-demand career skills with Coursera

Friday, March 10, 2017

Cryptography: Block Cipher and Modes of Operation

Machine Learning Specialization from University of Washington Become a Web Developer in 2016 with Coursera Become a Digital Marketer in 2016 with Coursera.

In cryptography, a block cipher is a deterministic algorithm operating on fixed-length groups of bits, called blocks, with unvarying transformation that is specified by a symmetric key.

A block cipher algorithm is a basic building block for providing data security.

To apply a block cipher in a variety of applications, five “modes of operations” are defined by NIST.
  1. Electronic Codebook
  2. Cipher Block Chaining
  3. Cipher Feedback
  4. Output Feedback
  5. Counter

Career skills to jumpstart your future. Online learning to jumpstart your future. Start your future with a Business Analytics Certificate.

Thursday, February 23, 2017

Cryptography: Ideal Block Cipher


In an ideal block cipher, the relationship between the input blocks and the output block is completely random. But it must be invertible for decryption to work.

Therefore, it has to be one-to- one, meaning that each input block is mapped to a unique output block.

The mapping from the input bit blocks to the output bit blocks can also be construed as a mapping from the integers corresponding to the input bit blocks to the integers corresponding to the output bit blocks.

The encryption key for the ideal block cipher is the codebook itself, meaning the table that shows the relationship between the input blocks and the output blocks
Sitewide-Feb4of4640x480Problems with Ideal Block Cipher

There is a practical problem with the ideal block cipher.
If a small block size, such as n = 4, is used, then the system is equivalent to a classical substitution cipher.
Such systems are vulnerable to a statistical analysis of the plaintext.
This weakness is not inherent in the use of a substitution cipher but rather results from the use of a small block size.
If n is sufficiently large and an arbitrary reversible substitution between plaintext and ciphertext is allowed, then the statistical characteristics of the source plaintext are masked to such an extent that this type of cryptanalysis is infeasible.
However, an arbitrary reversible substitution cipher (the ideal block cipher) for a large block size is not practical from an implementation and performance point of view.
Why?

n=4, required key length: (4 bits)*(16 rows) = 64 bits.
In general, for an n-bit ideal block cipher, the length of the key defined in this fashion is n * 2n bits.
For a 64-bit block, which is a desirable length to thwart statistical attacks, the required key length is 64 * 264 = 270 = 1021 bits.
The size of the encryption key would make the ideal block cipher an impractical idea.
Think of the logistical issues related to the transmission, storage, and processing of such large keys.
Considering these difficulties, what we need to do is make an approximation for large value of n so that it is easily realizable.