panaimin@icst.pku.edu.cn - PowerPoint PPT Presentation

About This Presentation
Title:

panaimin@icst.pku.edu.cn

Description:

Title: Author: Last modified by: panaimin Created Date: 10/2/1998 5:29:39 AM Document presentation format – PowerPoint PPT presentation

Number of Views:97
Avg rating:3.0/5.0
Slides: 79
Provided by: 6649737
Category:
Tags: cipher | edu | hill | icst | panaimin | pku

less

Transcript and Presenter's Notes

Title: panaimin@icst.pku.edu.cn


1
????????????(?)
  • ???,??????????
  • panaimin_at_icst.pku.edu.cn
  • http//www.icst.pku.edu.cn/InfoSecCourse

2
??
  • ??????
  • ??????
  • ??????
  • AES
  • ??????

3
???????????
  • ?? E (X,K) ? Y, y E(x,k)
  • ?? D (Y,K) ? X, x D(y,k)

4
????????
  • ?????????
  • ??????
  • ????????,????
  • ???
  • ????
  • ???
  • ????

5
????????????????
6
???
  • ??????
  • (1)?????????
  • ??(substitution)
  • ??(transposition)
  • (2)?????
  • ????????
  • ???????
  • (3)???????
  • ????(?????)
  • ?????

7
????
  • ??X?K??????????
  • ?????????????????????,???????????????????
  • ??????????,???5?
  • (1)????
  • (2)??????-???
  • (3)????
  • (4)????
  • (1)(2)(3)???(4)???

8
????????
  • Unconditionally secure,?????
  • ????,?????,??????,??????,????????,?????????????
  • ?????????????????
  • ??????????????????
  • Computationally secure,
  • ????????

9
?????????????
  • ????(password)k????
  • ??????????????,? Ek(x1) ! Ek(x2) if x1 ! x2
  • ???????????
  • ???????,????????????
  • ???
  • ???????
  • ??????
  • ??????????????

10
??????????
  • ??????????
  • ???(?????)
  • ???(???)
  • ????????
  • ????
  • ?????????????
  • ?????????,????
  • ?????????????????
  • ????????

11
?????????
  • ??????
  • ????
  • ????
  • ??????
  • DES
  • ??????
  • AES????
  • Rijndael

12
??????
  • ????
  • Caesar???
  • ???????
  • Playfair???
  • Hill???
  • ?????
  • ????
  • ?????????,??
  • ?????????,????????
  • ??????,????????????
  • ??????
  • ????

13
????????
  • ????????
  • DES??
  • ???????????
  • ???????
  • ???????????
  • ????????????????????????????

14
??????
  • DES(Data Encryption Standard)
  • IDEA
  • Blowfish
  • RC5
  • CAST-128

15
????????????
  • Diffusion(??)
  • ???????????
  • ????????,???????????,???????????????
  • Confusion(??)
  • ???????
  • ???????????????
  • ?????????

16
Feistel???????????
  • ??????,????
  • ?n???,???????
  • ?n???,??n64,????????????
  • Feistel???????????????

17
Feistel???????????
  • ?????????????????????????
  • ????????????????????????????
  • ???????????(permutation)
  • ??(confusion)???(diffusion)?????

18
Feistel???
19
Feistel????
  • ?? Li Ri-1 Ri Li-1?F(Ri-1,Ki)
  • ?? Ri-1 Li
  • Li-1 Ri?F(Ri-1,Ki)
  • Ri?F(Li,Ki)

20
Feistel????????
  • ????????????,?????,64????
  • ????????????,?????,64????,????????gt128
  • ??,??16?
  • ????????????,??????????
  • ?????????????,??????????
  • ??????,?????????
  • ???????????????????????

21
Feistel???????????
22
Feistel?????????????
23
DES??
  • 1977?????????(NBS,??NIST)??
  • 64????56???
  • ??
  • IBM?60?????LUCIFER??,???????128???
  • ????,???56???,IBM???NBS(NIST),????DES

24
DES??????
25
DES ???
  • Li Ri-1 Ri Li-1?F(Ri-1,Ki)

26
DES Function F
  • Expansion 32 ? 48
  • S-box 6 ? 4
  • Permutation

27
DES 32??48?????
32 01 02 03 04 05 04 05 06 07 08 09 08
09 10 11 12 13 12 13 14 15 16 17 16 17 18
19 20 21 20 21 22 23 24 25 24 25 26 27 28
29 28 29 30 31 32 01
28
DES S-box
  • S(1)
  • 14 04 13 01 02 15 11 08 03 10 06 12 05 09 00 07
  • 00 15 07 04 14 02 13 01 10 06 12 11 09 05 03 08
  • 04 01 14 08 13 06 02 11 15 12 09 07 03 10 05 00
  • 15 12 08 02 04 09 01 07 05 11 03 14 10 00 06 13

29
DES Permutation
16 07 20 21 29 12 28 17 01 15 23 26 05 18 31
10 02 08 24 14 32 27 03 09 19 13 30 06 22 11 04 25
30
DES?????????
  • PC-1
  • ??????
  • PC2
  • ??????
  • 1??2?

31
DES???
  • 56??????
  • ??????,97?100000??????6?????????DES
  • ???????,97?1?????,????Internet????????,????????700
    00?????96????
  • DES?????
  • ????8?S-BOX
  • ??DES?????
  • ?????
  • ?????

32
?????
  • ????????
  • ?????????????????????????????????
  • ???DES?16?????????,???S-BOX???????????
  • ??????????????,?????????
  • ?????DES??,??????????????

33
?????????
34
??DES?????
  • ?????
  • 247?????,??247????????
  • ?????
  • ?????????DES??
  • ??247????,????DES???

35
??DES
  • C EK2(EK1(P)) ? P DK1(DK2(C))

36
?????????????????
37
??DES
  • CEK3(DK2(EK1(P))) ? PDK1(EK2( DK3(C)))

38
???????
  • ?????(electronic codebook mode)ECB
  • ?????(cipher block chaining)CBC
  • ??????(cipher feedback)CFB
  • ??????(output feedback)OFB

39
?????ECB
  • ?????????
  • ????????????
  • ???????
  • ???????
  • ??????????????
  • ????????

40
?????CBC
  • ??????????IV
  • ?????????
  • ?????IV?????????
  • ????????????
  • ?????ECB

41
??????CFB
  • CFB????????
  • ?????????????IV
  • ???????,IV????
  • ???????????? (Wj-1)/j W????????,j??????

42
??????OFB
  • OFB????????
  • ?????????????IV
  • ?????????????

43
???????(?)??
  • ??
  • ????(block cipher)?????????(block)?????????
  • ????(stream cipher)?????,???????(?)?????????
  • ????
  • ????
  • ??One-time pad

44
???????
  • IDEA
  • Blowfish
  • RC5
  • CAST-128
  • RC2
  • RC4

45
IDEA??
  • 90?????,91???,92????
  • ????DES
  • 128???,64???
  • ????????????
  • ????
  • ????

46
IDEA????
  • ??confusion???
  • ????
  • ?216(65536)?????
  • ?2161 (65537)?????
  • ???????????
  • ??diffusion???
  • ??(MA)??
  • ??????
  • ???????????

47
IDEA????
48
IDEA???
49
BLOWFISH??
  • ???Bruce Schneier93
  • BLOWFISH????
  • ???Feistel??,16?
  • ??18????????
  • ??????5k??
  • ??????,???????????
  • ???????????????????????????32??3214448???
  • ?????????,???

50
BLOWFISH????
  • BLOWFISH????????????????,??S-BOX????
  • ???????
  • ??????S-BOX??????521?BLOWFISH????,????????????????
    ?
  • ????S-BOX????????
  • ?Feistel????????,?????????????,???????
  • ?????????
  • ???,?????????????

51
RC5????
  • ???Ron Rivest
  • ????
  • ????
  • ??w????,RC5???????,????16?32?64
  • ??r????,???0,1,,255
  • ??b????K????,???0,1,,255
  • RC5??RC5-w/r/b
  • ???????????RC5-32/12/16

52
RC5????
  • ??????
  • ????,?2w
  • ???? ?
  • ????? ltltlt
  • ??
  • LE0 A S0
  • RE0 B S1
  • for i 1 to r do
  • LEi ((LEi-1?REi-1) ltltlt REi-1 S2i
  • REi ((REi-1?LEi) ltltlt LEi S2i1

53
RC5????????
54
CAST-128????
  • RFC 214497??
  • ??48-128?,8???
  • 16?Feistel????
  • 64???
  • ???
  • ????????
  • ????F??

55
CAST-128?????
56
CAST-128?????
  • S-Box????,??????????????????,?????????S-BOX????S-B
    OX???
  • ?????????????????????????????????????????Blowfish?
    RC5?????????????????
  • F??????confusion?diffusion????????????????????

57
RC2????
  • ???Ron Rivest
  • ????64?,????8?1024?
  • ????16????????
  • RC2?S/MIME???????40?64?128???

58
RC4?????
  • ???Ron Rivest
  • ????OFB
  • ????
  • ?????
  • ???????,??88?S?

59
AES??
  • 1997?NIST????AES??
  • ?? ???DES?,?????????,??128?,??128/192/256?
  • 1998??????15????
  • 1999??????????? MARS, RC6, Rijndael, Serpent,
    Twofish
  • 2000??Rijndael??

60
Rijndael??
  • ???Feistel??
  • ???????????
  • ??128/192/256(/32Nb)?????
  • ??128/192/256(/32Nk)????
  • ????????????
  • ????????

61
Rijndael??(?)
  • ??/???????

k00 k01 k02 k03
k10 k11 k12 k13
k20 k21 k22 k23
k30 k31 k32 k33
a00 a01 a02 a03 a04 a05
a10 a11 a12 a13 a14 a15
a20 a21 a22 a23 a24 a25
a30 a31 a32 a33 a34 a35
Nr Nb4 Nb6 Nb8
Nk4 10 12 14
Nk6 12 12 14
Nk8 14 14 14
  • ??

62
Rijndael????
  • ??State????,??????????RoundKey???????????
  • ????
  • ???????AddRoundKey(State,RoundKey)
  • Round(State,RoundKey)
  • ByteSub(State)
  • ShiftRow(State)
  • MixColumn(State)
  • AddRoundKey(State,RoundKey)
  • FinalRound(State,RoundKey)
  • ByteSub(State)
  • ShiftRow(State)
  • AddRoundKey(State,RoundKey)

63
Rijndael AddRoundKey??
  • ????GF(28)???(XOR)

a00 a01 a02 a03 a04 a05
a10 a11 a12 a13 a14 a15
a20 a21 a22 a23 a24 a25
a30 a31 a32 a33 a34 a35
k00 k01 k02 k03 k04 k05
k10 k11 k12 k13 k14 k15
k20 k21 k22 k23 k24 k25
k30 k31 k32 k33 k34 k35
?
b00 b01 b02 b03 b04 b05
b10 b11 b12 b13 b14 b15
b20 b21 b22 b23 b24 b25
b30 b31 b32 b33 b34 b35

64
Rijndael ByteSub??
  • ByteSub(S-box)??????
  • ??????????
  • ??GF(28)?????,???GF(2)???????

a00 a01 a02 a03 a04 a05
a10 a11 a12 a13 a14 a15
a20 a21 a22 a23 a24 a25
a30 a31 a32 a33 a34 a35
b00 b01 b02 b03 b04 b05
b10 b11 b12 b13 b14 b15
b20 b21 b22 b23 b24 b25
b30 b31 b32 b33 b34 b35
S-box
aij
bij
65
Rijndael ShiftRow??
  • ???????,???????????

66
Rijndael MixColumn??
  • ???GF(28)?????????c(x)???c(x) 03x3 01x2
    01x 02 c-1(x) 0Bx3 0Dx2 09x 0E
  • ?M(x) x41

67
?????
a00 a01 a02 a03 a04 a05
a10 a11 a12 a13 a14 a15
a20 a21 a22 a23 a24 a25
a30 a31 a32 a33 a34 a35
  • Round(State,RoundKey)
  • ByteSub(State)
  • ShiftRow(State)
  • MixColumn(State)
  • AddRoundKey(State,RoundKey)

68
Rijndael Key schedule(1)
  • ??????????, (Nr1)Nb??
  • Nklt6
  • KeyExpansion(byte Key4Nk, word WNb(Nr1))
  • for(i0iltNki)
  • Wi(Key4i, Key4i1, Key4i2,
    Key4i3)
  • for(iNkiltNb(Nr1)i)
  • tempWi-1
  • if(iNk 0)
  • tempByteSub(templtltlt8)Rconi/Nk
  • WiWi-Nktemp
  • Rconi(xi-1, 00, 00, 00) xi-1?GF(28)???.

69
Rijndael Key schedule(2)
  • Nkgt6
  • KeyExpansion(byte Key4Nk, word WNb(Nr1))
  • for(i0iltNki)
  • Wi(Key4i, Key4i1, Key4i2,
    Key4i3)
  • for(iNkiltNb(Nr1)i)
  • tempWi-1
  • if(iNk 0)
  • tempByteSub(templtltlt8)Rconi/Nk
  • else if(iNk 4)
  • tempByteSub(templtltlt8)
  • WiWi-Nktemp

70
Rijndael ????
  • Rijndael(State,CipherKey)
  • KeyExpansion(CipherKey, ExpandedKey)
  • AddRoundKey(State, ExpandedKey)
  • For(i1iltNri)
  • ByteSub(State)
  • ShiftRow(State)
  • MixColumn(State)
  • AddRoundKey(State,ExpandedKeyNbi)
  • ByteSub(State)
  • ShiftRow(State)
  • AddRoundKey(State, ExpandedKeyNbi)

71
Rijndael ????
AddRoundKey() For(i1iltNri)
ByteSub() ShiftRow() MixColumn() AddRoundKey
() ByteSub() ShiftRow() AddRoundKey()
I_AddRoundKey() I_ShiftRow() I_ByteSub() For(i1
iltNri) I_AddRoundKey()I_MixColumn() I_Shif
tRow() I_ByteSub() I_AddRoundKey()
I_AddRoundKey() For(i1iltNri)
I_ShiftRow() I_ByteSub() I_AddRoundKey()
I_MixColumn() I_ShiftRow() I_ByteSub() I_Add
RoundKey()
72
Rijndael?????????
  • ???DES??????????
  • ????IDEA???????
  • ??????????????
  • ????
  • ????

73
?????
  • ?????,?????,??
  • ?????,??????
  • ????
  • RSA????
  • ????????
  • ???
  • ????,????????
  • ???,????,????????
  • ?????
  • ????(Randomization)?????????

74
???????
  • ?????(linear congruential method)

75
???????????(?)??????
76
???????????(?)?DES??????
77
???????????(?)?ANSI X9.17
78
BBS???????
  • ????????(next-bit test)
  • ?????????????????k?????????k1??????0.5
  • BBS??????????n???
Write a Comment
User Comments (0)
About PowerShow.com