Top Banner
CRYPTOGRAPHY lecture 3 Wednesday
24

CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

Dec 19, 2015

Download

Documents

Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

CRYPTOGRAPHY

lecture 3Wednesday

Page 2: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

Secure transmission

Steganography cryptography

Transposition Substitution

Monoalphabetic

Page 3: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

The difference between substitution and transposition is that in:Subtitution: each letter retains its position but changes its identity,Transposition: each letter retains its identity but changes its position.

Example 3

Page 4: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

HW #2: Caesar shift problems

2. KENKMOC PYBDEXK TEFKD

3.MHILYLZAZBHLXBPZXBLMVYABUHLHWWPBZJSHBKPBZJHLJBZKPJABTHYJHUBTLZAULBAYVU

Page 5: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

• QK MEJXNEJJ ZMEVTJ Q YVNGEZ VNHKE KVMMHY JXMEEXJ HB FHWWNEJXHKE WEKEVXP XPE PVNH HB V JXMEEX NVTI Q XRMK TA FHNNVM XH XPE FHNZ VKZ ZVTI YPEK TA EAEJ YEME JXVWWEZ WA XPE BNVJP HB V KEHK NQDPX XPVX JINQX XPE KQDPX VKZ XHRFPEZ XPE JHRKZ HB JQNEKFE

Page 6: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

new ciphers

1. MPV DIZ DFF EPUQH D WZIM QUSZ NPY EZSUBJZIUQH GZTTDHZT UT UC KVQ

2. HGJUBQPU V HY H CVP AHT BA DHQG ZVYBT V KB GVZJRT JB BJURW YQZVE JBB CQJ ZVTER VJ VZ YBZJGS EGHZZVEHG VJ KBRZ TBJ VTZDVWR HTS EVDURWR

Page 7: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

new ciphers

1. HGJUBQPU V HY H CVP AHT BA DHQG ZVYBT V KB GVZJRT JB BJURW YQZVE JBB CQJ ZVTER VJ VZ YBZJGS EGHZZVEHG VJ KBRZ TBJ VTZDVWR HTS EVDURWR

Page 8: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

Mono-alphabetic Substitution Cipher

• Allow any permutation of the alphabet• Each letter is replaced by a different

letter or symbol• Key = permutation (still need to decide

on a key and exchange this information in a secure way).

• 26! Possibilities– What does this mean?

Page 9: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

Frequency Analysis

Page 10: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

HW # 3: Reading

Review: The Code Book chapter 1 & read chapter 2 p. 45-51Find websites on substitution ciphers and frequency analysisBegin research for a 5-7 page essay on “Why are substitution and transposition ciphers obsolete, and when did they become so.” Due on Monday in class.

Page 11: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

(in class): Substitution cipher

SK BKGKC FBTKCHZWBT W ZXUBA HM SKOO,

WBT EWQK UZ MFC MSB, WH SXKB SK XWGK

TUHJMGKCKT UZ DMC MFCHKOGKH

Page 12: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

(in class): Substitution cipher

CGXTOUNZL NQ UDOU HDNTD BCJONLQ

HDCL ZLC DOQ WZBMZUUCL CACBEUDNLM

DC KCOBLCG NL QTDZZK.

Page 13: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

HW # 3: Substitution cipher

UWZEZ VTPUW ZBEIK WVRWT UPUZT UWPUV YZFZE PAIQB

SISVT RBFZE TZJPR UNIKW PUUWZ GAVFZ ETZVT YBEPA

SKWIV UVTWZ EZVUK VNNVA TUPAU NISVT PCCZP EPASQ ZEZCN PRZSQ ITBOZ UWVAX ZFZAO BEZQV HPEEZ PASVA

ZJCNV RPQNZ UWZEZ VTPAB UWZEU WZBEI KWVRW TUPUZ

TUWPU UWVTW PTPNE ZPSIW PCCZA ZS

Page 14: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

HW # 3: Substitution cipher

VBIPA PMBIE DQFJI DTBQR WPIUI PMJAM HIEDR IJPIE IJJWF YTDFD PIGID GLIMD NAJJD LUIMB IGDLA MAEWL HWPNJ VBAEB BWUIE DPPIE MINMB IRVAM BWPDM BIFWP NMDWJ JQRIW RDPKM BIGDV IFJDT MBIIW FMBMB IJIGW FWMIW PNISQ WLJMW MADPM DVBAE BMBIL WVJDT PWMQF IWPND TPWMQ FIJKD NIPMA MLIMB IRWNI EIPMF IJGIE MMDMB IDGAP ADPJD TRWPO APNFI SQAFI JMBWM MBIYJ BDQLN NIELW FIMBI EWQJI JVBAE BARGI LMBIR MDMBI JIGWF WMADP

Page 15: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

HW # 3: Substitution cipher

NBSQF VKLUV GZSGN BGVZQ SZMCR GZUVG RHABI FHSVW XGZMTVLMVE LQSGV LSGVQ TRUVM RGLKC GRHCV ZQZMC NRMVG VXZMM LSNRH HSGVQ VMVUV QDZHZ AZQTZ RMAVS SVQCQ RUVMG RHGVZ QSRMN VPVVO HNVZM CGRNR MLMVN BGVZQ SRMGR NGRHS GLFTG SHZMC HVMHV HTFRC VHGVK LUVHN BGVZQ SELQL MXVRS DZHGR HLDMR XGVQR HGGRH AVXZF HVRMN VRSAR CVHGR HGVZQ SGRHD LFMCQ VXVRU VCEQL NNBHR TGSNB GVZQS DZHDL FMCVC DRSGG RHDLF MCVCG VZQSE LQZHE QLNNV LMGRN GRHGF QSCRC KRTGS HLHSR KKNVS GLFTG SRMNV GRHGF QSCRC HNZQS ALSGV JFZKG FQSRM SGRHX GZMTV HLFTG SLFQA KRHHN BSQFV KLUVG ZSGNB GVZQS ZMCRG ZUVGR H

Page 16: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

HW # 3: Substitution cipher

826821526251162515231172625148114  14826232621111161411615142623722526  14826168262326172213262514826232621111  11221614231252212142221622161827182625  8262326116252026232671782152625148114  14826232621111161411615142623722526  252610711112512011 

Page 17: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

Websites which help

http://www.geocities.com/cryptogramcorner/

http://cs.colgate.edu/faculty/nevison/Core139Web/tools/substitution.html

Page 18: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

What can we do to improve the substitution cipher?In 1460 Battista Alberti wrote an essay on what he believed to be a new form of cipher: use two or more cipher alphabets alternately to encrypt a message.

ABCDEFGHIJKLMNOPQRSTUVWXYZ plain text

GHIJKLMNOPQRSTUVWXYZABCDEF cipher1

RSTUVWXYZABCDEFGHIJKLMNOPQ cipher2

Let’s encrypt the statement

IT IS WAY TOO EARLY IN THE DAY TO BE DOING THISOK OJ CRE KUF KRXCE ZT KNV JRE KU SK UUZTX ZYOJ12 34 567 890 12345 67 890 123 45 67 89012 3456

Page 19: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

What can we do to improve the substitution cipher?Alberti was followed by Johannes Trithemius (born 1462) and Giovanni Porta (born 1535) who developed his ideas. Finally, Vigenere put all these ideas together. Let’s take a whole table of Caesar shift alphabets. The first row will have a Caesar shift of 1, the second of 2, etc. Each letter in the plaintext message can be enciphered by a different row.

Page 20: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

Vigenere cipher:Start with a table of Caesar shift alphabets.

A B C D E F G H I J K L M N O P Q R S T U V W X Y Z B C D E F G H I J K L M N O P Q R S T U V W X Y Z A C D E F G H I J K L M N O P Q R S T U V W X Y Z A BD E F G H I J K L M N O P Q R S T U V W X Y Z A B CE F G H I J K L M N O P Q R S T U V W X Y Z A B C DF G H I J K L M N O P Q R S T U V W X Y Z A B C D EG H I J K L M N O P Q R S T U V W X Y Z A B C D E FH I J K L M N O P Q R S T U V W X Y Z A B C D E F GI J K L M N O P Q R S T U V W X Y Z A B C D E F G HJ K L M N O P Q R S T U V W X Y Z A B C D E F G H IK L M N O P Q R S T U V W X Y Z A B C D E F G H I JL M N O P Q R S T U V W X Y Z A B C D E F G H I J K M N O P Q R S T U V W X Y Z A B C D E F G H I J K L N O P Q R S T U V W X Y Z A B C D E F G H I J K L M O P Q R S T U V W X Y Z A B C D E F G H I J K L M N P Q R S T U V W X Y Z A B C D E F G H I J K L M N O Q R S T U V W X Y Z A B C D E F G H I J K L M N O P R S T U V W X Y Z A B C D E F G H I J K L M N O P Q S T U V W X Y Z A B C D E F G H I J K L M N O P Q R T U V W X Y Z A B C D E F G H I J K L M N O P Q R S U V W X Y Z A B C D E F G H I J K L M N O P Q R S T V W X Y Z A B C D E F G H I J K L M N O P Q R S T U W X Y Z A B C D E F G H I J K L M N O P Q R S T U V X Y Z A B C D E F G H I J K L M N O P Q R S T U V W Y Z A B C D E F G H I J K L M N O P Q R S T U V W X Z A B C D E F G H I J K L M N O P Q R S T U V W X Y

Page 21: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

A B C D E F G H I J K L M N O P Q R S T U V W X Y Z B C D E F G H I J K L M N O P Q R S T U V W X Y Z A C D E F G H I J K L M N O P Q R S T U V W X Y Z A BD E F G H I J K L M N O P Q R S T U V W X Y Z A B CE F G H I J K L M N O P Q R S T U V W X Y Z A B C DF G H I J K L M N O P Q R S T U V W X Y Z A B C D EG H I J K L M N O P Q R S T U V W X Y Z A B C D E FH I J K L M N O P Q R S T U V W X Y Z A B C D E F GI J K L M N O P Q R S T U V W X Y Z A B C D E F G HJ K L M N O P Q R S T U V W X Y Z A B C D E F G H IK L M N O P Q R S T U V W X Y Z A B C D E F G H I JL M N O P Q R S T U V W X Y Z A B C D E F G H I J K M N O P Q R S T U V W X Y Z A B C D E F G H I J K L N O P Q R S T U V W X Y Z A B C D E F G H I J K L M O P Q R S T U V W X Y Z A B C D E F G H I J K L M N P Q R S T U V W X Y Z A B C D E F G H I J K L M N O Q R S T U V W X Y Z A B C D E F G H I J K L M N O P R S T U V W X Y Z A B C D E F G H I J K L M N O P Q S T U V W X Y Z A B C D E F G H I J K L M N O P Q R T U V W X Y Z A B C D E F G H I J K L M N O P Q R S U V W X Y Z A B C D E F G H I J K L M N O P Q R S T V W X Y Z A B C D E F G H I J K L M N O P Q R S T U W X Y Z A B C D E F G H I J K L M N O P Q R S T U V X Y Z A B C D E F G H I J K L M N O P Q R S T U V W Y Z A B C D E F G H I J K L M N O P Q R S T U V W X Z A B C D E F G H I J K L M N O P Q R S T U V

W X Y

SAVEMEPLEASE plain text

CRYPTOGRAMCR keyword

URTTFSVCEMUV enciphered

The first letter, S is encrypted using the row beginning with CThe second letter, A is encryted using the row beginning with RThe third letter, V is encrypted using the row beginning with YThe fourth letter, E, is encrypted using the row beginning with P.And so on . . .

You can use http://www.simonsingh.net/The_Black_Chamber/v_square.html

Page 22: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

Vigenere cipher

• Frequency analysis does not apply.• Enormous number of possible keys• The Vigenere cipher is a

polyalphabetic cipher.• It was then neglected for 2 centuries

– it is hard to break but also hard to encrypt.

Page 23: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

Vigenere cipher: the unbreakable code

• At first glance the Vigenère Cipher appears to be unbreakable, due to its use of up to 26 different cipher alphabets. Ciphers like this, which use more than one cipher alphabet are known as Polyalphabetic Ciphers. These can be incredibly difficult to decipher, because of their resistance to letter frequency analysis. Indeed, over time, the Vigenère cipher became known as 'Le Chiffre Undechiffrable', or 'The Unbreakable Cipher'.

This slide and the next few copied directly from Simon Singh’s website.

Page 24: CRYPTOGRAPHY lecture 3 Wednesday. Secure transmission Steganographycryptography TranspositionSubstitution Monoalphabetic.

Ciphers• Monoalphabetic ciphers: each letter in the

plaintext is encoded by only one letter from the cipher alphabet, and each letter in the cipher alphabet represents only one letter in the plaintext.

• Polyalphabetic ciphers: each letter in the plaintext can be encoded by any letter in the cipher alphabet, and each letter in the cipher alphabet may represent different letters from the plaintext each time it appears.