1、 KSKSKSKS KSKSKSK KSKSKS KSKSK KSKS KSK KS KS X ISO/IEC 10116 n KS X ISO/IEC 10116 :2007 (2012 ) 2007 11 30 http:/www.kats.go.krKS X ISO/IEC 10116:2007 : e- ( ) ( ) () () ( ) : () ( ) () () JS ( ) KS X ISO/IEC 10116:2007 : (http:/www.standard.go.kr) : :1994 12 16 :2007 11 30 :2012 12 31 : e 2012-084
2、8 : e ( 02-509-7262) (http:/www.kats.go.kr). 10 5 , . KS X ISO/IEC 10116:2007 i ii iii 1 1 2 1 3 .1 4 ( ).3 4.1 a mod n.3 4.2 (array of bits) 3 4.3 2 3 4.4 (decryption)3 4.5 (encryption)4 4.6 4 4.7 4 4.8 I (t) 4 5 4 6 (ECB, Electronic Codebook) .5 6.1 5 6.2 .5 6.3 .5 7 (CBC, Cipher Block Chaining) .
3、5 7.1 5 7.2 .6 7.3 .6 8 (CFB, Cipher Feedback) .6 8.1 6 8.2 .7 8.3 .7 9 (OFB, Output Feedback) 8 9.1 8 9.2 .8 9.3 .9 10 (CTR, Counter) 9 10.1 9 10.2 .10 10.3 .10 A() .11 B() .13 C() .19 D() 22 34 .35 KS X ISO/IEC 10116:2007 ii e . KS X ISO/IEC 10116:2007 . A () B () C () D () KS X ISO/IEC 10116:2007
4、 iii 2006 3 ISO/IEC 10116, Information technologySecurity techniques Modes of operation for an n-bit cipher , . n- . n . 3 5 . a) (ECB, Electronic Codebook) b) (CBC, Cipher Block Chaining) c) (CFB, Cipher Feedback) d) (OFB, Output Feedback) e) (CTR, Counter) KS X ISO/IEC 10116:2007 (2012 ) n Informa
5、tion technologySecurity techniquesMode of operation for an n-bit block cipher algorithm 1 n- (, , ) 5 . . . . ( ) . ISO/IEC 9834 . A . A . B() . KS X ISO/IEC 180333 . 2 . ( ) . ( ) ( .) . KS X IEC 180333:2006, 3: ISO/IEC 9834, Information technologyOpen systems interconnectionProcedures for the oper
6、ation of OSI Registration Authorities(KS X ISO/IEC 9834 ) 3 . 3.1 (block chaining) KS X ISO/IEC 10116:2007 2 3.2 (block cipher) KS X ISO/IEC 180331 3.3 (ciphertext) 3.4 (counter) n (, n ) ; 2 1 (modulo 2 n ) . 3.5 (cryptographic synchronization) 3.6 (decryption) KS X ISO/IEC 180331 3.7 (encryption)
7、, ( ) KS X ISO/IEC 180331 3.8 ( FB, feedback buffer) . FB SV . 3.9 (key) (, , ) KS X ISO/IEC 180331 3.10 n- ( n-bit block cipher) n 3.11 (plaintext) 3.12 ( SV, starting variable) . KS X ISO/IEC 10116:2007 3 . . 4 ( ) C (Ciphertext block) CTR (Counter value) d K K E (Intermediate variable) eK K F (In
8、termediate variable) FB (Feedback buffer) i (Iteration) j / (Size of plaintext/ciphertext variable) K (Key) n / m (Number of stored ciphertext blocks) p (Plaintext block) q / (Number of plaintext/ciphertext variables) r (Size of feedback buffer) SV (Starting variable) X (Block cipher input block) Y
9、(Block cipher output block) | (Concatenation of bit strings) 4.1 a mod n a n , a mod n a n ( ) . ba mod n b . 0 b n, (ba) n 4.2 (array of bits) P C 1 . , A(a 1 , a 2 , . . . , a m ) B(b 1 , b 2 , . . . , b m ) m 1 m . 1 . . 4.3 2 2 “ or(exclusive or)” . A B . A B(a 1 b 1 , a 2 b 2 , . . . , a m b m
10、) 4.4 (decryption) KS X ISO/IEC 10116:2007 4 . Pd K (C) , P C K 4.5 (encryption) . Ce K (P) , P C K 4.6 j- A(a 1 , a 2 , . . . , a m ) j (j A)(a 1 , a 2 , . . . , a j ) . 1 j m . 4.7 “ (St, shift function)” : 1 t m m- X t- F S t (X | F ) m- . S t (X | F )(x t1 , x t2 , . . . , x m , f 1 , f 2 , . .
11、. , f t ) (t m) S t (X | F )(f 1 , f 2 , . . . , f t ) (tm) x 1 , x 2 , . . . , x t X t F t . tm X F . 4.8 I (t) I (t) 1 t- . 5 . . CBC B.2.3 . (CBC, Cipher Block Chaining) (7. ) m KS X ISO/IEC 10116:2007 5 . (CFB, Cipher Feedback) (8. ) 3 r, j k . (OFB, Output Feedback) (9. ) (CTR, Counter) (10. )
12、j . () . . K . (ECB, Electronic Codebook) SV SV . ( B ). . 6 (ECB, Electronic Codebook) 6.1 ECB . a) 1) n q P 1 , P 2 , . . . , P q2) K b) , , n q C 1 , C 2 , . . . , C q6.2 ECB . C i e K (P i ), i1, 2, . . . , q 6.3 ECB . P i d K (C i ), i1, 2, . . . , q 7 (CBC, Cipher Block Chaining) 7.1 CBC m 0 .
13、 m ( m1) 1024. m 1024 . . CBC . a) 1) n q P 1 , P 2 , . . . , P qKS X ISO/IEC 10116:2007 6 2) K 3) n m SV 1 , SV 2 , . . . , SV m m1 2 CBC (ISO/IEC 10116: 1997). b) , , n q C 1 , C 2 , . . . , C q7.2 CBC . C i e K (P i SV i ), 1 i min(m, q) q m, . C i e K (P i C im ), m1 i q m “ (FB, feedback buffer
14、)” ( C.2 ). C.2 . 7.3 CBC . P i d K (C i ) SV i , 1 i min(m, q) q m, . P i d K (C i ) C im , m1 i q m “ (FB, feedback buffer)” ( C.2 ). C.2 . 8 (CFB, Cipher Feedback) 8.1 CFB 3 . r, , n r 1024n r n . b) rn 1 CFB (ISO/IEC 10116:1991). KS X ISO/IEC 10116:2007 7 c) r , , r 1024n . CFB j k (B.3.2 ). CFB
15、 . a) 1) j q P 1 , P 2 , . . . , P q 2) K 3) r SV b) 1) n q X 1 , X 2 , . . . , X q2) n q Y 1 , Y 2 , . . . , Y q3) j q E 1 , E 2 , . . . , E q4) k q1 F 1 , F 2 , . . . , F q15) r q FB 1 , FB 2 , . . . , FB qc) , , j q C 1 , C 2 , . . . , C q 8.2 FB . FB 1 SV 6 . a) Xin FB i (FB n ) b) Yie K (X i )(
16、 ) c) Eij Y i(Y i j ) d) C i P i E i( ) e) F i I (kj) | C i( ) f) FB i1 S k (FB i| F i ) (FB ) i1, 2, ., q d) . C.3 . Y j 2 j . Y . 1 j . kj 1 k F . FB k F k FB . FB k . FB n X . 8.3 . KS X ISO/IEC 10116:2007 8 F B . FB 1 SV 6 . a) X i n FB i(FB n ) b) Y i e K (X i )( ) c) E i j Y i(Y i j ) d) P i C
17、 i E i( ) e) F i I(kj) | C i( ) f) FB i1 S k (FB i| F i ) (FB ) i1, 2, ., q d) . C.3 . Y j 2 j . Y . 1 j . kj 1 k F . FB k F k FB . FB k . FB n X . 9 (OFB, Output Feedback) 9.1 OFB , j(, 1 j n) . OFB . a) 1) j q P 1 , P 2 , . . . , P q2) K 3) n SV b) 1) n q X 1 , X 2 , . . . , X q2) n q Y 1 , Y 2 ,
18、. . . , Y q3) j q E 1 , E 2 , . . . , E qc) , , j q C 1 , C 2 , . . . , C q9.2 X . X 1 SV 4 . KS X ISO/IEC 10116:2007 9 a) Y i e K (X i ) ( ) b) E i j Y i (Y i j ) c) C i P i E i ( ) d) X i1 Y i ( ) i1, 2, ., q c) . C.4 . 1 j . Y i X, X i1 . Y i . 9.3 . X . X 1 SV 4 . a) Y i e K (X i ) ( ) b) Eij Y
19、i(Y i j ) c) P i C i E i( ) d) X i1 Y i( ) i1, 2, ., q c) . C.4 . 1 j . Y i X, X i1 . Y i . 10 (CTR, Counter) 10.1 CTR , j(, 1 j n) . . a) 1) j q P 1 , P 2 , . . . , P q2) K 3) n SV b) 1) n q CTR 1 , CTR 2 , . . . , CTR q2) n q Y 1 , Y 2 , . . . , Y q3) j q E 1 , E 2 , . . . , E qKS X ISO/IEC 10116:
20、2007 10 c) , , j q C 1 , C 2 , . . . , C q10.2 CTR . CTR 1 SV 4 . a) Y i e K (CTR i ) ( ) b) E i j Y i (Y i j ) c) C i P i E i( ) d) CTR i1 (CTR i1 ) mod 2 n ( CTR ) i1, 2, ., q c) . C.5 . 1 j . Y i Y i j . CTR 1(modulo 2 n ) . 10.3 . CTR . CTR 1 SV 4 . a) Y i e K (CTR i )( ) b) E i j Y i (Y i j ) c
21、) P i C i E i( ) d) CTR i1 (CTR i1 ) mod 2 n ( CTR ) i1, 2, ., q c) . C.5 . 1 j . Y i Y i j . CTR 1(modulo 2 n ) . Y i X, X i1 . Y i . KS X ISO/IEC 10116:2007 11 A () . ModesOfOperation iso(1) standard(0) modes-of-operation(10116) single-part(0) asn1-module(0) algorithm-object-identifiers(0) DEFINIT
22、IONS EXPLICIT TAGS := BEGIN - EXPORTS All; - IMPORTS BlockAlgorithms FROM EncryptionAlgorithms-3 iso(1) standard(0) encryption-algorithms(18033) part(3) asn1-module(0) algorithm-object-identifiers(0) ; OID := OBJECT IDENTIFIER - Alias - Synonyms - is10116 OID := iso(1) standard(0) modes-of-operation(10116) single-part(0) id-mode OID := is10116 mode(1) id-pad OID := is10116 pad(2) id-pad-null id-pad-1 RELATIVE-OID := 0 - no