Vigvisual: a Visualization Tool for the Vigenère Cipher

Total Page:16

File Type:pdf, Size:1020Kb

Vigvisual: a Visualization Tool for the Vigenère Cipher VIGvisual: A Visualization Tool for the Vigenère Cipher Can Li, Jun Ma, Jun Tao, Melissa Keranen Chaoli Wang Jean Mayo, Ching-Kuang Department of Mathematical Department of Computer Shene Sciences Science & Engineering Department of Computer Michigan Technological University of Notre Dame Science University Notre Dame, IN Michigan Technological Houghton, MI [email protected] University [email protected] Houghton, MI {canli,junm,junt,jmayo,shene}@mtu.edu ABSTRACT Well designed pedagogical tools are very useful in help- This paper describes a visualization tool VIGvisual that helps ing students understand concepts and practice needed skills. students learn and instructors teach the Vigen`ere cipher. While there are tools available [1, 2, 9], most of them only The software allows the user to visualize both encryption provide interfaces for encryption and decryption without showing the process, and very few include cryptanalysis. and decryption through a variety of cipher tools. The demo VIGvisual mode is useful and efficient for classroom presentation. The is designed to address this issue by providing an practice mode allows the user to practice encryption and environment so that it can be used in the classroom and decryption. VIGvisual is quite versatile, providing support for self-study. It is able to animate the Vigen`ere cipher for both beginners learning how to encrypt and decrypt, with a variety of cipher tools, all of which are available for and also for the more advanced users wishing to practice students to practice encryption and decryption with error checking. Furthermore, VIGvisual also helps students learn cryptanalysis in the attack mode. Classroom evaluation of VIGvisual the tool was positive. how to break the Vigen`ere cipher. uses Kasiski’s method and the Index of Coincidence method for keyword length estimation, and the χ2 method with frequency graphs Categories and Subject Descriptors for keyword recovery. To the best of our knowledge, only [2] K.3.2 [Computers and Education]: Computer and In- offers a similar capability; however, it is just an interactive formation Science Education—Computer science education, cryptanalysis environment. VIGvisual goes one step further information systems education by offering a more comprehensive visualization component with tools and animation not only for cryptanalysis but also for beginners to learn and practice the Vigen`ere cipher. General Terms In the following, Section 2 discusses the course in which Algorithms, Security VIGvisual was used and evaluated, Section 3 presents an overview of VIGvisual, Section 4 has our findings from a class- Keywords room evaluation, and Section 5 is our conclusion. Cryptography; visualization 2. COURSE INFORMATION VIGvisual was used in a cryptography course, MA3203 In- 1. INTRODUCTION troduction to Cryptography, that is offered out of the De- The Vigen`ere cipher appeared in the 1585 book Traict´e partment of Mathematical Sciences at Michigan Technolog- des Chiffres by Blaise de Vigen`ere. It is a simple cipher, ical University. It is a junior level course that gives a basic but for nearly three centuries the Vigen`ere cipher had not introduction to the field of cryptography. This course cov- been broken until Friedrich W. Kasiski published his 1863 ers classical cryptography, the Data Encryption Standard book [7]. Charles Babbage also broke the cipher with a (DES), the Advanced Encryption Standard (AES), the RSA similar technique in 1846, although he never published his algorithm, discrete logarithms, hash functions, and elliptic work. Currently, the Vigen`ere cipher has become a standard curve cryptography. For each cryptosystem, we study how it topic in many textbooks [4, 8, 10]. was designed, why it works, how one may attack the system, and how it has been used in practice. Understanding classical cryptography is essential to any Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee providedthat copies are not made or distributed introductory cryptography course, and one of the major clas- for profit or commercial advantage and that copies bear this notice and the full cita- sical cryptosystems is the Vigen`ere cipher. The Vigen`ere ci- tion on the first page. Copyrights for componentsof this work owned by others than pher is a generalization of the monoalphabetic shift cipher, ACM must be honored. Abstracting with credit is permitted. To copyotherwise, or re- which has a keyword length of one. This cipher is very dif- publish, to post on servers or to redistribute to lists, requires prior specific permission ficult to present in class because of the long pieces of text and/or a fee. Request permissions from [email protected]. that need to be used in order to illustrate the algorithm in a ITiCSE’15, July 6–8, 2015, Vilnius, Lithuania. VIGvisual Copyright c 2015 ACM 978-1-4503-3440-2/15/07...$15.00. meaningful way. Because was used in the course, DOI: http://dx.doi.org/10.1145/2729094.2742589. students were able to see the encryption algorithm demon- strated quickly. This allowed for a more thorough study of the most interesting aspects of the cipher, which are the decryption techniques and attacks. The attack component covers Kasiski’s method, the index of coincidence method, and the χ2 method. 3. SOFTWARE DESCRIPTION VIGvisual supports Linux, MacOS and Windows and has three modes, Demo, Practice and Attack. The Demo mode helps the user visualize the process of encryption and decryp- tion with animation. The Practice mode allows the user to practice encryption and decryption with error checking. The Attack mode offers a chance for the user to learn how (a) Vigen`ere Table to break the Vigen`ere cipher with Kasiski’s and the Index of Coincidence (IOC) methods, followed by the χ2 method to recover the unknown keyword. 3.1 The Demo Mode VIGvisual starts with the Demo mode (Figure 1). The top portion has input fields for plaintext, keyword and cipher- (c) Saint Cyr Slide text. The user starts a new session with New and enters a plaintext-keyword pair or a ciphertext-keyword pair, or uses RandPT and RandCT to automatically generate a random plaintext-keyword pair and a random ciphertext-keyword (b) Cipher Disk pair. This is followed by clicking Encrypt or Decrypt to encrypt or decrypt the entered message. By default, the key- Figure 2: Cipher Tools word is repeated and aligned with the original word struc- ture. Clicking Align switches to the view of breaking the can be moved left or right. The table rows and columns, plaintext/ciphertext to align with the keyword length. the movable disk and the bottom slide change according to the triplet of plaintext letter, keyword letter and ciphertext letter. Thus, the instructor has a demo tool for classroom use and the students have a clear view of how the Vigen`ere cipher performs encryption and decryption. 3.2 The Practice Mode Click the Practice tab to enter the Practice mode (Fig- ure 3). All three tools are available. The user clicks Encrypt or Decrypt to start a new session, and uses Random to gener- ate a random plaintext-keyword or ciphertext-keyword pair, New to start a new session, Redo to redo the current session, and Align to align the plaintext or ciphertext using the key- word length. Then, the user enters a keyword (if Random is Figure 1: Screenshot of the Demo Mode not chosen) followed by the expected ciphertext or plaintext. The user may stop at anywhere and click the Check button The user uses Start and Stop to start and stop an anima- to check the result. Incorrect letters are marked in red or tion, the slider to select an animation speed, and Pre and with question marks if the positions are left as blank. The Next to move to the previous and next position. The cor- Answer field shows the correct answer. responding plaintext letter, keyword letter and ciphertext letter are shown in different colors in an animation. The user may bring up one or more tools with buttons Ta- ble, Disk and Slide. Figure 2(a) shows the Vigen`ere table. The plaintext letter under consideration and its column use one color, the corresponding keyword letter and its row use a different one, and the ciphertext letter is at the intersec- tion of the plaintext column and keyword row. The cipher disk has two concentric disks stacked together (Figure 2(b)). The bottom (resp., top) disk, the stationary (resp., movable) one, represents the plaintext (resp., ciphertext) letters and is fixed (resp., rotatable). The user rotates the movable disk so that the keyword letter aligns with the letter A of the stationary disk. Then, the corresponding plaintext and ci- phertext letters align together. Figure 2(c) has the Saint Cyr Slide. The upper part is fixed while the lower part Figure 3: Screenshot of the Practice Mode 3.3 The Attack Mode Click the Attack button to enter the Attack mode. The user clicks Random to randomly generate a ciphertext or New to start a new session and enter a new ciphertext (Fig- ure 4). The process of breaking a message has two steps: keyword length estimation and keyword recovery. This pro- cess may not always be successful, and several iterations may be needed. VIGvisual has several Hint buttons in all windows under the Attack tab, each of which brings up a hint win- dow to either explain what the window and/or algorithm is or provide a chance for the user to do simple exercises. (a) Top Portion (b) Bottom Portion Figure 5: Screenshot of the Kasiski Window by the same letter with an IOC close to 0.068. To apply this idea, for each 1 ≤ k ≤ n, we may divide the ciphertext into k cosets, calculate the IOC of each coset, and calculate the average of the k IOC values.
Recommended publications
  • IMPLEMENTASI ALGORITMA CAESAR, CIPHER DISK, DAN SCYTALE PADA APLIKASI ENKRIPSI DAN DEKRIPSI PESAN SINGKAT, Lumasms
    Prosiding Seminar Ilmiah Nasional Komputer dan Sistem Intelijen (KOMMIT 2014) Vol. 8 Oktober 2014 Universitas Gunadarma – Depok – 14 – 15 Oktober 2014 ISSN : 2302-3740 IMPLEMENTASI ALGORITMA CAESAR, CIPHER DISK, DAN SCYTALE PADA APLIKASI ENKRIPSI DAN DEKRIPSI PESAN SINGKAT, LumaSMS Yusuf Triyuswoyo ST. 1 Ferina Ferdianti ST. 2 Donny Ajie Baskoro ST. 3 Lia Ambarwati ST. 4 Septiawan ST. 5 1,2,3,4,5Jurusan Manajemen Sistem Informasi, Universitas Gunadarma [email protected] Abstrak Short Message Service (SMS) merupakan salah satu cara berkomunikasi yang banyak digunakan oleh pengguna telepon seluler. Namun banyaknya pengguna telepon seluler yang menggunakan layanan SMS, tidak diimbangi dengan faktor keamanan yang ada pada layanan tersebut. Banyak pengguna telepon seluler yang belum menyadari bahwa SMS tidak menjamin integritas dan keamanan pesan yang disampaikan. Ada beberapa risiko yang dapat mengancam keamanan pesan pada layanan SMS, diantaranya: SMS spoofing, SMS snooping, dan SMS interception. Untuk mengurangi risiko tersebut, maka dibutuhkan sebuah sistem keamanan pada layanan SMS yang mampu menjaga integritas dan keamanan isi pesan. Dimana tujuannya ialah untuk menutupi celah pada tingkat keamanan SMS. Salah satu penanggulangannya ialah dengan menerapkan algoritma kriptografi, yaitu kombinasi atas algoritma Cipher Disk, Caesar, dan Scytale pada pesan yang akan dikirim. Tujuan dari penulisan ini adalah membangun aplikasi LumaSMS, dengan menggunakan kombinasi ketiga algoritma kriptografi tersebut. Dengan adanya aplikasi ini diharapkan mampu mengurangi masalah keamanan dan integritas SMS. Kata Kunci: caesar, cipher disk, kriptografi, scytale, SMS. PENDAHULUAN dibutuhkan dikarenakan SMS mudah digunakan dan biaya yang dikeluarkan Telepon seluler merupakan salah untuk mengirim SMS relatif murah. satu hasil dari perkembangan teknologi Namun banyaknya pengguna komunikasi.
    [Show full text]
  • Amy Bell Abilene, TX December 2005
    Compositional Cryptology Thesis Presented to the Honors Committee of McMurry University In partial fulfillment of the requirements for Undergraduate Honors in Math By Amy Bell Abilene, TX December 2005 i ii Acknowledgements I could not have completed this thesis without all the support of my professors, family, and friends. Dr. McCoun especially deserves many thanks for helping me to develop the idea of compositional cryptology and for all the countless hours spent discussing new ideas and ways to expand my thesis. Because of his persistence and dedication, I was able to learn and go deeper into the subject matter than I ever expected. My committee members, Dr. Rittenhouse and Dr. Thornburg were also extremely helpful in giving me great advice for presenting my thesis. I also want to thank my family for always supporting me through everything. Without their love and encouragement I would never have been able to complete my thesis. Thanks also should go to my wonderful roommates who helped to keep me motivated during the final stressful months of my thesis. I especially want to thank my fiancé, Gian Falco, who has always believed in me and given me so much love and support throughout my college career. There are many more professors, coaches, and friends that I want to thank not only for encouraging me with my thesis, but also for helping me through all my pursuits at school. Thank you to all of my McMurry family! iii Preface The goal of this research was to gain a deeper understanding of some existing cryptosystems, to implement these cryptosystems in a computer programming language of my choice, and to discover whether the composition of cryptosystems leads to greater security.
    [Show full text]
  • Historical Ciphers • A
    ECE 646 - Lecture 6 Required Reading • W. Stallings, Cryptography and Network Security, Chapter 2, Classical Encryption Techniques Historical Ciphers • A. Menezes et al., Handbook of Applied Cryptography, Chapter 7.3 Classical ciphers and historical development Why (not) to study historical ciphers? Secret Writing AGAINST FOR Steganography Cryptography (hidden messages) (encrypted messages) Not similar to Basic components became modern ciphers a part of modern ciphers Under special circumstances modern ciphers can be Substitution Transposition Long abandoned Ciphers reduced to historical ciphers Transformations (change the order Influence on world events of letters) Codes Substitution The only ciphers you Ciphers can break! (replace words) (replace letters) Selected world events affected by cryptology Mary, Queen of Scots 1586 - trial of Mary Queen of Scots - substitution cipher • Scottish Queen, a cousin of Elisabeth I of England • Forced to flee Scotland by uprising against 1917 - Zimmermann telegram, America enters World War I her and her husband • Treated as a candidate to the throne of England by many British Catholics unhappy about 1939-1945 Battle of England, Battle of Atlantic, D-day - a reign of Elisabeth I, a Protestant ENIGMA machine cipher • Imprisoned by Elisabeth for 19 years • Involved in several plots to assassinate Elisabeth 1944 – world’s first computer, Colossus - • Put on trial for treason by a court of about German Lorenz machine cipher 40 noblemen, including Catholics, after being implicated in the Babington Plot by her own 1950s – operation Venona – breaking ciphers of soviet spies letters sent from prison to her co-conspirators stealing secrets of the U.S. atomic bomb in the encrypted form – one-time pad 1 Mary, Queen of Scots – cont.
    [Show full text]
  • The Mathemathics of Secrets.Pdf
    THE MATHEMATICS OF SECRETS THE MATHEMATICS OF SECRETS CRYPTOGRAPHY FROM CAESAR CIPHERS TO DIGITAL ENCRYPTION JOSHUA HOLDEN PRINCETON UNIVERSITY PRESS PRINCETON AND OXFORD Copyright c 2017 by Princeton University Press Published by Princeton University Press, 41 William Street, Princeton, New Jersey 08540 In the United Kingdom: Princeton University Press, 6 Oxford Street, Woodstock, Oxfordshire OX20 1TR press.princeton.edu Jacket image courtesy of Shutterstock; design by Lorraine Betz Doneker All Rights Reserved Library of Congress Cataloging-in-Publication Data Names: Holden, Joshua, 1970– author. Title: The mathematics of secrets : cryptography from Caesar ciphers to digital encryption / Joshua Holden. Description: Princeton : Princeton University Press, [2017] | Includes bibliographical references and index. Identifiers: LCCN 2016014840 | ISBN 9780691141756 (hardcover : alk. paper) Subjects: LCSH: Cryptography—Mathematics. | Ciphers. | Computer security. Classification: LCC Z103 .H664 2017 | DDC 005.8/2—dc23 LC record available at https://lccn.loc.gov/2016014840 British Library Cataloging-in-Publication Data is available This book has been composed in Linux Libertine Printed on acid-free paper. ∞ Printed in the United States of America 13579108642 To Lana and Richard for their love and support CONTENTS Preface xi Acknowledgments xiii Introduction to Ciphers and Substitution 1 1.1 Alice and Bob and Carl and Julius: Terminology and Caesar Cipher 1 1.2 The Key to the Matter: Generalizing the Caesar Cipher 4 1.3 Multiplicative Ciphers 6
    [Show full text]
  • Index-Of-Coincidence.Pdf
    The Index of Coincidence William F. Friedman in the 1930s developed the index of coincidence. For a given text X, where X is the sequence of letters x1x2…xn, the index of coincidence IC(X) is defined to be the probability that two randomly selected letters in the ciphertext represent, the same plaintext symbol. For a given ciphertext of length n, let n0, n1, …, n25 be the respective letter counts of A, B, C, . , Z in the ciphertext. Then, the index of coincidence can be computed as 25 ni (ni −1) IC = ∑ i=0 n(n −1) We can also calculate this index for any language source. For some source of letters, let p be the probability of occurrence of the letter a, p be the probability of occurrence of a € b the letter b, and so on. Then the index of coincidence for this source is 25 2 Isource = pa pa + pb pb +…+ pz pz = ∑ pi i=0 We can interpret the index of coincidence as the probability of randomly selecting two identical letters from the source. To see why the index of coincidence gives us useful information, first€ note that the empirical probability of randomly selecting two identical letters from a large English plaintext is approximately 0.065. This implies that an (English) ciphertext having an index of coincidence I of approximately 0.065 is probably associated with a mono-alphabetic substitution cipher, since this statistic will not change if the letters are simply relabeled (which is the effect of encrypting with a simple substitution). The longer and more random a Vigenere cipher keyword is, the more evenly the letters are distributed throughout the ciphertext.
    [Show full text]
  • A Hybrid Cryptosystem Based on Vigenère Cipher and Columnar Transposition Cipher
    International Journal of Advanced Technology & Engineering Research (IJATER) www.ijater.com A HYBRID CRYPTOSYSTEM BASED ON VIGENÈRE CIPHER AND COLUMNAR TRANSPOSITION CIPHER Quist-Aphetsi Kester, MIEEE, Lecturer Faculty of Informatics, Ghana Technology University College, PMB 100 Accra North, Ghana Phone Contact +233 209822141 Email: [email protected] / [email protected] graphy that use the same cryptographic keys for both en- Abstract cryption of plaintext and decryption of cipher text. The keys may be identical or there may be a simple transformation to Privacy is one of the key issues addressed by information go between the two keys. The keys, in practice, represent a Security. Through cryptographic encryption methods, one shared secret between two or more parties that can be used can prevent a third party from understanding transmitted raw to maintain a private information link [5]. This requirement data over unsecured channel during signal transmission. The that both parties have access to the secret key is one of the cryptographic methods for enhancing the security of digital main drawbacks of symmetric key encryption, in compari- contents have gained high significance in the current era. son to public-key encryption. Typical examples symmetric Breach of security and misuse of confidential information algorithms are Advanced Encryption Standard (AES), Blow- that has been intercepted by unauthorized parties are key fish, Tripple Data Encryption Standard (3DES) and Serpent problems that information security tries to solve. [6]. This paper sets out to contribute to the general body of Asymmetric or Public key encryption on the other hand is an knowledge in the area of classical cryptography by develop- encryption method where a message encrypted with a reci- ing a new hybrid way of encryption of plaintext.
    [Show full text]
  • Cipher Disk A
    Make It@Home: Cipher Disk A. Materials 1 Tack 1 Small Cipher Disk 1 Large Cipher Disk 1 Small Eraser Scissors B. Directions 1. Download and print the Cipher Disk.pdf document. 2. Cut out the two cipher disks. 3. Put the smaller disk on top of the larger disk and stick the tack thru the center of both disks. 4. Stick the sharp end of the tack into the eraser. This will prevent you from sticking yourself while turning the disks to make your ciphers. C. Encrypting A Code 1. Pick a letter from the smaller disk on top - this will be used as the KEY that will be shared between you and your friends to encrypt and decrypt the message. Once you have picked a letter from the smaller disk, line it up with the “A” from the larger disk. Example Key: LARGE DISK: A SMALL DISK: M KEY = A:M 2. Begin encrypting each letter of your secret message. Find the first letter of your message on the larger disk and write down the cipher letter which appears underneath it on the smaller disk. In the example below, A=M, B=L, C=K, etc. LARGE DISK: ABCDEFGHIJKLMNOPQRSTUVWXYZ SMALL DISK: MLKJIHGFEDCBAZYXWVUTSRQPON 3. Continue finding each letter until your message has been encrypted. Once you are finished, send your friend the encrypted message and KEY seperately. PLAINTEXT: MAKING CODES IS FUN CIPHERTEXT: AMCEZG KYJIU EU HSZ NOTE: Make sure your friend knows the KEY so they can use their Cipher Disk to break the code. For a super secure cipher, create a new KEY every time you send a message OR change the KEY every time you encrypt a letter.
    [Show full text]
  • Shift Cipher Substitution Cipher Vigenère Cipher Hill Cipher
    Lecture 2 Classical Cryptosystems Shift cipher Substitution cipher Vigenère cipher Hill cipher 1 Shift Cipher • A Substitution Cipher • The Key Space: – [0 … 25] • Encryption given a key K: – each letter in the plaintext P is replaced with the K’th letter following the corresponding number ( shift right ) • Decryption given K: – shift left • History: K = 3, Caesar’s cipher 2 Shift Cipher • Formally: • Let P=C= K=Z 26 For 0≤K≤25 ek(x) = x+K mod 26 and dk(y) = y-K mod 26 ʚͬ, ͭ ∈ ͔ͦͪ ʛ 3 Shift Cipher: An Example ABCDEFGHIJKLMNOPQRSTUVWXYZ 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 • P = CRYPTOGRAPHYISFUN Note that punctuation is often • K = 11 eliminated • C = NCJAVZRCLASJTDQFY • C → 2; 2+11 mod 26 = 13 → N • R → 17; 17+11 mod 26 = 2 → C • … • N → 13; 13+11 mod 26 = 24 → Y 4 Shift Cipher: Cryptanalysis • Can an attacker find K? – YES: exhaustive search, key space is small (<= 26 possible keys). – Once K is found, very easy to decrypt Exercise 1: decrypt the following ciphertext hphtwwxppelextoytrse Exercise 2: decrypt the following ciphertext jbcrclqrwcrvnbjenbwrwn VERY useful MATLAB functions can be found here: http://www2.math.umd.edu/~lcw/MatlabCode/ 5 General Mono-alphabetical Substitution Cipher • The key space: all possible permutations of Σ = {A, B, C, …, Z} • Encryption, given a key (permutation) π: – each letter X in the plaintext P is replaced with π(X) • Decryption, given a key π: – each letter Y in the ciphertext C is replaced with π-1(Y) • Example ABCDEFGHIJKLMNOPQRSTUVWXYZ πBADCZHWYGOQXSVTRNMSKJI PEFU • BECAUSE AZDBJSZ 6 Strength of the General Substitution Cipher • Exhaustive search is now infeasible – key space size is 26! ≈ 4*10 26 • Dominates the art of secret writing throughout the first millennium A.D.
    [Show full text]
  • Classic Crypto
    Classic Crypto Classic Crypto 1 Overview We briefly consider the following classic (pen and paper) ciphers o Transposition ciphers o Substitution ciphers o One-time pad o Codebook These were all chosen for a reason o We see same principles in modern ciphers Classic Crypto 2 Transposition Ciphers In transposition ciphers, we transpose (scramble) the plaintext letters o The scrambled text is the ciphertext o The transposition is the key Corresponds to Shannon’s principle of diffusion (more about this later) o This idea is widely used in modern ciphers Classic Crypto 3 Scytale Spartans, circa 500 BC Wind strip of leather around a rod Write message across the rod T H E T I M E H A S C O M E T H E W A L R U S S A I D T O T A L K O F M A N Y T H I N G S When unwrapped, letters are scrambled TSATAHCLONEORTYTMUATIESLHMTS… Classic Crypto 4 Scytale Suppose Alice and Bob use Scytale to encrypt a message o What is the key? o How hard is it for Trudy to break without key? Suppose many different rod diameters are available to Alice and Bob… o How hard is it for Trudy to break a message? o Can Trudy attack messages automatically—without manually examining each putative decrypt? Classic Crypto 5 Columnar Transposition Put plaintext into rows of matrix then read ciphertext out of columns For example, suppose matrix is 3 x 4 o Plaintext: SEETHELIGHT o Ciphertext: SHGEEHELTTIX Same effect as Scytale o What is the key? Classic Crypto 6 Keyword Columnar Transposition For example o Plaintext: CRYPTOISFUN o Matrix 3 x 4 and keyword MATH o Ciphertext:
    [Show full text]
  • Decrypt Cryptotexts: GBLVMUB JOGPSNBUJLZ VMNIR RPNBMZ EBMFLP OFABKEFT Decrypt: VHFUHW GH GHXA VHFUHW GH GLHX, VHFUHW GH WURLV VH
    PROLOGUE - I. Decrypt cryptotexts: Part IV GBLVMUB JOGPSNBUJLZ Secret-key cryptosystems VMNIR RPNBMZ EBMFLP OFABKEFT prof. Jozef Gruska IV054 4. Secret-key cryptosystems 2/99 PROLOGUE - II. CHAPTER 4: SECRET-KEY (SYMMETRIC) CRYPTOGRAPHY Decrypt: In this chapter we deal with some of the very old, or quite old, classical (secret-key or symmetric) cryptosystems and their cryptanalysis that were primarily used in the pre-computer era. VHFUHW GH GHXA These cryptosystems are too weak nowadays, too easy to break, especially VHFUHW GH GLHX, with computers. However, these simple cryptosystems give a good illustration of several of the VHFUHW GH WURLV important ideas of the cryptography and cryptanalysis. Moreover, most of them can be very useful in combination with more modern VHFUHW GH WRXV. cryptosystem - to add a new level of security. prof. Jozef Gruska IV054 4. Secret-key cryptosystems 3/99 prof. Jozef Gruska IV054 4. Secret-key cryptosystems 4/99 BASICS CRYPTOLOGY - HISTORY + APPLICATIONS Cryptology (= cryptography + cryptanalysis) has more than four thousand years long history. Some historical observation People have always had fascination with keeping information away from others. Some people – rulers, diplomats, military people, businessmen – have always had needs to keep some information away from others. BASICS Importance of cryptography nowadays Applications: cryptography is the key tool to make modern information transmission secure, and to create secure information society. Foundations: cryptography gave rise to several new key concepts of the foundation of informatics: one-way functions, computationally perfect pseudorandom generators, zero-knowledge proofs, holographic proofs, program self-testing and self-correcting, . prof. Jozef Gruska IV054 4. Secret-key cryptosystems 5/99 prof.
    [Show full text]
  • Cryptology: an Historical Introduction DRAFT
    Cryptology: An Historical Introduction DRAFT Jim Sauerberg February 5, 2013 2 Copyright 2013 All rights reserved Jim Sauerberg Saint Mary's College Contents List of Figures 8 1 Caesar Ciphers 9 1.1 Saint Cyr Slide . 12 1.2 Running Down the Alphabet . 14 1.3 Frequency Analysis . 15 1.4 Linquist's Method . 20 1.5 Summary . 22 1.6 Topics and Techniques . 22 1.7 Exercises . 23 2 Cryptologic Terms 29 3 The Introduction of Numbers 31 3.1 The Remainder Operator . 33 3.2 Modular Arithmetic . 38 3.3 Decimation Ciphers . 40 3.4 Deciphering Decimation Ciphers . 42 3.5 Multiplication vs. Addition . 44 3.6 Koblitz's Kid-RSA and Public Key Codes . 44 3.7 Summary . 48 3.8 Topics and Techniques . 48 3.9 Exercises . 49 4 The Euclidean Algorithm 55 4.1 Linear Ciphers . 55 4.2 GCD's and the Euclidean Algorithm . 56 4.3 Multiplicative Inverses . 59 4.4 Deciphering Decimation and Linear Ciphers . 63 4.5 Breaking Decimation and Linear Ciphers . 65 4.6 Summary . 67 4.7 Topics and Techniques . 67 4.8 Exercises . 68 3 4 CONTENTS 5 Monoalphabetic Ciphers 71 5.1 Keyword Ciphers . 72 5.2 Keyword Mixed Ciphers . 73 5.3 Keyword Transposed Ciphers . 74 5.4 Interrupted Keyword Ciphers . 75 5.5 Frequency Counts and Exhaustion . 76 5.6 Basic Letter Characteristics . 77 5.7 Aristocrats . 78 5.8 Summary . 80 5.9 Topics and Techniques . 81 5.10 Exercises . 81 6 Decrypting Monoalphabetic Ciphers 89 6.1 Letter Interactions . 90 6.2 Decrypting Monoalphabetic Ciphers .
    [Show full text]
  • Cryptanalysis of a Vigenère
    Security of Networks 2011- 2012 (10) Cryptanalysis of a Vigenère: A Vigenère cipher can be broken using the techniques of breaking a shift cipher as soon as the length of the keyword is known. This is because each repeat of a letter in the keyword corresponds to a single shift cipher. There are two ways to determine the keylength. Kasiski Test (1863 - Major F.W. Kasiski, German cryptologist): Length of keyword is a divisor of the gcd of the distances between identical strings of length at least 3. Friedman Test (1925, Colonel William Frederick Friedman (1891-1969)) also called the Kappa Test: The index of coincidence of a message is the probability that a randomly chosen pair of letters in the message are equal. If the message has length th n and ni denotes the number of occurrences of the i letter then the index, denoted by I, is given by: Now we can also calculate this index for any language source if we know the probabilities of occurrence of each of the letters. Thus, if pa is the probability of occurrence of the letter a, for example, then we get: Using our knowledge of these probabilities we can easily calculate that IEnglish ~ 0.065 and if we had a random source of English letters then IRandom ~ 0.038 (= 1/26). This index can give information about a message. For instance, if a ciphered message was either a transposition or a monoalphabetic substitution then one would expect to have IMessage ~ IEnglish , but if a polyalphabetic substitution was used then this value should decrease (but Dr.
    [Show full text]