Cryptography: Theory and Practice:Classical Cryptography

cryptography: theory and practice Cryptography: Theory and Practice
by Douglas Stinson
CRC Press, CRC Press LLC
ISBN: 0849385210   Pub Date: 03/17/95
  

Previous Table of Contents Next


DEFINITION 1.8  Suppose x = x1x2 . . . xn′ and y = y1y2 . . . yn′ are strings of n and n′ alphabetic characters, respectively. The mutual index of coincidence of x and y, denoted MIc(x, y), is defined to be the probability that a random element of x is identical to a random element of y. If we denote the frequencies of A, B, C, . . . , Z in x and y by f0, f1, f25 and f′0, . . . , f′1, . . . , f′25, respectively, then MIc(x, y) is seen to be

Now, given that we have determined the value of m, the substrings yi are obtained by shift encryption of the plaintext. Suppose K = (k1, k2, . . . , km) is the keyword. Let us see if we can estimate MIc(yi, yj). Consider a random character in yi and a random character in yj. The probability that both characters are A is , the probability that both are B is , etc. (Note that all subscripts are reduced modulo 26.) Hence, we estimate that

Observe that the value of this estimate depends only on the difference ki - kj mod 26, which we call the relative shift of yi and yj. Also, notice that

so a relative shift of yields the same estimate of MIc as does a relative shift of 26 - .

We tabulate these estimates, for relative shifts ranging between 0 to 13, in Table 1.4.

Table 1.4 Expected Mutual Indices of Coincidence
relative shift expected value of MIc
  0 0.065
  1 0.039
  2 0.032
  3 0.034
  4 0.044
  5 0.033
  6 0.036
  7 0.039
  8 0.034
  9 0.034
10 0.038
11 0.045
12 0.039
13 0.043

The important observation is that, if the relative shift is not zero, these estimates vary between 0.031 and 0.045; whereas, a relative shift of zero yields an estimate of 0.065. We can use this observation to formulate a likely guess for , the relative shift of yi and yj, as follows. Suppose we fix yi, and consider the effect of encrypting yj by e0, e1, e2, . . .. Denote the resulting strings by , etc. It is easy to compute the indices , 0 ≤ g ≤ 25. This can be done using the formula

When g = , the MIc should be close to 0.065, since the relative shift of yi and is zero. However, for values of g, the MIc should vary between 0.031 and 0.045.

By using this technique, we can obtain the relative shifts of any two of the substrings yi. This leaves only 26 possible keywords, which can easily be obtained by exhaustive key search, for example.

Let us illustrate by returning to Example 1.11.

Example 1.11 (Cont.)

We have hypothesized that the keyword length is 5. We now try to compute the relative shifts. By computer, it is not difficult to compute the 260 values , where 1 ≤ ij ≤ 5, 0 ≤ g 25. These values are tabulated in Table 1.5. For each (i, j) pair, we look for values that are close to 0.065. If there is a unique such value (for a given (i, j) pair), we conjecture that

Table 1.5 Observed Mutual Indices of Coincidence

it is the value of the relative shift.

Six such values in Table 1.5 are boxed. They provide strong evidence that the relative shift of y1 and y2 is 9; the relative shift of y1 and y5 is 16; the relative shift of y2 and y3 is 13; the relative shift of y2 and y5 is 7; the relative shift of y3 and y5 is 20; and the relative shift of y4 and y5 is 11. This gives us the following equations in the five unknowns k1, k2, k3, k4, k5:


Previous Table of Contents Next

Copyright © CRC Press LLC



Cryptography. Theory and Practice
Modern Cryptography: Theory and Practice
ISBN: 0130669431
EAN: 2147483647
Year: 1995
Pages: 133
Authors: Wenbo Mao

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net