{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

sol1-12 - CMPT 404 Cryptograph and Protocols Outline...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
CMPT 404 — Cryptograph and Protocols Outline Solutions to Exercises on Exercises on Probability and Perfect Secu- rity. 1. The text was encrypted using a substitution cipher. Find the plaintext and explain the steps you took to find it. Punctuation marks are removed from the text. This is a quote from “The Hobbit”: “Dead silence fell in the middle of a word. Out went all lights. The fire leaped up in black smokes. Ashes and cinders were in the eyes of the dwarves, and the wood was filled again with their clamour and their cries. Bilbo found himself running round and round (as he thought) and calling and calling: ‘Dori, Nori, Ori, Oin, Gloin, Fili, Kili, Bombur, Bofur, Dwalin, Balin, Thorin Oakenshield’, while people he could not see or feel were doing the same all round him (with an occasional ‘Bilbo!’ thrown in). But the cries of the others got steadily further and fainter, and though after a while it seemed to him they changed to yells and cries for help in the distance, all noise at last died right away, and he was left alone in complete silence and darkness.” 2. One method to improve the security of substitution ciphers is to compress the plaintext (say, using gzip) before applying the encryption algorithm. Explain why this simple procedure improves security. You may think of two explanations, linguistic and mathematical. In our attack on a substitution cipher we used two methods: (1) frequencies analysis, and (2) short/frequent words and frequent combinations of letters. Compressing a text completely removes all the hints on short words and changes combinations of letters so that they are unrecognizable. This is the ‘linguistic’ reason why compressing a text improves the security of a substitution cipher. The mathematical reason is the following. The reason we compress a text is to make every symbol to carry more information, so that the same amount of information can be transmitted using fewer symbols. In a text every symbol carries the maximum amount of information if each symbol occurs with the same probability. Thus compressing a text makes its symbol to appear more uniformly destroying the basis of frequencies analysis. Compressing a text usually creates symbols that do not belong to the alphabet. Therefore to use a substitution cipher we have to extend it onto all possible 256 bytes. 3. Prove that the statistical distance between random variables X and Y satisfy the following properties: (a) Δ( X, Y ) = 1 2 X v | Pr[ X = v ] - Pr[ Y = v ] | ; (b) (triangle inequality) for any random variables Z , Δ( X, Y ) Δ( X, Z ) + Δ( Z, Y ) . (a) By definition Δ( X, Y ) = max T | Pr[ X T ] - Pr[ Y T ] | , where maximum is taken over all subsets of the set V of values of X and Y . Observing that Pr[ X T ] = v T Pr[ X = v ] and Pr[ Y T ] = v T Pr[ Y = v ] we obtain Pr[ X T ] - Pr[ Y T ] = X v T (Pr[ X = v ] - Pr[ Y = v ]) .
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}