Presentation is loading. Please wait.

Presentation is loading. Please wait.

Introduction to Cryptography and Security Mechanisms Dr Keith Martin McCrea 34901784 443099

Similar presentations


Presentation on theme: "Introduction to Cryptography and Security Mechanisms Dr Keith Martin McCrea 34901784 443099"— Presentation transcript:

1 Introduction to Cryptography and Security Mechanisms Dr Keith Martin McCrea 34901784 443099 keith.martin@rhul.ac.uk

2 Before we start…

3 Introduction to Cryptography and Security Mechanisms 2005 3 Quiz 1 Which of the following activities can cryptography not be used to provide in the electronic world? AEnsuring that only an intended recipient can obtain some information BEnsuring that information cannot be altered before it reaches an intended recipient CEnsuring that a sender of some information cannot later deny having sent the information DEnsuring that some received information was sent by the claimed sender

4 Introduction to Cryptography and Security Mechanisms 2005 4 Quiz 2 Which of the following attacks is the odd one out? ASending a forged message BDeleting the opening phrase of a message CReading a message that was not intended for you DIntercepting a message and destroying it before it gets to the intended recipient

5 Introduction to Cryptography and Security Mechanisms 2005 5 Quiz 3 Under the worst-case conditions for a symmetric cipher system, we assume that the attacker of a cipher system has access to: AThe encryption algorithm, the encryption key, all ciphertexts BAll ciphertexts, some plaintext/ciphertext pairs, the decryption key CSome plaintext/ciphertext pairs, the encryption algorithm, all previously used decryption keys DThe encryption algorithm, all ciphertexts, some plaintext/ciphertext pairs

6 Introduction to Cryptography and Security Mechanisms: Unit 4 Historical algorithms Dr Keith Martin McCrea 34901784 443099 keith.martin@rhul.ac.uk

7 Introduction to Cryptography and Security Mechanisms 2005 7 Learning Outcomes Describe a number of simple historical cipher systems Relate a number of historical cipher system to the basic model of a cipher system Appreciate the direction of historical advances in cipher system design Illustrate the properties of these historical cipher systems that make them unsuitable for modern use Formulate some essential basic design features for a modern cipher system

8 Introduction to Cryptography and Security Mechanisms 2005 8 Sections 1.Monoalphabetic ciphers 2.Historical advances

9 1. Monoalphabetic ciphers

10 Introduction to Cryptography and Security Mechanisms 2005 10 Ciphers in this unit Please note that all the ciphers in this unit are: Symmetric Operate on alphabetic characters Are not suitable for general modern use However, they allow us to: Illustrate the basic model of a cipher system Learn some basic design principles

11 Introduction to Cryptography and Security Mechanisms 2005 11 The Caesar Cipher The Caesar Cipher is clearly unsuitable for modern use! Identify at least three cryptographic weaknesses that result in the Caesar Cipher being regarded as insecure.

12 Introduction to Cryptography and Security Mechanisms 2005 12 The Simple Substitution Cipher The Simple Substitution Cipher is a considerable improvement on the Caesar Cipher What is the main improvement?

13 Introduction to Cryptography and Security Mechanisms 2005 13 Keyspace of the Substitution Cipher The key space of the Simple Substitution Cipher is approximately 4 x 10 26, that is: 400 000 000 000 000 000 000 000 000 Just how big is that? There are an estimated 10 sextillion (that’s 10 22 ) stars in our universe. That means that the Simple Substitution Cipher has about 40 000 times the number of keys than there are stars in our universe. The key space of DES is somewhere between 10 16 and 10 17. That’s a much smaller number – it’s only about 100 000 times the number of stars in our galaxy!

14 Introduction to Cryptography and Security Mechanisms 2005 14 Wise words Having a large key space is necessary to prevent an exhaustive key search, but it is not sufficient to guarantee the security of a cipher system. A large key is not a guarantee of security but a small key is a guarantee of insecurity. In other words (Martin Hellman’s, to be precise…)

15 Introduction to Cryptography and Security Mechanisms 2005 15 Letter frequency analysis The Substitution Cipher is broken very effectively by letter frequency analysis You obviously need to know some ciphertext to conduct this attack. Identify at least two other pieces of information that it would be useful to know in order to conduct an effective letter frequency analysis of the Simple Substitution Cipher.

16 Introduction to Cryptography and Security Mechanisms 2005 16 Four lessons 1.The Simple Substitution Cipher leaks information about the plaintext even before detailed letter frequency analysis has been conducted. 2.Knowing the context of the plaintext can be extremely important when conducting letter frequency analysis. 3.Letter frequency analysis really works! 4.It is not necessary to determine the entire key before being able to decrypt the ciphertext. The following four lessons can be learnt if you conduct Exercises 2, 3, 4 and 5 for this unit.

17 Introduction to Cryptography and Security Mechanisms 2005 17 Unicity distance The unicity distance of a cipher system is the number of ciphertext letters that you need before, given a ciphertext of that length, you can expect there to be only one meaningful plaintext and encryption key that could have been used to obtain that ciphertext. The unicity distance is a value that can be calculated from the statistical properties of the underlying plaintext language. For a Simple Substitution Cipher applied to English plaintexts, the unicity distance is usually regarded as being around 28 ciphertext letters.

18 Introduction to Cryptography and Security Mechanisms 2005 18 Unicity distance That’s the theory, so what about the practice? If you have 28 ciphertext characters from a Simple Substitution Cipher then you can be fairly sure that there is only one matching plaintext out there. Can you actually find it?

19 Introduction to Cryptography and Security Mechanisms 2005 19 Unicity distance In theoryNumber of ciphertext letters In practice Less than about 5 Between about 5 and 27 Around 28 = unicity distance Between 28 and about 200 More than about 200

20 2. Historical advances

21 Introduction to Cryptography and Security Mechanisms 2005 21 Advances on Simple Substitution Bearing in mind the lessons of the previous section, identify three types of cipher system design improvement that would make it harder to conduct single letter frequency analysis?

22 Introduction to Cryptography and Security Mechanisms 2005 22 Playfair Cipher The Playfair Cipher operates on pairs of letters (bigrams). The key is a 5x5 square consisting of every letter except J. Before encrypting, the plaintext must be transformed: Replace all J’s with I’s Write the plaintext in pairs of letters… …separating any identical pairs by a Z If the number of letters is odd, add a Z to the end

23 Introduction to Cryptography and Security Mechanisms 2005 23 Playfair Cipher: Encryption If two plaintext letters lie in the same row then replace each letter by the one on its “right” in the key square If two plaintext letters lie in the same column then replace each letter by the one “below” it in the key square Else, replace: –First letter by letter in row of first letter and column of second letter in the key square –Second letter by letter in column of first letter and row of second letter in the key square

24 Introduction to Cryptography and Security Mechanisms 2005 24 Playfair Cipher: Example STAND ERCHB KFGIL MOPQU VWXYZ GLOW WORM IK WT TW EO

25 Introduction to Cryptography and Security Mechanisms 2005 25 Playfair Cipher In what way has the Playfair Cipher defeated single letter frequency analysis? How might you try to decrypt a ciphertext that was encrypted using a Playfair Cipher, without knowing the key?

26 Introduction to Cryptography and Security Mechanisms 2005 26 English letter frequencies LetterNumberLetterNumberLetterNumber A 8.167B 1.492C2.782 D4.253E12.702F2.228 G2.015H 6.094I6.966 J0.153K 0.772L4.025 M2.406N 6.749O7.507 P1.929Q 0.095R5.987 S6.327T 9.056U2.758 V0.978W 2.360X0.150 Y1.974Z 0.074

27 Introduction to Cryptography and Security Mechanisms 2005 27 Histogram of letter frequencies

28 Introduction to Cryptography and Security Mechanisms 2005 28 Homophonic Coding A modification of the Simple Substitution Cipher The idea is to replace some plaintext letters with different ciphertext characters in order to confuse the ciphertext character frequency statistics.

29 Introduction to Cryptography and Security Mechanisms 2005 29 Homophonic Coding A possible homophonic code is as follows: Use a character alphabet of 1000. Use our table of letter frequencies: use 82 different characters to encode A use 15 different characters to encode B use 1 character to encode J, Q, Y and Z etc. How well do you think such a code will hold out against single letter frequency analysis? Do you think that such a code is suitable for adoption in a practical environment?

30 Introduction to Cryptography and Security Mechanisms 2005 30 Vigenère Cipher The Vigenère Cipher illustrates another important technique for defeating letter frequency analysis. What is it?

31 Introduction to Cryptography and Security Mechanisms 2005 31 Vigenère Cipher Make sure you understand how the Vigenère Cipher works by conducting Exercises 6, 7, 8 and 9 for this unit. How would you go about breaking the Vigenère Cipher?

32 Introduction to Cryptography and Security Mechanisms 2005 32 Summary A large key space alone does not guarantee security. It is possible to break a cipher system without first determining the key. The ciphertext produced by a cipher system should disguise the statistics of the plaintext alphabet. Effective techniques for disguising plaintext statistics include: –Increasing the size of the plaintext alphabet –Replacing plaintext characters with more than one different ciphertext character –Introducing positional dependence but these properties alone do not guarantee security.


Download ppt "Introduction to Cryptography and Security Mechanisms Dr Keith Martin McCrea 34901784 443099"

Similar presentations


Ads by Google