Computer Networks and Computer Security
Computer Networks and Computer Security
(x) = (x)
d
(y) =
1
(y)
where
1
is the inverse permutation to .
Here is an example of a permutation , which could comprise an encryption
function. (As before, plaintext characters are written in lower case and cipher-
text characters are written in upper case). Thus, e
(x
1
, . . . , x
m
) = (x
(1)
, . . . , x
(m)
)
d
(y
1
, . . . , y
m
) = (y
1
(1)
, . . . , y
1
(m)
)
where
1
is the inverse permutation to pi.
19-21-6
Here is an example to illustrate the permutation cipher. Suppose m = 6 and
the key is the following permutation : The inverse permutation
1
is given
x 1 2 3 4 5 6
(x) 3 5 1 6 4 2
by Now, suppose we are given the plaintext
x 1 2 3 4 5 6
1
(x) 3 6 1 5 2 4
shesellsseashellsbytheseashore
We rst partition the plaintext into groups of six letters (since the keysize m =
6).
shesel|lsseas|hellsb|ythere|ashore
Now each group of six letters is rearranged according to the permutation ,
yielding the following
EESLSH|SALSES|LSHBLE|HSY EET|HRAEOS|
So, the ciphertext is
EESLSHSALSESLSHBLEHSY EETHRAEOS
The ciphertext can be decrypted in a similar fashion, using the inverse permu-
tation
1
; I urge you all to try this out.
Recommended Reading
1. Chapter 1 of Stallings [1] for an introduction to network and computer
security. The model for network security is also discussed here.
2. Chapter 1 of Stinson [2] provides a nice introduction to cryptography. The
discussion on the shift, substitution, Vignere, and permutation ciphers in
this lecture is taken from this reference. There is also a good discussion of
these ciphers in Chapter 2 of Stallings. Section 1.2 of Stinson illustrates
how the substitution and Vignere ciphers can be broken using a statistical
analysis on the ciphertext; there is also some discussion in Section 2.2 of
Stallings.
References
[1] W. Stallings, Cryptography and Network Security: Principles and Prac-
tices, 3rd edition, Prentice Hall, NJ, 2003.
[2] D.R. Stinson, Cryptography: Theory and Practice, 2nd edition, Chapman
& Hall/CRC, 2002.
19-21-7