The Paar Lectures on Introductory Cryptography

Slectures by Divya Agarwal and Katie Marsh

4. Stream Ciphers


Introductory lecture to Stream Ciphers - Prof. Paar

Link to video on youtube


Accompanying Lecture Notes


Stream Ciphers vs. Block Ciphers

  • Stream Ciphers
    • Encrypt bits individually by adding a bit from a key stream to a plaintext bit.
    • Usually small and fast, common in embedded devices (e.g., A5/1 for GSM phones)
  • Block Ciphers
    • Encrypt an entire block of plaintext bits at a time with the same key.
    • Are common for Internet applications

In this lecture we study Stream Ciphers.

Encryption and Decryption of Stream Ciphers

Each plaintext bit $ x_i $ is encrypted by adding a secret key stream bit $ s_i $ modulo 2. Refer figure below.

Fig 1:Encryption and Decryption with Stream Ciphers
  • Encryption : $ y_i = e_{si} = x_i + s_i mod2 $ where $ x_i,s_i,y_i \in \{0,1\} $
  • Decryption : $ x_i = e_{si} = y_i + s_i mod2 $

Encryption and decryption are the same functions.

Why is Modulo 2 Addition a Good Encryption Function?

  • Modulo 2 addition is equivalent to XOR operation.
  • For perfectly random key stream $ s_i $, each ciphertext output bit has a 50% chance to be 0 or 1, which is a Good statistic property.

How do we get a good Key Stream?

Security of stream cipher depends entirely on the key stream $ s_i $:

  • It should be random.
  • Must be reproducible at both sender and receiver ends.

There are several ways to produce random key streams, they are listed below:

  • Random number genrators(RNGs)
    • True Random number genrators(TRNGs)
    • Pseudo Random number genrators(PRNG)
    • Cryptographically Secure Pseudorandom number genrators(CSRNG)
  • One-Time Pad(OTP)
  • Linear feedback shift registers(LFSRs)


The complete lecture on Stream Ciphers is available here.


References

  • C. Paar. Understanding Cryptography. Lecture Notes. Dept. of Electr. Eng. and In­for­ma­ti­on Sci­en­ces, Ruhr University.
  • C. Paar and J. Pelzl. Understanding Cryptography. A textbook for Student and Practitioners. Springer 2010.

Questions and comments

If you have any questions, comments, etc. please post them here.


Back to 2015 Summer Cryptography Paar


Alumni Liaison

Questions/answers with a recent ECE grad

Ryne Rayburn