Stream Cipher. A stream cipher breaks the message M into successive characters or bits m 1, m 2,..., and enciphers each m i with the ith element k i of.

Slides:



Advertisements
Similar presentations
Classical Encryption Techniques Week 6-wend. One-Time Pad if a truly random key as long as the message is used, the cipher will be secure called a One-Time.
Advertisements

“Advanced Encryption Standard” & “Modes of Operation”
Modern Symmetric-Key Ciphers
Modern Symmetric-Key Ciphers
CS 483 – SD SECTION BY DR. DANIYAL ALGHAZZAWI (3) Information Security.
Classical Cryptosystems Shift Ciphers (Caesar) y= x+k (mod 26) Affine Ciphers y=ax+b (mod 26) Vigenere Ciphers codes=(02,14,03,04,18) Substitution Ciphers.
Digital Kommunikationselektroink TNE027 Lecture 6 (Cryptography) 1 Cryptography Algorithms Symmetric and Asymmetric Cryptography Algorithms Data Stream.
CSCI283 Fall 2005 GWU All slides from Bishop’s slide set Stream Ciphers.
 We spoke about defense challenges  Crypto introduction o Secret key, public algorithms o Symmetric, asymmetric crypto, one-way hashes  Attacks on cryptography.
Announcements: Matlab: tutorial available at Matlab: tutorial available at
亂數產生器安全性評估 之統計測試 SEC HW7 姓名:翁玉芬 學號:
Classical Cryptography 1. Introduction: Some Simple Cryptosystems.
Stream cipher diagram + + Recall: One-time pad in Chap. 2.
© The McGraw-Hill Companies, Inc., 2008 第 6 章 製造流程的選擇與設計.
J. Wang. Computer Network Security Theory and Practice. Springer 2008 Chapter 2 Data Encryption algorithms Part II.
EEC 693/793 Special Topics in Electrical Engineering Secure and Dependable Computing Lecture 5 Wenbing Zhao Department of Electrical and Computer Engineering.
Monte Carlo Simulation Part.1 Dept. Phys., Tunghai Univ. Numerical Methods, C. T. Shih.
CH 15- 元件可靠度之驗證  驗證方法  指數模式之可靠度驗證  韋式模式之可靠度驗證  對數常態模式之可靠度驗證  失效數為零時之可靠度估算  各種失效模式之應用.
EEC 688/788 Secure and Dependable Computing Lecture 4 Wenbing Zhao Department of Electrical and Computer Engineering Cleveland State University
觀測量的權 權的觀念與計算.
資料結構實習-二.
1 Foundations The problem of providing secret communication over insecure media is the most traditional and basic problem of cryptography.
McGraw-Hill©The McGraw-Hill Companies, Inc., Security PART VII.
Introduction to Symmetric Block Cipher Jing Deng Based on Prof. Rick Han’s Lecture Slides Dr. Andreas Steffen’s Security Tutorial.
EEC 693/793 Special Topics in Electrical Engineering Secure and Dependable Computing Lecture 5 Wenbing Zhao Department of Electrical and Computer Engineering.
2005/7 Linear system-1 The Linear Equation System and Eliminations.
Lecture 23 Symmetric Encryption
Computer Security CS 426 Lecture 3
Encryption Schemes Second Pass Brice Toth 21 November 2001.
Block and Stream Ciphers1 Reference –Matt Bishop, Computer Security, Addison Wesley, 2003.
Block Cipher Transmission Modes CSCI 5857: Encoding and Encryption.
EE5552 Network Security and Encryption block 4 Dr. T.J. Owens CEng MIET Dr T. Itagaki MIET, MIEEE, MAES.
Chapter 2 Basic Encryption and Decryption. csci5233 computer security & integrity 2 Encryption / Decryption encrypted transmission AB plaintext ciphertext.
Modes of Operation. Topics  Overview of Modes of Operation  EBC, CBC, CFB, OFB, CTR  Notes and Remarks on each modes.
symmetric key cryptography
Códigos y Criptografía Francisco Rodríguez Henríquez A Short Introduction to Stream Ciphers.
Cryptography and Network Security Chapter 6. Multiple Encryption & DES  clear a replacement for DES was needed theoretical attacks that can break it.
Slide 1 Stream Ciphers uBlock ciphers generate ciphertext Ciphertext(Key,Message)=Message  Key Key must be a random bit sequence as long as message uIdea:
Chapter 2 – Elementary Cryptography  Concepts of encryption  Cryptanalysis  Symmetric (secret key) Encryption (DES & AES)(DES & AES)  Asymmetric (public.
One-Time Pad Or Vernam Cipher Sayed Mahdi Mohammad Hasanzadeh Spring 2004.
Chapter 20 Symmetric Encryption and Message Confidentiality.
CS555Spring 2012/Topic 51 Cryptography CS 555 Topic 5: Pseudorandomness and Stream Ciphers.
Stream Ciphers Making the one-time pad practical.
ITMS – 3153 Information Systems Security
Chapter 20 Symmetric Encryption and Message Confidentiality.
CS526: Information Security Prof. Sam Wagstaff September 16, 2003 Cryptography Basics.
Stream Cipher July 2011.
Elementary Cryptography  Concepts of encryption  Symmetric (secret key) Encryption (DES & AES)(DES & AES)  Asymmetric (public key) Encryption (RSA)(RSA)
Computer Security: Principles and Practice First Edition by William Stallings and Lawrie Brown Lecture slides by Lawrie Brown Chapter 2 – Cryptographic.
Multiple Encryption & DES  clearly a replacement for DES was needed Vulnerable to brute-force key search attacks Vulnerable to brute-force key search.
Chapter 9: Algorithms Types and Modes Dulal C. Kar Based on Schneier.
More About DES Cryptography and Network Security Reference: Sec 3.1 of Stallings Text.
McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Security.
Modes of Usage Dan Fleck CS 469: Security Engineering These slides are modified with permission from Bill Young (Univ of Texas) 11 Coming up: Modes of.
CRYPTANALYSIS OF STREAM CIPHER Bimal K Roy Cryptology Research Group Indian Statistical Institute Kolkata.
Computer Security Cryptography. Cryptography Now and Before  In the past – mainly used for confidentiality  Today –Still used for confidentiality –Data.
Vigenere Cipher For example, choose a word “GOLD” for a key. And, add “GOLDGOLDGOLD….” to your plaintext Plaintext: t o o m u c h h y p e Key : GOLDGOLDGOLD.
Lecture 23 Symmetric Encryption
Symmetric Cipher Model Plaintext input 1- encryption algorithm 2- secret key Encryption Cipher text output Cipher text input 1- Decryption algorithm 2-
Cipher Transmission and Storage Modes Part 2: Stream Cipher Modes CSCI 5857: Encoding and Encryption.
University of Malawi, Chancellor College
CS526Topic 2: Classical Cryptography1 Information Security CS 526 Topic 2 Cryptography: Terminology & Classic Ciphers.
CIM Cryptograhic Concepts Overview1 Cryptographic Concepts Overview Chapter 2- Cryptography and Network Security by Stallings for Details.
หัวข้อบรรยาย Stream cipher RC4 WEP (in)security LFSR CSS (in)security.
Block Cipher Encrypting a large message Electronic Code Book (ECB) message m1 m2 m3 m4 m5 m6 c1 c2 c3 c4 c5 c6 E E E Secret.
PART VII Security.
Introduction to Modern Symmetric-key Ciphers
ADVANCED ENCRYPTION STANDARDADVANCED ENCRYPTION STANDARD
Elect. Codebook, Cipher Block Chaining
Presentation transcript:

Stream Cipher

A stream cipher breaks the message M into successive characters or bits m 1, m 2,..., and enciphers each m i with the ith element k i of a key stream K=k 1 k 2...; that is, E K (M)=E k1 (m 1 )E k2 (m 2 )...

Periodic A stream cipher is periodic if the key stream repeats after d characters for some fixed d; otherwise, it is nonperiodic. Periodic: Rotor cipher, Hagelin cipher Nonperiodic: Vernam cipher (one-time pad), running-key cipher

Stream Cipher Two different approaches : synchronous methods self-synchronous methods

Synchronous Stream Cipher The key stream is generated independently of the message stream. If a ciphertext character is lost during transmission, the sender and receiver must resynchronize their key generators before they can proceed further.

Synchronous Stream Cipher Must ensure no part of the key stream is repeated Linear Feedback Shift Registers Output-block Feedback Mode Counter Method

Example of SSC

Self-synchronous Methods Each key character is derived from a fixed number n of preceding ciphertext characters. If a ciphertext character is lost or altered during transmission, the error propagates forward for n characters, but the cipher resynchronizes by itself after n correct ciphertext character have been received. Autokey cipher and Cipher Feedback Mode (CFM) Nonperiodic.

Example of Self-synchronous

Error Handling If errors are propagated by the decryption algorithm, applying error detecting codes before encryption provides a mechanism for authenticity.

Synchronous Stream Cipher key stream is generated independently of the message stream key stream must deterministic so the stream can be reproduced for decipherment. How to generate a random key stream? The starting stage of the key generator is initialized by a “ seed ” I 0.

Stream Cipher Stream ciphers are often breakable if the key stream repeats or has redundancy. To be un breakable, it must be a random sequence as long as the plaintext. Each element in the key alphabet should be uniformly distributed over the key stream, and there should be no long repeated subsequences or other patterns. No finite algorithm can generate truly random sequences.

LFSR LFSR (Linear Feedback Shift Register) shift register R=(r n, r n-1,..., r 1 ) “ tap ” sequence T=(t n, t n-1,..., t 1 ) t i and r i are binary digit bit r 1 is appended to the key stream, bits r n,...,r 2 are shifted right a new bit derived from T and R is inserted into the left end of the register.

LFSR Letting R ’ =(r n ’, r n-1 ’,... r 1 ’ ) denote the next state of R, we see that the computation of R ’ is thus: r i ’ =r i+1 i=1,...,n-1 r n ’ =TR=∑ n i=1 t i r i mod 2 R ’ =HR mod 2, where H is the nxn matrix. T(x)=t n x n + t n-1 x n t 1 x + 1 若 T(x) 為質多項式( primitive polynomial ) 則可以產生 2 n -1 個 sequence.

LFSR

Example of LFSR

LFSR The feedback loop attempts to simulate a one- time pad by transforming a short key I0 into a long pseudo-random sequence K. Unfortunately, the result is a poor approximation of the one-time pad.

Example of LFSR

Cryptanalysis of LFSR Known-plaintext attack 2n pairs of plaintext-ciphertext pairs M=m 1...m 2n, C=c 1...c 2n m i  c i =m i  (m i  k i )=ki, i=1,...,2n

Cryptanalysis of LFSR

Output-Block Feedback Mode weakness of LFSR is caused by the linearity of R ’ =HR mod 2 Nonlinear block ciphers such as the DES seem to be good candidates for this.

Output-block Feedback Mode

Counter Method Successive input blocks are generated by a simple counter. It is possible to generate the ith key character k i without generating the first i-1 key characters by setting the counter to I 0 + i – 1

Counter Method

Self-Synchronous Stream Cipher A Self-synchronous stream cipher derives each key character from a fixed number n of preceding ciphertext characters. Autokey Cipher and Cipher Feedback

Autokey Cipher An autokey cipher is one in which the key is derived from the message it enciphers. In Vigenere first cipher, the key is formed by appending the plaintext M= m 1 m 2... to a “ priming key ” character k 1 ; the ith key character (i>1) is thus given by k i =m i-1.

Autokey Cipher In Vigenere second cipher, the key is formed by appending each character of the ciphertext to the priming key k 1 ; that is, k i =c i-1 (i > 1)

Aotukey Cipher 缺點: it exposes the key in the ciphertext stream This problem is easily remedied by passing the ciphertext characters through a nonlinear block cipher to derive the key characters. Cipher Feedback mode (CFM)

The ciphertext characters participate in the feedback loop. It is sometimes called “ changing ”, because each ciphertext character is functionally dependent on (chained to) preceding ciphertext characters.

Example of CFM

亂數產生器 LFSR 線性同餘產生器 非線性亂數產生器 截切亂數產生器 數學計算產生器 分解因數法 離散對數法 二次剩餘法 質數法

LFSR

線性同餘產生器 x i =ax i-1 + b (mod m) x 0 為初值 a, b, m 為 KEY 條件: gcd(b,m)=1 對於每個能夠整除 M 之質數 p 而言, b=a-1 必須為 p 之 整數倍 IF 4|m then 4|b 缺點:產生之亂數可預測

非線性亂數產生器

截切亂數產生器

亂數產生器的安全性評估 好的亂數產生器具備之特性 週期長 不可預測性( Unpredictable ) 測試法: Chi-Square 測試法 Kolmogorov-Smirnov(KS) 測試法

Chi-Square 測試法

判斷標準