Upload
lekiet
View
215
Download
1
Embed Size (px)
Citation preview
Transposition Ciphers
A transposition cipher is one in which plaintext symbols arerearranged (that is, permuted or transposed) to produce ci-phertext. The method of rearrangement, shared by Alice andBob, may be typographical or mathematical in nature.
1
Simple Columnar Transposition
The key information is the number k of columns.
Encipherment: Plaintext is written in lines k letters wide and thentranscribed column by column left to right to produce ciphertext.
2
Decipherment:
If n is the length ofthe ciphertext, it is writ-ten column by columnleft to right down in ak ! (n DIV k) rectangu-lar array with a “tail”of length n MOD k asshown. Transcribing rowby row produces plain-text.
k
n DIV k
n MOD k
M E S S A G E . . .A N D M O R E . . .A N D S T I L...
L A S T
3
Example: Suppose the key (number of columns) is 8. Encipherthe plaintextNOTHING IN THE WORLD IS MORE DANGEROUS THAN SINCERE IGNORANCE AND
CONSCIENTIOUS STUPIDITY"
"Martin Luther King, Jr.
4
Solution:
! !
N O T H I N G I
N T H E W O R L
D I S M O R E D
A N G E R O U S
T H A N S I N C
E R E I G N O R
A N C E A N D C
O N S C I E N T
I O U S S T U P
I D I T Y
Ciphertext: NNDAT EAOII OTINH RNNOD THSGA ECSUI HEMEN IECST IWORSGAISY NOROI NNETG REUNO DNUIL DSCRC TP
5
Example: If the number of columns is 7 and the ciphertext is
GPSDO AILTI VRVAA WETEC NITHM EDLHE TALEA ONNE
find the plaintext.
6
Solution: There are 39 letters in the ciphertext, so there are39 DIV 7 = 5 full rows and one partial row with 39 MOD 7 = 4letters.
G I V E M E A
P L A C E T O
S T A N D A N
D I W I L L M
O V E T H E E
A R T H
Plaintext: GIVE ME A PLACE TO STAND AND I WILL MOVE THE EARTH"
"Archimedes
7
Keyword Columnar Transposition
The order of transcription of the columns is determined by thealphabetical order of letters in the keyword. If repeated lettersare allowed in the keyword, then the column under the leftmostoccurence of the letter is transcribed first, followed successivelyby those to the right.
Decipherment is as for the simple columnar transposition exceptthat columns are written into the template in the order specifiedby the alphabetical order of the keyword’s letters.
8
Example: With keyword QUICK, encipher the plaintext DO NOT
SEEK THE TRUTH, ONLY CEASE TO CHERISH YOUR OPINIONS"
"Zen Proverb
9
Solution
Work: Q U I C K
4 5 2 1 3
-----------
D O N O T
S E E K T
H E T R U
T H O N L
Y C E A S
E T O C H
E R I S H
Y O U R O
P I N I O
N S
Ciphertext:OKRNA CSRIN ETOEO IUNTT
ULSHH OODSH TYEEY PNOEE
HCTRO IS
10
Example: Decipher
NSCRG LEXCT OEFNE HNRTL HOAHT OEICY NOIOT TEEGK SGWAO IHIAA
NRWEN OTKRT DDPE
if the keyword was k = COMPARE.
11
Solution: There are 64 letters in the ciphertext and 7 letters inthe keyword, so it fits in a template with 64 DIV 7 = 9 full rowsand a short row with 64 MOD 7 = 1 letter.
12
C O M P A R E
2 5 4 6 1 7 3
--------------
T E C H N O L
O G Y I S T H
E K N A C K O
F S O A R R A
N G I N G T H
E W O R L D T
H A T W E D O
N O T E X P E
R I E N C E I
T
13
C O M P A R E
2 5 4 6 1 7 3
--------------
T E C H N O L
O G Y I S T H
E K N A C K O
F S O A R R A
N G I N G T H
E W O R L D T
H A T W E D O
N O T E X P E
R I E N C E I
T
Plaintext: TECHNOLOGY IS
THE KNACK OF SO ARRANGING
THE WORLD THAT WE DO NOT
EXPERIENCE IT
"
"Max Frisch (1911–), Rollo May, The Cry for Myth, Norton, NY, p. 57.
14
Cryptanalysis
For a simple columnar transposition, cryptanalysis is relativelyeasy: try deciphering with various numbers of columns until in-telligible plaintext shows up.
15
Example: Cryptanalyze this!
SISEE RMIHI GHNST SEANA VAGOI MDNGN IRIMM OEDTG N
Solution
k = 2? S A
I G
S O
E I
E M... ...
gives SAIGSOEIEM. . ., which is not English.
16
k = 3? S T G
I S N
S E I
E A R
E N I... ... ...
gives STGISNSEIEARENI. . ., which is not English.
17
k = 4? S H A R
I N G I
S S O M
E T I M
E S M O
R E D E
M A N D
I N G T
H A N G
I V I N
G
gives SHARINGISSOMETIMESMOREDEMANDINGTHANGIVING"
"Mary Bateson
18
Cryptanalysis of a Keyword Columnar Transposition
Basic idea: determine the number of columns and then anagramthe columns to find an intelligibile message.
Example: Suppose that
SRUGE PEDIA SDWXC SATLS NRNMT EAEEE AOMSU ITENI KHBBI IDEER
ENEW
was produced by a keyword columnar transposition and thatEXPERIENCE was part of the plaintext. Find the plaintext.
19
Solution: k=2? The plaintext EXPERIENCE would encipher either
as
E X
P E
R I
E N
C E
or
* E
X P
E R
I E
N C
E *
In either case, the sequences EPREC and XEINE should appear.They do not, so this is not the keyword length.
20
k=3? The plaintext EXPERIENCE would encipher either as
E X P
E R I
E N C
E
or
* E X
P E R
I E N
C E *
or
* * E
X P E
R I E
N C E
In any case, the sequences EEEE, XRN, and PIC should appear.They do not, so this is not the keyword length.
21
Continuing this way and hoping that the keyword has fewer than10 letters, we find that assuming k = 7 implies
* * * * * * *
E X P E R I E
N C E * * * *
The sequences EN, XC, and PE should appear in the ciphertext.They do!
SRUGE PEDIA SDWXC SATLS NRNMT EAEEE AOMSU ITENI KHBBI IDEER
ENEW
22
The columns are either
M I S A T I E
S A R T E K E
U S U L A H R
I D G S E B E
T W E N E B N
E X P R E I E
N C E N A I W
S D M O D
if MSU ITEN
and EER ENEW
are short, or
M I S A T I D
S A R T E K E
U S U L A H E
I D G S E B R
T W E N E B E
E X P R E I N
N C E N A I E
S D M O W
if MSU ITEN
and IKHBBII
are short, or
24
M I S A T K E
S A R T E H E
U S U L A B R
I D G S E B E
T W E N E I N
E X P R E I E
N C E N A D W
I S D M O
if KHBBI ID and EER ENEW are short.
25