Professional Documents
Culture Documents
The first round key KI=OOOO 1011 0000001001100111 1001 1011 0100 1001 10100101.
Please calculate the following values.
Hint: Ex[] is the expansion permutation. Use the tables referenced in the DES at
(1) Ex(Ro) = 01110 100001 010101 010101 011110 100001 010101 010101
A = 011100 010001 011100 11 00 10 111 000 010101 110011 110000
(2) B = 0000 110000100001 0110 1101 0101 0000
(3) PCB) = 1001 00100001 110000100000 1001 1100
RI = 0101 11100001 1100 1110 110001100011
L 1 = 1111 0000 10 10 1010 1111 0000 1010 1010
00 04 08 OC 01 05 09 OD 7C 6B 01 D7
01 05 09 OD 00 04 08 DC 63 F2 30 FE
02 06 OA OE 03 07 OB OF 7B C5 2B 76
03 07 OB OF 02 06 OA OE 77 6F 67 AB
a b c
~
7C 6B 01 D7 75 87 OF A2 ;;. 03, ~/, 0 '.J
F2 30 FE 63 55 E6 04 22 01 . 0). ·0 3. oj
2B 76 7B C5 3E 2E B8 Be PI 01 0)" 03
AB 77 6F 67 10 15 58 OA
d e
, of 0 I 02
3. (1) Define a toy hash function h: (Z2)7 ~ (Z2)4 by the rule by hex) =xA where all operations
are modulo 2 and
1 0 0 0
1 1 0 0
1 1 1 0
A= 1 1 1 1
0 1 1 1
0 0 1 1
0 0 0 1
Find all preimages of (0, 1,0,1).
(2) Suppose thatf: {O,l}m ~ {O,l}m is a preimage resistant bijection. Define h : {0, 1 }2m ~
{O,l}'" as follows. Given x E{O,l }2m, write x=x '\Ix", where x " x" E{O, l}m. Then define
e;ba C~:
f
i& '(\
(2) For an integer i? 2, define a hash function h;: {O,1}2 m ~ {O,1}m recursively from hi-I, as
i
follows:
i i 1
a. Write x E{O,1}2 m as X=XtlIX2, where XI , X2E{O,1}2 - m.
=i)
St/wtQ h, ~ VJt{,'j/'1M nt&fJ~. hlctX,)// h,(1~:;' h,l'X/)II h, ('X;~
X'). -~U
Iv. IN
,u..,.,. ' ~ h (nC -.2 VX,,)1t A ~'-l. (tXt2» ::' AI( hi-2(1X,{jI/I"'-I (<</~) '.
I
.6- ')
~=-'J(~,I tx:' . hi'-I lx,) =- ni-t IK.) q tl Ai -~(rt,.,) 1/hn1'W =- Mk_ ~(~~) 1/A,e> (Pbl)
~l'hVL hJ~ toI/.'),.~ ~~~. 7/w,5.
hi-2 (~,I)=- A,-:l ('XI;) , At-viti,) =- h..-1-(lXI~). Jahi-iK'~-J~) ~ht-MlJr..:.)
517 ,p'~ Wt k .
5. (1) Use the extended Euclidean algoritlun to CDmpute the multiplicative inverses:
a. 17- 1 mod 101
b. 357- 1 mod 1234
(2) Compute gcd (57, 93), and find integers sand t such that 57s+93t= gcd (57, 93).
(c) Compute Euler's totient functions: cp(41), cp(27), and cp(440).
s== --I ~ . t ~ ?
(J). rC<P()-==l/JO
f{~7):! res);t2.={Y
~(~~)~Jt'~/~ ~/bO