The Making and Breaking of Secret Ciphers. The next competition is scheduled for April 18 – 22, 2013

Slides:



Advertisements
Similar presentations
CLASSICAL ENCRYPTION TECHNIQUES
Advertisements

Making “Good” Encryption Algorithms
Cryptology Terminology and Early History. Cryptology Terms Cryptology –The science of concealing the meaning of messages and the discovery of the meaning.
Cryptology  Terminology  plaintext - text that is not encrypted.  ciphertext - the output of the encryption process.  key - the information required.
1 Codes, Ciphers, and Cryptography-Ch 2.1 Michael A. Karls Ball State University.
Cryptography Cryptography: art or science of keeping messages secret Cryptology: branch of mathematics that studies the mathematical foundations of cryptographic.
Classical Cryptography
Cryptanalysis of the Playfair Cipher Using an Evolutionary Algorithm By: Benjamin Rhew.
1 Day 04- Cryptography Acknowledgements to Dr. Ola Flygt of Växjö University, Sweden for providing the original slides.
CYPHER INDEX n Introduction n Background n Demo INTRODUCTION n Cypher is a software toolkit designed to aid in the decryption of standard (historical)
Chapter 2 Basic Encryption and Decryption (part B)
CPSC CPSC 3730 Cryptography Chapter 2 Classical Encryption Techniques.
CS526Topic 2: Classical Cryptography1 Information Security CS 526 Topic 2 Cryptography: Terminology & Classic Ciphers.
Cryptographic Algorithms Course information General Concepts Introductory examples Terminology Classical cryptography Cryptanalysis.
Classical Encryption Techniques
Chapter 2 – Classical Encryption Techniques
3.1 Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. Chapter 3 Traditional Symmetric-Key Ciphers.
Cryptanalysis. The Speaker  Chuck Easttom  
Classical Monoalphabetic Ciphers Day 2. Keyword cipher Select a keyword, if the keyword has any repeated letters, drop all but the first occurrence. Write.
Chapter 2 Basic Encryption and Decryption. csci5233 computer security & integrity 2 Encryption / Decryption encrypted transmission AB plaintext ciphertext.
Classical Encryption Techniques
Cryptography. Secret (crypto) Writing (graphy) –[Greek word] Practice and study of hiding information Concerned with developing algorithms for: –Conceal.
Cryptography Programming Lab
Cryptography & Cryptanalysis
CSCI 5857: Encoding and Encryption
Chapter 2 Classical Encryption Techniques. Symmetric Encryption n conventional / private-key / single-key n sender and recipient share a common key n.
Chapter 2 – Elementary Cryptography  Concepts of encryption  Cryptanalysis  Symmetric (secret key) Encryption (DES & AES)(DES & AES)  Asymmetric (public.
Section 2.1: Shift Ciphers and Modular Arithmetic The purpose of this section is to learn about modular arithmetic, which is one of the fundamental mathematical.
Lec. 5 : History of Cryptologic Research II
Introduction to Cryptography
Cryptography and Network Security (CS435) Part Two (Classic Encryption Techniques)
Day 18. Concepts Plaintext: the original message Ciphertext: the transformed message Encryption: transformation of plaintext into ciphertext Decryption:
Section 2.1: Shift Ciphers and Modular Arithmetic Practice HW from Barr Textbook (not to hand in) p.66 # 1, 2, 3-6, 9-12, 13, 15.
CIT 380: Securing Computer SystemsSlide #1 CIT 380: Securing Computer Systems Classical Cryptography.
Rather than just shifting the alphabet Could shuffle (jumble) the letters arbitrarily Each plaintext letter maps to a different random cipher text letter.
Symmetric-Key Cryptography
Module :MA3036NI Cryptography and Number Theory Lecture Week 3 Symmetric Encryption-2.
2002 Networking Operating Systems (CO32010) 1. Operating Systems 2. Processes and scheduling 3.
Announcements: Please pass in Assignment 1 now. Please pass in Assignment 1 now. Assignment 2 posted (when due?) Assignment 2 posted (when due?)Questions?
CSCI 5857: Encoding and Encryption
Classic Cryptography History. Some Basic Terminology plaintext - original message ciphertext - coded message cipher - algorithm for transforming plaintext.
Introduction to Ciphers Breno de Medeiros. Cipher types From “Cipher”, Wikipedia article.
Abstract: Cryptology is a combination of the processes of keeping a message secret (cryptography) and trying to break the secrecy of that message (cryptoanalysis).
Elementary Cryptography  Concepts of encryption  Symmetric (secret key) Encryption (DES & AES)(DES & AES)  Asymmetric (public key) Encryption (RSA)(RSA)
Cryptography (Traditional Ciphers)
Data Security and Encryption (CSE348) 1. Lecture # 4 2.
1 Cryptanalysis Four kinds of attacks (recall) The objective: determine the key ( Herckhoff principle ) Assumption: English plaintext text Basic techniques:
Traditional Symmetric-Key Ciphers
Security in Computing Cryptography (Traditional Ciphers)
Data Security and Encryption (CSE348) 1. Lecture # 3 2.
Section 2.3: Substitution Ciphers
K. Salah1 Cryptography Module I. K. Salah2 Cryptographic Protocols  Messages should be transmitted to destination  Only the recipient should see it.
Network Security Lecture 13 Presented by: Dr. Munam Ali Shah.
Encryption. LEARNING OBJECTIVES: BY THE END OF THE LESSON YOU SHOULD KNOW. What encryption is and why it is important The basics of encryption techniques.
1 Classical Encryption Techniques. 2 Symmetric cipher model –Cryptography –Cryptanalysis Substitution techniques –Caesar cipher –Monoalphabetic cipher.
Cryptography services Lecturer: Dr. Peter Soreanu Students: Raed Awad Ahmad Abdalhalim
CS480 Cryptography and Information Security Huiping Guo Department of Computer Science California State University, Los Angeles 4. Traditional and Modern.
CRYPTOGRAPHY G REEK WORD MEANING “ SECRET WRITING ”
Substitution Ciphers.
Chapter 2 Basic Encryption and Decryption
Asad Gondal Ali Haider Mansoor
Classical Techniques: Substitution
Communication Security
Cryptography and Network Security
CS4780 Cryptography and Information Security
Outline Some Basic Terminology Symmetric Encryption
Encryption and Decryption
Information Security IT423
Running Key Cipher The security of polyalphabetic substitution cipher reside in key length. In running-key cipher, the length of key must be equal the.
Symmetric Encryption or conventional / private-key / single-key
Presentation transcript:

The Making and Breaking of Secret Ciphers

The next competition is scheduled for April 18 – 22,

 Challenge 1 (solution) Challenge 1solution  Challenge 2 (solution) Challenge 2solution  Challenge 3 (solution) Challenge 3solution

 Challenge 1 (solution) Challenge 1solution  Challenge 2 (solution) Challenge 2solution  Challenge 3 (solution) Challenge 3solution

 In a transposition cipher the letters in the plaintext are just transposed or “mixed up”  The letter frequencies would reflect that of the usual language

THAMATIEMANICIALISABANNDMDAINAOORKROK MLOFOINGLARABATCKCCHWHITTISNEDHERINAR W TFTMAXFTMBVBTGBLTUEBGWFTGBGTWTKDKHH FEHHDBGZYHKTUETVDVTMPABVABLGMMAXKXW TKPBG

THAMA TIEMA NICIA LISAB ANNDM DAINA OORKR OKMLO FOING LARAB ATCKC CHWHI TTISN EDHER INARW

THAMA TIEMA NICIA LISAB ANNDM AMATH EMATI CIANI SABLI NDMAN DAINA OORKR OKMLO FOING LARAB INADA RKROO MLOOK INGFO RABLA ATCKC CHWHI TTISN EDHER INARW CKCAT WHICH ISNTT HERED ARWIN A MATHEMATICIAN IS A BLIND MAN IN A DARK ROOM LOOKING FOR A BLACK CAT WHICH ISN’T THERE ----DARWIN

 Write the plaintext across the rows read the ciphertext down the columns  Encrypt using 4 columns (problem 2): Spring has sprung 1234 SPRI NGHA SSPR UNG CIPHERTEXT: SNSUPGSNRHPGIAR X CIPHERTEXT: SNSUPGSNRHPGIARX

 We can also permute the columns before we write down the plaintext: CODE SPRI NGHA SSPR UNG CDEO SRIP NHAG SPRS UGN CIPHERTEXT: SNSURHPGIARPGSN CIPHERTEXT: SNSUPGSNRHPGIAR

2012 Cipher challenge 2 IRADFE RMWSAE EETXAP EX

IRADFE RMWSAE EETXAP EX XX A P E

IRADFE RMWSAE EETXAP EX I F W EA R E S E P A R A T E DMEXX

 2012 Cipher challenge 2 continued eofoatutwtathbttherwteyixhnedxedlgxsolex (40 characters) Try to break it (Problem 3) oeunidrewobmicoaluxrlmaksettnootnrseeiotnhoo (44 characters) eaattpgrsteutuacrrnteediedaotewnisasntitrthofeyuet rvhteihnsetmroeifsncss (72 characters)

 DECRYPT: (Assume rows were not permuted.) TOQOIEOUTOEHFUFDQTAHTETATEUHREESHRHSAEE HNUEEEILSOYUMSSSSTQFPS Guess the number of columns & check (there are online applets for this)  OR Look: TOQOIEOUTOEHFUFDQTAHTETATEUHREESHRHSAEE HNUEEEILSOYUMSSSSTQFPS

We either have 5 full rows or 4 full rows and one partial row. There are 61 letters. Since 61 is not divisible by 5 we have 4 full rows and a partial. 61 = 4 x So we have 4 rows of 15 columns and the last row just has one column TE OO QU O I

 TOQOIEOUTOEHFUFDQTAHTETATEUHREESHRH SAEEHNUEEEILSOYUMSSSSTQFPS  This doesn’t look promising TE OU TEEEREUIYSQ OO E F A T U E H E E LU SF QU H D H A H S S H E SMS P OT F Q T T R H A N EOSTS I

TOQOIEOUTOEHFUFDQTAHTETATEUHREESHRH SAEEHNUEEEILSOYUMSSSSTQFPS TH OF QU O I E O U T O E So we have 11 full rows or 10 full rows and one partial row. Since 61 is not divisible by 11 we have 10 full rows and one partial: 61 = 10x6 + 1 So if this is correct, we have 6 columns.

TOQOIEOUTOEHFUFDQTAHTETATEUHREESHRH SAEEHNUEEEILSOYUMSSSSTQFPS THESUM OFTHES QUARES OFTHES IDESIS EQUALT OTHESQ UAREOF THEHYP OTENUS E

 Easy: itothrheeirinea  Harder: mwrhooeasuantltdpdloerimoavapterlhrheet  (Hint available on last page of handout)

Each letter of the alphabet is replaced by a different letter ABCDEFGHIJKLMNOPQRSTUVWXYZ VWXYZABCDEFGHIJKLMNOPQRSTU SIMPLE SHIFT ABCDEFGHIJKLMNOPQRSTUVWXYZ HOBAVPIZMENTUDWJSXCYKRGQLF RANDOM PERMUTATION

 Brute force  Frequency Analysis  Same plaintext is always replaced by the same ciphertext  Crib – a known word in the plaintext

IWXHXHIDDTPHNNDJHWDJASCDIQTJHXCVPRDB EJITGIDHDAKT tm

MB M HKDO SOOA KSQO NX ROO BLFNHOF, MN WKR XAQC S OZKLRO M RNXXV XA NHO RHXLQVOFR XB JMKANR Frequency analysis: Most common letters: O, R, S, N, M Most common English letters: E T A O I N S H R D L U Single letter words: I, A Common two letter words: of, to, in, it, is, be, as, at, so, we, he, by, or, on, do, if, me, my, up, an, go, no, us, am You try it (problem 5)

RDWQSQVDWPZCXNWZODCIKQWUWQVNSVYWPZIWN QWPWNNKXJOZXZQWLWZLGWVZMSNNZGUWVDW LZGSVSPKGYKQMNRDSPDDKUWPZQQWPVWMVDWI RSVDKQZVDWXKQMVZKNNCIWKIZQBVDWLZRWXNZO VDWWKXVDVDWNWLKXKVWKQMWACKGNVKVSZQVZ RDSPDVDWGKRNZOQKVCXWKQMZOQKVCXWNBZM WQVSVGWVDWIKMWPWQVXWNLWPVVZVDW ZLSQSZQNZOIKQFSQMXWACSXWNVDKVVDWJNDZCGM MWPGKXWVDWPKCNWNRDSPDSILWGVDWIVZVDWNWLKXKVSZQ Frequency analysis of ciphertext: w: v :d : z : k : q : n : s : x : p : m : g : c :i : l : r : o : u : a : y : b : j : f : t : h : e Most common English letters: E T A O I N S H R D L U Most common double letters: SS, EE, TT, FF, LL, MM, OO Most common digraphs: th er on an re he in ed nd ha at en es of or nt ea ti to it st io le is ou ar as de rt ve

RDWQSQVDWPZCXNWZODCIKQWUWQVNSVYWPZIWN QWPWNNKXJOZXZQWLWZLGWVZMSNNZGUWVDW LZGSVSPKGYKQMNRDSPDDKUWPZQQWPVWMVDWI RSVDKQZVDWXKQMVZKNNCIWKIZQBVDWLZRWXNZO VDWWKXVDVDWNWLKXKVWKQMWACKGNVKVSZQVZ RDSPDVDWGKRNZOQKVCXWKQMZOQKVCXWNBZM WQVSVGWVDWIKMWPWQVXWNLWPVVZVDW ZLSQSZQNZOIKQFSQMXWACSXWNVDKVVDWJNDZCGM MWPGKXWVDWPKCNWNRDSPDSILWGVDWIVZVDWNWLKXKVSZQ Frequency analysis of ciphertext: w: v :d : z : k : q : n : s : x : p : m : g : c :i : l : r : o : u : a : y : b : j : f : t : h : e Most common English letters: E T A O I N S H R D L U Most common digraphs: th er on an re he in ed nd ha at en es of or nt ea ti to it st io le is ou ar as de rt ve

KEY: K E Y K E Y E PLAIN: T R Y T H I S D V W D G W D Finish encrypting (problem 6)

KEY: K E Y Cipherext D A M T Finish decrypting (problem 7) T W O

 Waioerkjmmupagrmkopokjfpoijm  rkrorkrorkrorkrkrodkoork  Same letters in ciphertext need not correspond to same letters in plaintext

BYIRL BFMVG SXFEJ FJLXA MSVZI QHENK FIFCY JJRIF SEXRV CICDT EITHC BQVXS GWEXF PZHHT JGSPL HUHRP FDBPX NLMFV TFMIG RBZJT XIGHT JDAMW VMSFX LHFMS UXSDG EZDIE PCZLK LISCI JIWSI HTJVE VWVFM VWISO DFKIE QRQVL EPVHM YZSRW CIMZG LWVQQ RAWRT ZFKYV HOZIF JRDHG WVWKR RQSKM XOSFM VQEGS OJEXV HGBJT XXRHT JFTMQ WASJS JPOZP ZRHUS CZZVI VHTFK XLHME MFYPG RQHCE VHHTJ TEYVS EBYMG KWYUV PXKSY YFXLH GQURV EWWAS

jprwsttiqrugmyzfnvhcnscffnyjufybnqznubvqiftjujln sxrayedzbtxcmcytmbubrwcffnyjufybnqznrugmyzfn vhcnszenyqwcpmzejar Hint code length 3 jprwsttiqrugmyzfnvhcnscffnyjufybnqznubvqiftjujlnsxrayedzbtxcmcytmbubrwcffnyjufybnqznrugmyzfnvhcnszenyqwcpmzejarjprwsttiqrugmyzfnvhcnscffnyjufybnqznubvqiftjujlnsxrayedzbtxcmcytmbubrwcffnyjufybnqznrugmyzfnvhcnszenyqwcpmzejar

jprwsttiqrugmyzfnvhcnscffnyjufybnqznubvqiftjujlnsxrayedzbtxcmcytmbubrwcffnyjufybnqznrugmyzfnvhcnszenyqwcpmzejarjprwsttiqrugmyzfnvhcnscffnyjufybnqznubvqiftjujlnsxrayedzbtxcmcytmbubrwcffnyjufybnqznrugmyzfnvhcnszenyqwcpmzejar jwtrmfhsfjyquqtjsadtmtuwfjyqrmfhsnwmj Most frequent: j psiuynccnubzbijlxyzxcmbcnubzuynczycza Most frequent: c rtqgzvnfyfnnvfunrebcybrfyfnngzvneqper Most frequent: n

 The most common English letters are  E T A O I N S H R  Finish filling out the chart  Try to make a word  Check your guess by trying to decrypt (problem 8) ETAOINS J C N FQJ Y J

 The most common English letters are  E T A O I N S H R  Candidate 3 letter keywords:  FUN, RUN, ETAOINS JFQJVBWR CYJCOUPK NJUNZFAV

 jprwsttiqrugmyzfnvhcnscffnyjufybnqznubvqiftjuj lnsxrayedzbtxcmcytmbubrwcffnyjufybnqznrugm yzfnvhcnszenyqwcpmzejar  ERS/Vigenere.html ERS/Vigenere.html

JITTE RBUG

 Try #9

 Description from Wikipedia Description from Wikipedia

 Any plaintext letter can be replaced by up to 5 different ciphertext letters.  Every ciphertext letter could have come from up to 5 different plaintext letters.  About 2/3 of the time one would expect to use the “rectangle” substitution scheme (note: this is symmetric – pt  CT implies that CT  pt.  with 1/6 of the time, row and 1/6 of the time, column (not symmetric).  If “ab”  “OR”, what do you know about about “ba”?

PB PM ON HM PD NM IR IY FH KP AV UQ OI DO LB DZ QD GC YM IO KU KN DP PK IY BO CN RP PC HQ XN PF BO PT KL ZN NQ TF PE PF UK TN HT ON NU BI NQ CZ BW DY RI TF GU AF RZ Crib: “thatalittlelight”

 Look at the crib: “ thatalittlelight ”  It must have been paired like: th at al it tl el ig ht  Which is nice since: th at al it tl el ig ht

1 3 PB PM ON HM PD NM IR IY FH KP AV UQ OI DO th at LB DZ QD GC YM IO KU KN DP PK IY BO CN RP al it tl el ig ht PC HQ XN PF BO PT KL ZN NQ TF PE PF UK TN HT ON NU BI NQ CZ BW DY RI TF GU AF RZ Can you start building the key?

1: th  OI to hi t t o o h i h i 3: at  DO ad to a a d d o t t o 4: it  DZ id tz i i d d z t t z 5: tl  QD tq ld t t q q d l l d Only way to combine: ddvd

i h | d a l t o q | z Have: 6: el  GC eg lc e e g g c l l c 7: ig  YM iy gm i i y y m g g m 2: al  LB alb a l b Add in: Now, add 6 & 7: Two ways to add in 6&7: vh or dd. c don’t like! or lclc

h i | a-l-b d o-q t | z Have: Need to add: e g c l & i y m g c c Where? e e g y mfk n u v w x

p h y s i c a l b d e f g k m n o q r t u v w x z

1.Letter Frequency Analysis Calculator and Affine Cipher Calculator: Shift Cipher calculator: A tool to help with monoalphabetic substitution ciphers: Applet for cryptanalysis of the Vigenere Cipher: Most common letters, doubles, two letter words, etc: