1*0Sstevel@tonic-gateThe origional FIPE 180 used SHA-0 (FIPS 180) for its appendix 5 2*0Sstevel@tonic-gateexamples. This is an updated version that uses SHA-1 (FIPS 180-1) 3*0Sstevel@tonic-gatesupplied to me by Wei Dai 4*0Sstevel@tonic-gate-- 5*0Sstevel@tonic-gate APPENDIX 5. EXAMPLE OF THE DSA 6*0Sstevel@tonic-gate 7*0Sstevel@tonic-gate 8*0Sstevel@tonic-gateThis appendix is for informational purposes only and is not required to meet 9*0Sstevel@tonic-gatethe standard. 10*0Sstevel@tonic-gate 11*0Sstevel@tonic-gateLet L = 512 (size of p). The values in this example are expressed in 12*0Sstevel@tonic-gatehexadecimal notation. The p and q given here were generated by the prime 13*0Sstevel@tonic-gategeneration standard described in appendix 2 using the 160-bit SEED: 14*0Sstevel@tonic-gate 15*0Sstevel@tonic-gate d5014e4b 60ef2ba8 b6211b40 62ba3224 e0427dd3 16*0Sstevel@tonic-gate 17*0Sstevel@tonic-gateWith this SEED, the algorithm found p and q when the counter was at 105. 18*0Sstevel@tonic-gate 19*0Sstevel@tonic-gatex was generated by the algorithm described in appendix 3, section 3.1, using 20*0Sstevel@tonic-gatethe SHA to construct G (as in appendix 3, section 3.3) and a 160-bit XSEED: 21*0Sstevel@tonic-gate 22*0Sstevel@tonic-gateXSEED = 23*0Sstevel@tonic-gate 24*0Sstevel@tonic-gate bd029bbe 7f51960b cf9edb2b 61f06f0f eb5a38b6 25*0Sstevel@tonic-gate 26*0Sstevel@tonic-gatet = 27*0Sstevel@tonic-gate 67452301 EFCDAB89 98BADCFE 10325476 C3D2E1F0 28*0Sstevel@tonic-gate 29*0Sstevel@tonic-gatex = G(t,XSEED) mod q 30*0Sstevel@tonic-gate 31*0Sstevel@tonic-gatek was generated by the algorithm described in appendix 3, section 3.2, using 32*0Sstevel@tonic-gatethe SHA to construct G (as in appendix 3, section 3.3) and a 160-bit KSEED: 33*0Sstevel@tonic-gate 34*0Sstevel@tonic-gateKSEED = 35*0Sstevel@tonic-gate 36*0Sstevel@tonic-gate 687a66d9 0648f993 867e121f 4ddf9ddb 01205584 37*0Sstevel@tonic-gate 38*0Sstevel@tonic-gatet = 39*0Sstevel@tonic-gate EFCDAB89 98BADCFE 10325476 C3D2E1F0 67452301 40*0Sstevel@tonic-gate 41*0Sstevel@tonic-gatek = G(t,KSEED) mod q 42*0Sstevel@tonic-gate 43*0Sstevel@tonic-gateFinally: 44*0Sstevel@tonic-gate 45*0Sstevel@tonic-gateh = 2 46*0Sstevel@tonic-gate 47*0Sstevel@tonic-gatep = 48*0Sstevel@tonic-gate 8df2a494 492276aa 3d25759b b06869cb eac0d83a fb8d0cf7 49*0Sstevel@tonic-gate cbb8324f 0d7882e5 d0762fc5 b7210eaf c2e9adac 32ab7aac 50*0Sstevel@tonic-gate 49693dfb f83724c2 ec0736ee 31c80291 51*0Sstevel@tonic-gate 52*0Sstevel@tonic-gate 53*0Sstevel@tonic-gateq = 54*0Sstevel@tonic-gate c773218c 737ec8ee 993b4f2d ed30f48e dace915f 55*0Sstevel@tonic-gate 56*0Sstevel@tonic-gate 57*0Sstevel@tonic-gateg = 58*0Sstevel@tonic-gate 626d0278 39ea0a13 413163a5 5b4cb500 299d5522 956cefcb 59*0Sstevel@tonic-gate 3bff10f3 99ce2c2e 71cb9de5 fa24babf 58e5b795 21925c9c 60*0Sstevel@tonic-gate c42e9f6f 464b088c c572af53 e6d78802 61*0Sstevel@tonic-gate 62*0Sstevel@tonic-gate 63*0Sstevel@tonic-gatex = 64*0Sstevel@tonic-gate 2070b322 3dba372f de1c0ffc 7b2e3b49 8b260614 65*0Sstevel@tonic-gate 66*0Sstevel@tonic-gate 67*0Sstevel@tonic-gatek = 68*0Sstevel@tonic-gate 358dad57 1462710f 50e254cf 1a376b2b deaadfbf 69*0Sstevel@tonic-gate 70*0Sstevel@tonic-gate 71*0Sstevel@tonic-gatekinv = 72*0Sstevel@tonic-gate 73*0Sstevel@tonic-gate 0d516729 8202e49b 4116ac10 4fc3f415 ae52f917 74*0Sstevel@tonic-gate 75*0Sstevel@tonic-gateM = ASCII form of "abc" (See FIPS PUB 180-1, Appendix A) 76*0Sstevel@tonic-gate 77*0Sstevel@tonic-gateSHA(M) = 78*0Sstevel@tonic-gate 79*0Sstevel@tonic-gate a9993e36 4706816a ba3e2571 7850c26c 9cd0d89d 80*0Sstevel@tonic-gate 81*0Sstevel@tonic-gate 82*0Sstevel@tonic-gatey = 83*0Sstevel@tonic-gate 84*0Sstevel@tonic-gate 19131871 d75b1612 a819f29d 78d1b0d7 346f7aa7 7bb62a85 85*0Sstevel@tonic-gate 9bfd6c56 75da9d21 2d3a36ef 1672ef66 0b8c7c25 5cc0ec74 86*0Sstevel@tonic-gate 858fba33 f44c0669 9630a76b 030ee333 87*0Sstevel@tonic-gate 88*0Sstevel@tonic-gate 89*0Sstevel@tonic-gater = 90*0Sstevel@tonic-gate 8bac1ab6 6410435c b7181f95 b16ab97c 92b341c0 91*0Sstevel@tonic-gate 92*0Sstevel@tonic-gates = 93*0Sstevel@tonic-gate 41e2345f 1f56df24 58f426d1 55b4ba2d b6dcd8c8 94*0Sstevel@tonic-gate 95*0Sstevel@tonic-gate 96*0Sstevel@tonic-gatew = 97*0Sstevel@tonic-gate 9df4ece5 826be95f ed406d41 b43edc0b 1c18841b 98*0Sstevel@tonic-gate 99*0Sstevel@tonic-gate 100*0Sstevel@tonic-gateu1 = 101*0Sstevel@tonic-gate bf655bd0 46f0b35e c791b004 804afcbb 8ef7d69d 102*0Sstevel@tonic-gate 103*0Sstevel@tonic-gate 104*0Sstevel@tonic-gateu2 = 105*0Sstevel@tonic-gate 821a9263 12e97ade abcc8d08 2b527897 8a2df4b0 106*0Sstevel@tonic-gate 107*0Sstevel@tonic-gate 108*0Sstevel@tonic-gategu1 mod p = 109*0Sstevel@tonic-gate 110*0Sstevel@tonic-gate 51b1bf86 7888e5f3 af6fb476 9dd016bc fe667a65 aafc2753 111*0Sstevel@tonic-gate 9063bd3d 2b138b4c e02cc0c0 2ec62bb6 7306c63e 4db95bbf 112*0Sstevel@tonic-gate 6f96662a 1987a21b e4ec1071 010b6069 113*0Sstevel@tonic-gate 114*0Sstevel@tonic-gate 115*0Sstevel@tonic-gateyu2 mod p = 116*0Sstevel@tonic-gate 117*0Sstevel@tonic-gate 8b510071 2957e950 50d6b8fd 376a668e 4b0d633c 1e46e665 118*0Sstevel@tonic-gate 5c611a72 e2b28483 be52c74d 4b30de61 a668966e dc307a67 119*0Sstevel@tonic-gate c19441f4 22bf3c34 08aeba1f 0a4dbec7 120*0Sstevel@tonic-gate 121*0Sstevel@tonic-gatev = 122*0Sstevel@tonic-gate 8bac1ab6 6410435c b7181f95 b16ab97c 92b341c0 123