Presentation is loading. Please wait.

Presentation is loading. Please wait.

Cryptology I.Definitions II.Substitution Ciphers III.Transpositions Ciphers IV.The DES Algorithm V.Public-Key Cryptology.

Similar presentations


Presentation on theme: "Cryptology I.Definitions II.Substitution Ciphers III.Transpositions Ciphers IV.The DES Algorithm V.Public-Key Cryptology."— Presentation transcript:

1 Cryptology I.Definitions II.Substitution Ciphers III.Transpositions Ciphers IV.The DES Algorithm V.Public-Key Cryptology

2 Definitions code–thousands of words, phrases or symbols that form codewords that replace plaintext elements. cipher–a method of secret writing cryptography–art of devising ciphers cryptoanalysis–art of breaking ciphers cryptology–art of devising & breaking ciphers

3 Substitution Ciphers Monoalphabetic (26! possible ciphers) –Caesar cipher –Newspaper’s “Daily Cryptoquote” Polyalphabetic –Vigenere cipher –Playfair cipher

4 Caesar Cipher ABCDEFGHIJKLMNOPQRSTUVWXYZ |||||||||||||||||||||||||| DEFGHIJKLMNOPQRSTUVWXYZABC ATTACK AT DAWN would be encoded as DWWDFN DW GDZQ

5 Ark. Democrat Gazette, Dec. 3, 2001 Newspaper’s Daily Cryptoquote OGR MWRZNVMD YXMP GMC URRD M CQWUBX BY XNURZOQ MDK YZRRKBW.

6 Ark. Democrat Gazette, Dec. 3, 2001 Newspaper’s Daily Cryptoquote OGR MWRZNVMD YXMP GMC URRD M CQWUBX BY XNURZOQ MDK YZRRKBW. THE AMERICAN FLAG HAS BEEN A SYMBOL OF LIBERTY AND FREEDOM.

7 Percentages of the English Language Letters__ Diagrams__ Trigrams__ Words___ E13.05TH3.16THE4.72THE6.42 T9.02IN1.54ING1.42OF4.02 O8.21ER1.33AND1.13AND3.15 A7.81RE1.30ION1.00TO2.36 N7.28AN1.08ENT0.98A2.09 I6.77HE1.08FOR0.76IN1.77 R6.64AR1.02TIO0.75THAT1.25 S6.46EN1.02ERE0.69IS1.03 H5.85TI1.02HER0.68I0.94 D4.11TE0.98ATE0.66IT0.93 L3.60AT0.88VER0.63FOR0.77 C2.93ON0.84TER0.62AS0.76 F2.88HA0.84THA0.62WITH0.76 U2.77OU0.72ATI0.59WAS0.72 M2.62IT0.71HAT0.55HIS0.71 P2.15ES0.69ERS0.54HE0.71 Y1.51ST0.68HIS0.52BE0.63 W1.49OR0.68RES0.50NOT0.61 G1.39NT0.67ILL0.47BY0.57 B1.28HI0.66ARE0.46BUT0.56 V1.00EA0.64CON0.45HAVE0.55 K0.42VE0.64NCE0.45YOU0.55 X0.30CO0.59ALL0.44WHICH0.53 J0.23DE0.55EVE0.44ARE0.50 Q0.14RA0.55ITH0.44ON0.47 Z0.09RO0.55TED0.44OR0.45

8 Polyalphabetic Substitutions Use a different “alphabet” for each letter in the plaintext. Defeats attacks based upon common English frequency charts.

9 Vigenere Cipher ABCDEFGHIJKLMNOPQRSTUVWXYZ BCDEFGHIJKLMNOPQRSTUVWXYZA CDEFGHIJKLMNOPQRSTUVWXYZAB Key: COOKIEMONSTERCOOKIEMONSTER DEFGHIJKLMNOPQRSTUVWXYZABC Plaintext: ATTACKATDAWNPLEASE EFGHIJKLMNOPQRSTUVWXYZABCD FGHIJKLMNOPQRSTUVWXYZABCDE GHIJKLMNOPQRSTUVWXYZABCDEF 1. Use key letter to select row HIJKLMNOPQRSTUVWXYZABCDEFG 2. Use plaintext letter to select column IJKLMNOPQRSTUVWXYZABCDEFGH 3. Ciphertext letter is found at selected row & column JKLMNOPQRSTUVWXYZABCDEFGHI KLMNOPQRSTUVWXYZABCDEFGHIJ Ciphertext: CHHKKOMHQSPRGNSOCM LMNOPQRSTUVWXYZABCDEFGHIJK MNOPQRSTUVWXYZABCDEFGHIJKL NOPQRSTUVWXYZABCDEFGHIJKLM OPQRSTUVWXYZABCDEFGHIJKLMN PQRSTUVWXYZABCDEFGHIJKLMNO QRSTUVWXYZABCDEFGHIJKLMNOP RSTUVWXYZABCDEFGHIJKLMNOPQ STUVWXYZABCDEFGHIJKLMNOPQR TUVWXYZABCDEFGHIJKLMNOPQRS UVWXYZABCDEFGHIJKLMNOPQRST VWXYZABCDEFGHIJKLMNOPQRSTU WXYZABCDEFGHIJKLMNOPQRSTUV XYZABCDEFGHIJKLMNOPQRSTUVW YZABCDEFGHIJKLMNOPQRSTUVWX ZABCDEFGHIJKLMNOPQRSTUVWXY

10 Playfair Cipher 1)Group plaintext into pairs of letters. The letters ‘I’ and ‘J’ are considered to be the same letter. If any pair contains identical M B Q Z A letters insert a ‘Q’. If odd number of letters, add an ‘X’. D R G F S 2)If the 2 letters are in same row, take the pair of letters N H U E K to the right of the plaintext letters V T L W I 3)If the 2 letters are in the same column, take the pair of O X C P Y of letters below the plaintext letters. 4)If the 2 letters form the corners of a rectangle, Take the 2 letters at the opposite corners of the rectangle. The letter in the same row as the first plaintext letter is taken as the first cipher letter. Plaintext: Now is the time for all good men Grouped: NO WI ST HE TI ME FO RA LQ LG OQ OD ME NX Cipher: VM IV RI UK LV ZN DP SB CG CU CM MN ZN HO

11 Transposition Ciphers Railfence Transpositions Columnar Transpositions Double Transpositions

12 Railfence Transpositions Plaintext: IS THIS A GOOD CIPHER I I O I R Railfence: S H S G O C P E T A D H Ciphertext: IIOIRSHSGOCPETADH

13 Columnar Transpositions MEGABUCK PLEASETR Key determines number of columns. ANSFERON EMILLION Ciphertext is written using columns in DOLLARST alphabetical order of letters in key. OMYSWISS BANKACCO Ciphertext: AFLL SKSO SELA WAIA UNTSIXTWTOOS SCTCLNMO MANT ESIL YNTW OTWOABCDRNNT SOWDPAED OBUO ERIR ICXB

14 Double Transpositions POLITICSMONEY COMETOTHTTEDR Columns of first matrix are EAIDOFTHOFYMI entered into the second matrix. EPARTYAOAPC Columns of second matrix yield EEHHT the ciphertext. OT Plaintext: COME TO THE AID OF THE PARTY Ciphertext: DMPH TOAEO EYAH TFOET RICT

15 The DES Algorithm Data Encryption Standard was adopted by National Bureau of Standards in 1977 Plaintext is 1 st grouped into blocks of 64 bits 56-bit key 19 distinct stages –Initial key independent transposition –16 substitution steps using 56-bit key –Final 2 stages involve more transpositions Decryption uses same key with stages in reverse order

16 The DES Algorithm 56 bit key Initial Transposition Iteration 1 Iteration 2 Iteration 16 32 bit swap Final Transposition 64 bit plaintext 64 bit ciphertext 32 bits L i-1 + f(R i-1,K i ) L i-1 R i-1 Detail of one iteration

17 The DES Algorithm IBM’s original design used 128 bits U.S. National Security Agency requested reduction to 56 bits Reason for change has not been made public Reasons for particular choices for iteration functions has remained secret as well Requires key distribution

18 The DES Algorithm DES has been replaced with Triple DES This newer version uses a 112-bit key. AES (Advanced Encryption Standard) According to the U.S. Commerce Department all federal departments must use AES by May 29, 2002. This should influence commercial use as well. AES was developed by Belgian researchers and is based upon a 128-bit key.

19 Public-Key Cryptography (The RSA algorithm * is most famous example.) Relationship between the plaintext and the ciphertext * Named for developers Rivest, Shamir, and Adleman.

20 Public-Key Cryptography Selecting a public key: 1) Select 2 distinct primes, p & q (preferably extremely large). 2) Form the product, n = p * q. 3) Compute  = (p-1) * (q-1). 4) Select any integer e, with the property that GCD(e,  ) = 1. The pair of integers, e and n, comprise the public key. Example: If p = 3 and q = 11, then n = 33 and  = 20. We could choose e = 7, since GCD(7,20) = 1. Thus, our public key would be the pair: e = 7 and n=33.

21 Public-Key Cryptography Selecting a private key: Using the value for e and  found earlier, find d such that (e*d) mod  = 1. The pair of integers, d and n, comprise the private key. Continuing previous example: Since e = 7 and  = 20, d must be 3 (7*3 mod 20 = 1). Thus, our private key would be the pair: d = 3 and n = 33.

22 Public-Key Cryptography Ciphertext is generated using: c = p e mod n. TextNumericp 7 c = p 7 mod 33 S19893,871,73913 U211,801,088,54121 N14105,413,50420 D416,38416 A111 Y256,103,515,62531 Ciphertext: 13 21 20 16 01 31

23 Public-Key Cryptography Plaintext is recovered using: p = c d mod n. Numericc 3 c = p 3 mod 33Text 132,19719S 219,26121U 208,00014N 164,0964D 111A 3129,79125Y Plaintext: SUNDAY

24 Public-Key Cryptography The security is dependent upon the difficulty of finding the prime factors of a very large integer. No efficient algorithm has yet been found. Factoring 200 digit integers requires 4.3*10 6 years. Factoring 300 digit integers requires 5.5*10 12 years. Factoring 500 digit integers requires 4.7*10 22 years. (Assumes a computer that uses 1 nanosecond per instruction.)

25 Public-Key Cryptography E-mail signatures –A encodes his personal ID using his private key –If B can decode the personal ID using A’s public key, then B knows that A sent message. C = E(ID,private_key A ) P = D(C, public_key A )

26 Public-Key Cryptography Encrypted signatures. (1)A encodes personal ID using A’s private key. (2)A encodes result using B’s public key. (3)Upon receipt, B decodes by first using B’s private key. (4)B then verifies signature by decoding using A’s public key. A’s steps: C = E( E(ID,private A ), public B ) ; Transmit C B’s steps: Receive C ; P = D( D(C,private B ), public A ) If P equals A’s ID then B is confident that message came from A; furthermore A is protected because only B can decode the message.

27 Public-Key Cryptography PGP (Pretty Good Privacy) –Uses Public-Key cryptography –Used by many to encrypt their e-mail and implement signatures –Inexpensive (free version available for personal use) http://www.pgpi.org http://web.mit.edu/network/pgp.html http://www.pgp.com

28 References The Codebreakers, by David Kahn, 1973. Excellent account of the history of cryptology with special emphasis during World War II Cryptanalysis for Microcomputers, by Caxton C. Foster, 1982. Codes, Ciphers, and Computers, by Bruce Bosworth, 1982. Computer Networks, Andrew Tanenbaum, 1988. Cryptology, NSF Chautauqua Program taught by Robert E. Lewand at Christian Brothers University in Memphis, TN on June 28-30, 1998.


Download ppt "Cryptology I.Definitions II.Substitution Ciphers III.Transpositions Ciphers IV.The DES Algorithm V.Public-Key Cryptology."

Similar presentations


Ads by Google