110 likes | 197 Views
Expert System for Analyzing Simple Ciphers: Properties of Cipher Texts. Carolyn Rucci Advisor: Ralph Morelli 1 year project. Overview. What are letter frequencies and index of coincidence. What index of coincidence and patterns of letter frequencies does each cipher follow? Transposition
E N D
Expert System for Analyzing Simple Ciphers:Properties of Cipher Texts Carolyn Rucci Advisor: Ralph Morelli 1 year project
Overview • What are letter frequencies and index of coincidence. • What index of coincidence and patterns of letter frequencies does each cipher follow? • Transposition • Caesar • Affine • Vigenère • Playfair • Summary • What next?
Review of Letter Frequencies and Index of Coincidence • Letter Frequencies 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 monographic frequency distribution of normal alphabet • Index of Coincidence thisisatestoftheindexofcoincidenceinmessages thisisatestoftheindexofcoincidenceinmessagesthi 5matches / 44letters ~ 11%
Transposition Cipher • Simply rearranges the letters same letters present in cipher text as plain text • Reverse text: there once was a cat named fred derf deman tac a saw ecno ereht • Conclusion: Frequency distribution will be the same.
Caesar • Each cipher letter corresponds to the plain text letter three after it. • Plain Alphabet: 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 • Caesar Alphabet: d e f g h i j k l m n o p q r s t u v w x y z a b c the quick fox jumped over the lazy dog wkh txlfn ira mxpshg ryhu wkh odcb grj Shift 3 • Conclusion: Frequency distribution will match when shifted three spots.
Affine • Each cipher letter corresponds to exactly one plain text letter. C = (aP + b) mod 26 • Ex: a=4 and b=5: A = (4*1 + 5) mod 26 = 9 I • Conclusion: Same frequencies will be present but in a random order.
Vigenère A B C D E F … X Y Z A B C D E F … X Y Z B C D E F G … Y Z A C D E F GH … Z A B : Y Z A B C D ... V W X Z A B C D E … W X Y • Many cipher alphabets created based on keyword. CIPHER • Conclusion: No pattern to letter frequencies. • Find identical sequences of letters. • the frog jumping the fence… • dlc bffj tyklwej dlc bsefo… • Calculate interval bt/w sequences • If interval between two occurrences has common factor length of keyword A B C D E F … X Y Z K L M N O P … H I J E F G H I J K … B C D Y Z A B C D … V W X W X Y Z A B … U V W O P Q R S T … L M N R S T U V W … O P Q D E F G H I … A B C K E Y W O R D
Playfair • Mixed alphabetic sequence of 25 letters is written into a 5x5 square (J normally omitted). Case1: 2corners replace w/other corners Case2: same row replace w/letters to right Case3: same column replace w/letters below • Conclusion: No pattern of letter frequencies.
Review of Letter Frequencies and Index of Coincidence • Letter Frequencies 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 monographic frequency distribution of normal alphabet • Index of Coincidence thisisatestoftheindexofcoincidenceinmessages thisisatestoftheindexofcoincidenceinmessagesthi 5matches / 44letters ~ 11%
What Next? • Finalize criteria for distinguishing between Vigenère and Playfair ciphers. • Create a Java program that: • Examines index of coincidence and patterns of frequencies • Uses this information to determine which cipher was used