1 | /* |
2 | * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved. |
3 | * |
4 | * Licensed under the Apache License 2.0 (the "License"). You may not use |
5 | * this file except in compliance with the License. You can obtain a copy |
6 | * in the file LICENSE in the source distribution or at |
7 | * https://www.openssl.org/source/license.html |
8 | */ |
9 | |
10 | #include "bn_local.h" |
11 | #include "internal/nelem.h" |
12 | |
13 | #ifndef OPENSSL_NO_SRP |
14 | |
15 | #include <openssl/srp.h> |
16 | #include "crypto/bn_srp.h" |
17 | |
18 | # if (BN_BYTES == 8) |
19 | # if (defined(_WIN32) || defined(_WIN64)) && !defined(__MINGW32__) |
20 | # define bn_pack4(a1,a2,a3,a4) ((a1##UI64<<48)|(a2##UI64<<32)|(a3##UI64<<16)|a4##UI64) |
21 | # elif defined(__arch64__) |
22 | # define bn_pack4(a1,a2,a3,a4) ((a1##UL<<48)|(a2##UL<<32)|(a3##UL<<16)|a4##UL) |
23 | # else |
24 | # define bn_pack4(a1,a2,a3,a4) ((a1##ULL<<48)|(a2##ULL<<32)|(a3##ULL<<16)|a4##ULL) |
25 | # endif |
26 | # elif (BN_BYTES == 4) |
27 | # define bn_pack4(a1,a2,a3,a4) ((a3##UL<<16)|a4##UL), ((a1##UL<<16)|a2##UL) |
28 | # else |
29 | # error "unsupported BN_BYTES" |
30 | # endif |
31 | |
32 | static const BN_ULONG bn_group_1024_value[] = { |
33 | bn_pack4(0x9FC6, 0x1D2F, 0xC0EB, 0x06E3), |
34 | bn_pack4(0xFD51, 0x38FE, 0x8376, 0x435B), |
35 | bn_pack4(0x2FD4, 0xCBF4, 0x976E, 0xAA9A), |
36 | bn_pack4(0x68ED, 0xBC3C, 0x0572, 0x6CC0), |
37 | bn_pack4(0xC529, 0xF566, 0x660E, 0x57EC), |
38 | bn_pack4(0x8255, 0x9B29, 0x7BCF, 0x1885), |
39 | bn_pack4(0xCE8E, 0xF4AD, 0x69B1, 0x5D49), |
40 | bn_pack4(0x5DC7, 0xD7B4, 0x6154, 0xD6B6), |
41 | bn_pack4(0x8E49, 0x5C1D, 0x6089, 0xDAD1), |
42 | bn_pack4(0xE0D5, 0xD8E2, 0x50B9, 0x8BE4), |
43 | bn_pack4(0x383B, 0x4813, 0xD692, 0xC6E0), |
44 | bn_pack4(0xD674, 0xDF74, 0x96EA, 0x81D3), |
45 | bn_pack4(0x9EA2, 0x314C, 0x9C25, 0x6576), |
46 | bn_pack4(0x6072, 0x6187, 0x75FF, 0x3C0B), |
47 | bn_pack4(0x9C33, 0xF80A, 0xFA8F, 0xC5E8), |
48 | bn_pack4(0xEEAF, 0x0AB9, 0xADB3, 0x8DD6) |
49 | }; |
50 | |
51 | const BIGNUM bn_group_1024 = { |
52 | (BN_ULONG *)bn_group_1024_value, |
53 | OSSL_NELEM(bn_group_1024_value), |
54 | OSSL_NELEM(bn_group_1024_value), |
55 | 0, |
56 | BN_FLG_STATIC_DATA |
57 | }; |
58 | |
59 | static const BN_ULONG bn_group_1536_value[] = { |
60 | bn_pack4(0xCF76, 0xE3FE, 0xD135, 0xF9BB), |
61 | bn_pack4(0x1518, 0x0F93, 0x499A, 0x234D), |
62 | bn_pack4(0x8CE7, 0xA28C, 0x2442, 0xC6F3), |
63 | bn_pack4(0x5A02, 0x1FFF, 0x5E91, 0x479E), |
64 | bn_pack4(0x7F8A, 0x2FE9, 0xB8B5, 0x292E), |
65 | bn_pack4(0x837C, 0x264A, 0xE3A9, 0xBEB8), |
66 | bn_pack4(0xE442, 0x734A, 0xF7CC, 0xB7AE), |
67 | bn_pack4(0x6577, 0x2E43, 0x7D6C, 0x7F8C), |
68 | bn_pack4(0xDB2F, 0xD53D, 0x24B7, 0xC486), |
69 | bn_pack4(0x6EDF, 0x0195, 0x3934, 0x9627), |
70 | bn_pack4(0x158B, 0xFD3E, 0x2B9C, 0x8CF5), |
71 | bn_pack4(0x764E, 0x3F4B, 0x53DD, 0x9DA1), |
72 | bn_pack4(0x4754, 0x8381, 0xDBC5, 0xB1FC), |
73 | bn_pack4(0x9B60, 0x9E0B, 0xE3BA, 0xB63D), |
74 | bn_pack4(0x8134, 0xB1C8, 0xB979, 0x8914), |
75 | bn_pack4(0xDF02, 0x8A7C, 0xEC67, 0xF0D0), |
76 | bn_pack4(0x80B6, 0x55BB, 0x9A22, 0xE8DC), |
77 | bn_pack4(0x1558, 0x903B, 0xA0D0, 0xF843), |
78 | bn_pack4(0x51C6, 0xA94B, 0xE460, 0x7A29), |
79 | bn_pack4(0x5F4F, 0x5F55, 0x6E27, 0xCBDE), |
80 | bn_pack4(0xBEEE, 0xA961, 0x4B19, 0xCC4D), |
81 | bn_pack4(0xDBA5, 0x1DF4, 0x99AC, 0x4C80), |
82 | bn_pack4(0xB1F1, 0x2A86, 0x17A4, 0x7BBB), |
83 | bn_pack4(0x9DEF, 0x3CAF, 0xB939, 0x277A) |
84 | }; |
85 | |
86 | const BIGNUM bn_group_1536 = { |
87 | (BN_ULONG *)bn_group_1536_value, |
88 | OSSL_NELEM(bn_group_1536_value), |
89 | OSSL_NELEM(bn_group_1536_value), |
90 | 0, |
91 | BN_FLG_STATIC_DATA |
92 | }; |
93 | |
94 | static const BN_ULONG bn_group_2048_value[] = { |
95 | bn_pack4(0x0FA7, 0x111F, 0x9E4A, 0xFF73), |
96 | bn_pack4(0x9B65, 0xE372, 0xFCD6, 0x8EF2), |
97 | bn_pack4(0x35DE, 0x236D, 0x525F, 0x5475), |
98 | bn_pack4(0x94B5, 0xC803, 0xD89F, 0x7AE4), |
99 | bn_pack4(0x71AE, 0x35F8, 0xE9DB, 0xFBB6), |
100 | bn_pack4(0x2A56, 0x98F3, 0xA8D0, 0xC382), |
101 | bn_pack4(0x9CCC, 0x041C, 0x7BC3, 0x08D8), |
102 | bn_pack4(0xAF87, 0x4E73, 0x03CE, 0x5329), |
103 | bn_pack4(0x6160, 0x2790, 0x04E5, 0x7AE6), |
104 | bn_pack4(0x032C, 0xFBDB, 0xF52F, 0xB378), |
105 | bn_pack4(0x5EA7, 0x7A27, 0x75D2, 0xECFA), |
106 | bn_pack4(0x5445, 0x23B5, 0x24B0, 0xD57D), |
107 | bn_pack4(0x5B9D, 0x32E6, 0x88F8, 0x7748), |
108 | bn_pack4(0xF1D2, 0xB907, 0x8717, 0x461A), |
109 | bn_pack4(0x76BD, 0x207A, 0x436C, 0x6481), |
110 | bn_pack4(0xCA97, 0xB43A, 0x23FB, 0x8016), |
111 | bn_pack4(0x1D28, 0x1E44, 0x6B14, 0x773B), |
112 | bn_pack4(0x7359, 0xD041, 0xD5C3, 0x3EA7), |
113 | bn_pack4(0xA80D, 0x740A, 0xDBF4, 0xFF74), |
114 | bn_pack4(0x55F9, 0x7993, 0xEC97, 0x5EEA), |
115 | bn_pack4(0x2918, 0xA996, 0x2F0B, 0x93B8), |
116 | bn_pack4(0x661A, 0x05FB, 0xD5FA, 0xAAE8), |
117 | bn_pack4(0xCF60, 0x9517, 0x9A16, 0x3AB3), |
118 | bn_pack4(0xE808, 0x3969, 0xEDB7, 0x67B0), |
119 | bn_pack4(0xCD7F, 0x48A9, 0xDA04, 0xFD50), |
120 | bn_pack4(0xD523, 0x12AB, 0x4B03, 0x310D), |
121 | bn_pack4(0x8193, 0xE075, 0x7767, 0xA13D), |
122 | bn_pack4(0xA373, 0x29CB, 0xB4A0, 0x99ED), |
123 | bn_pack4(0xFC31, 0x9294, 0x3DB5, 0x6050), |
124 | bn_pack4(0xAF72, 0xB665, 0x1987, 0xEE07), |
125 | bn_pack4(0xF166, 0xDE5E, 0x1389, 0x582F), |
126 | bn_pack4(0xAC6B, 0xDB41, 0x324A, 0x9A9B) |
127 | }; |
128 | |
129 | const BIGNUM bn_group_2048 = { |
130 | (BN_ULONG *)bn_group_2048_value, |
131 | OSSL_NELEM(bn_group_2048_value), |
132 | OSSL_NELEM(bn_group_2048_value), |
133 | 0, |
134 | BN_FLG_STATIC_DATA |
135 | }; |
136 | |
137 | static const BN_ULONG bn_group_3072_value[] = { |
138 | bn_pack4(0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF), |
139 | bn_pack4(0x4B82, 0xD120, 0xA93A, 0xD2CA), |
140 | bn_pack4(0x43DB, 0x5BFC, 0xE0FD, 0x108E), |
141 | bn_pack4(0x08E2, 0x4FA0, 0x74E5, 0xAB31), |
142 | bn_pack4(0x7709, 0x88C0, 0xBAD9, 0x46E2), |
143 | bn_pack4(0xBBE1, 0x1757, 0x7A61, 0x5D6C), |
144 | bn_pack4(0x521F, 0x2B18, 0x177B, 0x200C), |
145 | bn_pack4(0xD876, 0x0273, 0x3EC8, 0x6A64), |
146 | bn_pack4(0xF12F, 0xFA06, 0xD98A, 0x0864), |
147 | bn_pack4(0xCEE3, 0xD226, 0x1AD2, 0xEE6B), |
148 | bn_pack4(0x1E8C, 0x94E0, 0x4A25, 0x619D), |
149 | bn_pack4(0xABF5, 0xAE8C, 0xDB09, 0x33D7), |
150 | bn_pack4(0xB397, 0x0F85, 0xA6E1, 0xE4C7), |
151 | bn_pack4(0x8AEA, 0x7157, 0x5D06, 0x0C7D), |
152 | bn_pack4(0xECFB, 0x8504, 0x58DB, 0xEF0A), |
153 | bn_pack4(0xA855, 0x21AB, 0xDF1C, 0xBA64), |
154 | bn_pack4(0xAD33, 0x170D, 0x0450, 0x7A33), |
155 | bn_pack4(0x1572, 0x8E5A, 0x8AAA, 0xC42D), |
156 | bn_pack4(0x15D2, 0x2618, 0x98FA, 0x0510), |
157 | bn_pack4(0x3995, 0x497C, 0xEA95, 0x6AE5), |
158 | bn_pack4(0xDE2B, 0xCBF6, 0x9558, 0x1718), |
159 | bn_pack4(0xB5C5, 0x5DF0, 0x6F4C, 0x52C9), |
160 | bn_pack4(0x9B27, 0x83A2, 0xEC07, 0xA28F), |
161 | bn_pack4(0xE39E, 0x772C, 0x180E, 0x8603), |
162 | bn_pack4(0x3290, 0x5E46, 0x2E36, 0xCE3B), |
163 | bn_pack4(0xF174, 0x6C08, 0xCA18, 0x217C), |
164 | bn_pack4(0x670C, 0x354E, 0x4ABC, 0x9804), |
165 | bn_pack4(0x9ED5, 0x2907, 0x7096, 0x966D), |
166 | bn_pack4(0x1C62, 0xF356, 0x2085, 0x52BB), |
167 | bn_pack4(0x8365, 0x5D23, 0xDCA3, 0xAD96), |
168 | bn_pack4(0x6916, 0x3FA8, 0xFD24, 0xCF5F), |
169 | bn_pack4(0x98DA, 0x4836, 0x1C55, 0xD39A), |
170 | bn_pack4(0xC200, 0x7CB8, 0xA163, 0xBF05), |
171 | bn_pack4(0x4928, 0x6651, 0xECE4, 0x5B3D), |
172 | bn_pack4(0xAE9F, 0x2411, 0x7C4B, 0x1FE6), |
173 | bn_pack4(0xEE38, 0x6BFB, 0x5A89, 0x9FA5), |
174 | bn_pack4(0x0BFF, 0x5CB6, 0xF406, 0xB7ED), |
175 | bn_pack4(0xF44C, 0x42E9, 0xA637, 0xED6B), |
176 | bn_pack4(0xE485, 0xB576, 0x625E, 0x7EC6), |
177 | bn_pack4(0x4FE1, 0x356D, 0x6D51, 0xC245), |
178 | bn_pack4(0x302B, 0x0A6D, 0xF25F, 0x1437), |
179 | bn_pack4(0xEF95, 0x19B3, 0xCD3A, 0x431B), |
180 | bn_pack4(0x514A, 0x0879, 0x8E34, 0x04DD), |
181 | bn_pack4(0x020B, 0xBEA6, 0x3B13, 0x9B22), |
182 | bn_pack4(0x2902, 0x4E08, 0x8A67, 0xCC74), |
183 | bn_pack4(0xC4C6, 0x628B, 0x80DC, 0x1CD1), |
184 | bn_pack4(0xC90F, 0xDAA2, 0x2168, 0xC234), |
185 | bn_pack4(0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF) |
186 | }; |
187 | |
188 | const BIGNUM bn_group_3072 = { |
189 | (BN_ULONG *)bn_group_3072_value, |
190 | OSSL_NELEM(bn_group_3072_value), |
191 | OSSL_NELEM(bn_group_3072_value), |
192 | 0, |
193 | BN_FLG_STATIC_DATA |
194 | }; |
195 | |
196 | static const BN_ULONG bn_group_4096_value[] = { |
197 | bn_pack4(0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF), |
198 | bn_pack4(0x4DF4, 0x35C9, 0x3406, 0x3199), |
199 | bn_pack4(0x86FF, 0xB7DC, 0x90A6, 0xC08F), |
200 | bn_pack4(0x93B4, 0xEA98, 0x8D8F, 0xDDC1), |
201 | bn_pack4(0xD006, 0x9127, 0xD5B0, 0x5AA9), |
202 | bn_pack4(0xB81B, 0xDD76, 0x2170, 0x481C), |
203 | bn_pack4(0x1F61, 0x2970, 0xCEE2, 0xD7AF), |
204 | bn_pack4(0x233B, 0xA186, 0x515B, 0xE7ED), |
205 | bn_pack4(0x99B2, 0x964F, 0xA090, 0xC3A2), |
206 | bn_pack4(0x287C, 0x5947, 0x4E6B, 0xC05D), |
207 | bn_pack4(0x2E8E, 0xFC14, 0x1FBE, 0xCAA6), |
208 | bn_pack4(0xDBBB, 0xC2DB, 0x04DE, 0x8EF9), |
209 | bn_pack4(0x2583, 0xE9CA, 0x2AD4, 0x4CE8), |
210 | bn_pack4(0x1A94, 0x6834, 0xB615, 0x0BDA), |
211 | bn_pack4(0x99C3, 0x2718, 0x6AF4, 0xE23C), |
212 | bn_pack4(0x8871, 0x9A10, 0xBDBA, 0x5B26), |
213 | bn_pack4(0x1A72, 0x3C12, 0xA787, 0xE6D7), |
214 | bn_pack4(0x4B82, 0xD120, 0xA921, 0x0801), |
215 | bn_pack4(0x43DB, 0x5BFC, 0xE0FD, 0x108E), |
216 | bn_pack4(0x08E2, 0x4FA0, 0x74E5, 0xAB31), |
217 | bn_pack4(0x7709, 0x88C0, 0xBAD9, 0x46E2), |
218 | bn_pack4(0xBBE1, 0x1757, 0x7A61, 0x5D6C), |
219 | bn_pack4(0x521F, 0x2B18, 0x177B, 0x200C), |
220 | bn_pack4(0xD876, 0x0273, 0x3EC8, 0x6A64), |
221 | bn_pack4(0xF12F, 0xFA06, 0xD98A, 0x0864), |
222 | bn_pack4(0xCEE3, 0xD226, 0x1AD2, 0xEE6B), |
223 | bn_pack4(0x1E8C, 0x94E0, 0x4A25, 0x619D), |
224 | bn_pack4(0xABF5, 0xAE8C, 0xDB09, 0x33D7), |
225 | bn_pack4(0xB397, 0x0F85, 0xA6E1, 0xE4C7), |
226 | bn_pack4(0x8AEA, 0x7157, 0x5D06, 0x0C7D), |
227 | bn_pack4(0xECFB, 0x8504, 0x58DB, 0xEF0A), |
228 | bn_pack4(0xA855, 0x21AB, 0xDF1C, 0xBA64), |
229 | bn_pack4(0xAD33, 0x170D, 0x0450, 0x7A33), |
230 | bn_pack4(0x1572, 0x8E5A, 0x8AAA, 0xC42D), |
231 | bn_pack4(0x15D2, 0x2618, 0x98FA, 0x0510), |
232 | bn_pack4(0x3995, 0x497C, 0xEA95, 0x6AE5), |
233 | bn_pack4(0xDE2B, 0xCBF6, 0x9558, 0x1718), |
234 | bn_pack4(0xB5C5, 0x5DF0, 0x6F4C, 0x52C9), |
235 | bn_pack4(0x9B27, 0x83A2, 0xEC07, 0xA28F), |
236 | bn_pack4(0xE39E, 0x772C, 0x180E, 0x8603), |
237 | bn_pack4(0x3290, 0x5E46, 0x2E36, 0xCE3B), |
238 | bn_pack4(0xF174, 0x6C08, 0xCA18, 0x217C), |
239 | bn_pack4(0x670C, 0x354E, 0x4ABC, 0x9804), |
240 | bn_pack4(0x9ED5, 0x2907, 0x7096, 0x966D), |
241 | bn_pack4(0x1C62, 0xF356, 0x2085, 0x52BB), |
242 | bn_pack4(0x8365, 0x5D23, 0xDCA3, 0xAD96), |
243 | bn_pack4(0x6916, 0x3FA8, 0xFD24, 0xCF5F), |
244 | bn_pack4(0x98DA, 0x4836, 0x1C55, 0xD39A), |
245 | bn_pack4(0xC200, 0x7CB8, 0xA163, 0xBF05), |
246 | bn_pack4(0x4928, 0x6651, 0xECE4, 0x5B3D), |
247 | bn_pack4(0xAE9F, 0x2411, 0x7C4B, 0x1FE6), |
248 | bn_pack4(0xEE38, 0x6BFB, 0x5A89, 0x9FA5), |
249 | bn_pack4(0x0BFF, 0x5CB6, 0xF406, 0xB7ED), |
250 | bn_pack4(0xF44C, 0x42E9, 0xA637, 0xED6B), |
251 | bn_pack4(0xE485, 0xB576, 0x625E, 0x7EC6), |
252 | bn_pack4(0x4FE1, 0x356D, 0x6D51, 0xC245), |
253 | bn_pack4(0x302B, 0x0A6D, 0xF25F, 0x1437), |
254 | bn_pack4(0xEF95, 0x19B3, 0xCD3A, 0x431B), |
255 | bn_pack4(0x514A, 0x0879, 0x8E34, 0x04DD), |
256 | bn_pack4(0x020B, 0xBEA6, 0x3B13, 0x9B22), |
257 | bn_pack4(0x2902, 0x4E08, 0x8A67, 0xCC74), |
258 | bn_pack4(0xC4C6, 0x628B, 0x80DC, 0x1CD1), |
259 | bn_pack4(0xC90F, 0xDAA2, 0x2168, 0xC234), |
260 | bn_pack4(0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF) |
261 | }; |
262 | |
263 | const BIGNUM bn_group_4096 = { |
264 | (BN_ULONG *)bn_group_4096_value, |
265 | OSSL_NELEM(bn_group_4096_value), |
266 | OSSL_NELEM(bn_group_4096_value), |
267 | 0, |
268 | BN_FLG_STATIC_DATA |
269 | }; |
270 | |
271 | static const BN_ULONG bn_group_6144_value[] = { |
272 | bn_pack4(0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF), |
273 | bn_pack4(0xE694, 0xF91E, 0x6DCC, 0x4024), |
274 | bn_pack4(0x12BF, 0x2D5B, 0x0B74, 0x74D6), |
275 | bn_pack4(0x043E, 0x8F66, 0x3F48, 0x60EE), |
276 | bn_pack4(0x387F, 0xE8D7, 0x6E3C, 0x0468), |
277 | bn_pack4(0xDA56, 0xC9EC, 0x2EF2, 0x9632), |
278 | bn_pack4(0xEB19, 0xCCB1, 0xA313, 0xD55C), |
279 | bn_pack4(0xF550, 0xAA3D, 0x8A1F, 0xBFF0), |
280 | bn_pack4(0x06A1, 0xD58B, 0xB7C5, 0xDA76), |
281 | bn_pack4(0xA797, 0x15EE, 0xF29B, 0xE328), |
282 | bn_pack4(0x14CC, 0x5ED2, 0x0F80, 0x37E0), |
283 | bn_pack4(0xCC8F, 0x6D7E, 0xBF48, 0xE1D8), |
284 | bn_pack4(0x4BD4, 0x07B2, 0x2B41, 0x54AA), |
285 | bn_pack4(0x0F1D, 0x45B7, 0xFF58, 0x5AC5), |
286 | bn_pack4(0x23A9, 0x7A7E, 0x36CC, 0x88BE), |
287 | bn_pack4(0x59E7, 0xC97F, 0xBEC7, 0xE8F3), |
288 | bn_pack4(0xB5A8, 0x4031, 0x900B, 0x1C9E), |
289 | bn_pack4(0xD55E, 0x702F, 0x4698, 0x0C82), |
290 | bn_pack4(0xF482, 0xD7CE, 0x6E74, 0xFEF6), |
291 | bn_pack4(0xF032, 0xEA15, 0xD172, 0x1D03), |
292 | bn_pack4(0x5983, 0xCA01, 0xC64B, 0x92EC), |
293 | bn_pack4(0x6FB8, 0xF401, 0x378C, 0xD2BF), |
294 | bn_pack4(0x3320, 0x5151, 0x2BD7, 0xAF42), |
295 | bn_pack4(0xDB7F, 0x1447, 0xE6CC, 0x254B), |
296 | bn_pack4(0x44CE, 0x6CBA, 0xCED4, 0xBB1B), |
297 | bn_pack4(0xDA3E, 0xDBEB, 0xCF9B, 0x14ED), |
298 | bn_pack4(0x1797, 0x27B0, 0x865A, 0x8918), |
299 | bn_pack4(0xB06A, 0x53ED, 0x9027, 0xD831), |
300 | bn_pack4(0xE5DB, 0x382F, 0x4130, 0x01AE), |
301 | bn_pack4(0xF8FF, 0x9406, 0xAD9E, 0x530E), |
302 | bn_pack4(0xC975, 0x1E76, 0x3DBA, 0x37BD), |
303 | bn_pack4(0xC1D4, 0xDCB2, 0x6026, 0x46DE), |
304 | bn_pack4(0x36C3, 0xFAB4, 0xD27C, 0x7026), |
305 | bn_pack4(0x4DF4, 0x35C9, 0x3402, 0x8492), |
306 | bn_pack4(0x86FF, 0xB7DC, 0x90A6, 0xC08F), |
307 | bn_pack4(0x93B4, 0xEA98, 0x8D8F, 0xDDC1), |
308 | bn_pack4(0xD006, 0x9127, 0xD5B0, 0x5AA9), |
309 | bn_pack4(0xB81B, 0xDD76, 0x2170, 0x481C), |
310 | bn_pack4(0x1F61, 0x2970, 0xCEE2, 0xD7AF), |
311 | bn_pack4(0x233B, 0xA186, 0x515B, 0xE7ED), |
312 | bn_pack4(0x99B2, 0x964F, 0xA090, 0xC3A2), |
313 | bn_pack4(0x287C, 0x5947, 0x4E6B, 0xC05D), |
314 | bn_pack4(0x2E8E, 0xFC14, 0x1FBE, 0xCAA6), |
315 | bn_pack4(0xDBBB, 0xC2DB, 0x04DE, 0x8EF9), |
316 | bn_pack4(0x2583, 0xE9CA, 0x2AD4, 0x4CE8), |
317 | bn_pack4(0x1A94, 0x6834, 0xB615, 0x0BDA), |
318 | bn_pack4(0x99C3, 0x2718, 0x6AF4, 0xE23C), |
319 | bn_pack4(0x8871, 0x9A10, 0xBDBA, 0x5B26), |
320 | bn_pack4(0x1A72, 0x3C12, 0xA787, 0xE6D7), |
321 | bn_pack4(0x4B82, 0xD120, 0xA921, 0x0801), |
322 | bn_pack4(0x43DB, 0x5BFC, 0xE0FD, 0x108E), |
323 | bn_pack4(0x08E2, 0x4FA0, 0x74E5, 0xAB31), |
324 | bn_pack4(0x7709, 0x88C0, 0xBAD9, 0x46E2), |
325 | bn_pack4(0xBBE1, 0x1757, 0x7A61, 0x5D6C), |
326 | bn_pack4(0x521F, 0x2B18, 0x177B, 0x200C), |
327 | bn_pack4(0xD876, 0x0273, 0x3EC8, 0x6A64), |
328 | bn_pack4(0xF12F, 0xFA06, 0xD98A, 0x0864), |
329 | bn_pack4(0xCEE3, 0xD226, 0x1AD2, 0xEE6B), |
330 | bn_pack4(0x1E8C, 0x94E0, 0x4A25, 0x619D), |
331 | bn_pack4(0xABF5, 0xAE8C, 0xDB09, 0x33D7), |
332 | bn_pack4(0xB397, 0x0F85, 0xA6E1, 0xE4C7), |
333 | bn_pack4(0x8AEA, 0x7157, 0x5D06, 0x0C7D), |
334 | bn_pack4(0xECFB, 0x8504, 0x58DB, 0xEF0A), |
335 | bn_pack4(0xA855, 0x21AB, 0xDF1C, 0xBA64), |
336 | bn_pack4(0xAD33, 0x170D, 0x0450, 0x7A33), |
337 | bn_pack4(0x1572, 0x8E5A, 0x8AAA, 0xC42D), |
338 | bn_pack4(0x15D2, 0x2618, 0x98FA, 0x0510), |
339 | bn_pack4(0x3995, 0x497C, 0xEA95, 0x6AE5), |
340 | bn_pack4(0xDE2B, 0xCBF6, 0x9558, 0x1718), |
341 | bn_pack4(0xB5C5, 0x5DF0, 0x6F4C, 0x52C9), |
342 | bn_pack4(0x9B27, 0x83A2, 0xEC07, 0xA28F), |
343 | bn_pack4(0xE39E, 0x772C, 0x180E, 0x8603), |
344 | bn_pack4(0x3290, 0x5E46, 0x2E36, 0xCE3B), |
345 | bn_pack4(0xF174, 0x6C08, 0xCA18, 0x217C), |
346 | bn_pack4(0x670C, 0x354E, 0x4ABC, 0x9804), |
347 | bn_pack4(0x9ED5, 0x2907, 0x7096, 0x966D), |
348 | bn_pack4(0x1C62, 0xF356, 0x2085, 0x52BB), |
349 | bn_pack4(0x8365, 0x5D23, 0xDCA3, 0xAD96), |
350 | bn_pack4(0x6916, 0x3FA8, 0xFD24, 0xCF5F), |
351 | bn_pack4(0x98DA, 0x4836, 0x1C55, 0xD39A), |
352 | bn_pack4(0xC200, 0x7CB8, 0xA163, 0xBF05), |
353 | bn_pack4(0x4928, 0x6651, 0xECE4, 0x5B3D), |
354 | bn_pack4(0xAE9F, 0x2411, 0x7C4B, 0x1FE6), |
355 | bn_pack4(0xEE38, 0x6BFB, 0x5A89, 0x9FA5), |
356 | bn_pack4(0x0BFF, 0x5CB6, 0xF406, 0xB7ED), |
357 | bn_pack4(0xF44C, 0x42E9, 0xA637, 0xED6B), |
358 | bn_pack4(0xE485, 0xB576, 0x625E, 0x7EC6), |
359 | bn_pack4(0x4FE1, 0x356D, 0x6D51, 0xC245), |
360 | bn_pack4(0x302B, 0x0A6D, 0xF25F, 0x1437), |
361 | bn_pack4(0xEF95, 0x19B3, 0xCD3A, 0x431B), |
362 | bn_pack4(0x514A, 0x0879, 0x8E34, 0x04DD), |
363 | bn_pack4(0x020B, 0xBEA6, 0x3B13, 0x9B22), |
364 | bn_pack4(0x2902, 0x4E08, 0x8A67, 0xCC74), |
365 | bn_pack4(0xC4C6, 0x628B, 0x80DC, 0x1CD1), |
366 | bn_pack4(0xC90F, 0xDAA2, 0x2168, 0xC234), |
367 | bn_pack4(0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF) |
368 | }; |
369 | |
370 | const BIGNUM bn_group_6144 = { |
371 | (BN_ULONG *)bn_group_6144_value, |
372 | OSSL_NELEM(bn_group_6144_value), |
373 | OSSL_NELEM(bn_group_6144_value), |
374 | 0, |
375 | BN_FLG_STATIC_DATA |
376 | }; |
377 | |
378 | static const BN_ULONG bn_group_8192_value[] = { |
379 | bn_pack4(0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF), |
380 | bn_pack4(0x60C9, 0x80DD, 0x98ED, 0xD3DF), |
381 | bn_pack4(0xC81F, 0x56E8, 0x80B9, 0x6E71), |
382 | bn_pack4(0x9E30, 0x50E2, 0x7656, 0x94DF), |
383 | bn_pack4(0x9558, 0xE447, 0x5677, 0xE9AA), |
384 | bn_pack4(0xC919, 0x0DA6, 0xFC02, 0x6E47), |
385 | bn_pack4(0x889A, 0x002E, 0xD5EE, 0x382B), |
386 | bn_pack4(0x4009, 0x438B, 0x481C, 0x6CD7), |
387 | bn_pack4(0x3590, 0x46F4, 0xEB87, 0x9F92), |
388 | bn_pack4(0xFAF3, 0x6BC3, 0x1ECF, 0xA268), |
389 | bn_pack4(0xB1D5, 0x10BD, 0x7EE7, 0x4D73), |
390 | bn_pack4(0xF9AB, 0x4819, 0x5DED, 0x7EA1), |
391 | bn_pack4(0x64F3, 0x1CC5, 0x0846, 0x851D), |
392 | bn_pack4(0x4597, 0xE899, 0xA025, 0x5DC1), |
393 | bn_pack4(0xDF31, 0x0EE0, 0x74AB, 0x6A36), |
394 | bn_pack4(0x6D2A, 0x13F8, 0x3F44, 0xF82D), |
395 | bn_pack4(0x062B, 0x3CF5, 0xB3A2, 0x78A6), |
396 | bn_pack4(0x7968, 0x3303, 0xED5B, 0xDD3A), |
397 | bn_pack4(0xFA9D, 0x4B7F, 0xA2C0, 0x87E8), |
398 | bn_pack4(0x4BCB, 0xC886, 0x2F83, 0x85DD), |
399 | bn_pack4(0x3473, 0xFC64, 0x6CEA, 0x306B), |
400 | bn_pack4(0x13EB, 0x57A8, 0x1A23, 0xF0C7), |
401 | bn_pack4(0x2222, 0x2E04, 0xA403, 0x7C07), |
402 | bn_pack4(0xE3FD, 0xB8BE, 0xFC84, 0x8AD9), |
403 | bn_pack4(0x238F, 0x16CB, 0xE39D, 0x652D), |
404 | bn_pack4(0x3423, 0xB474, 0x2BF1, 0xC978), |
405 | bn_pack4(0x3AAB, 0x639C, 0x5AE4, 0xF568), |
406 | bn_pack4(0x2576, 0xF693, 0x6BA4, 0x2466), |
407 | bn_pack4(0x741F, 0xA7BF, 0x8AFC, 0x47ED), |
408 | bn_pack4(0x3BC8, 0x32B6, 0x8D9D, 0xD300), |
409 | bn_pack4(0xD8BE, 0xC4D0, 0x73B9, 0x31BA), |
410 | bn_pack4(0x3877, 0x7CB6, 0xA932, 0xDF8C), |
411 | bn_pack4(0x74A3, 0x926F, 0x12FE, 0xE5E4), |
412 | bn_pack4(0xE694, 0xF91E, 0x6DBE, 0x1159), |
413 | bn_pack4(0x12BF, 0x2D5B, 0x0B74, 0x74D6), |
414 | bn_pack4(0x043E, 0x8F66, 0x3F48, 0x60EE), |
415 | bn_pack4(0x387F, 0xE8D7, 0x6E3C, 0x0468), |
416 | bn_pack4(0xDA56, 0xC9EC, 0x2EF2, 0x9632), |
417 | bn_pack4(0xEB19, 0xCCB1, 0xA313, 0xD55C), |
418 | bn_pack4(0xF550, 0xAA3D, 0x8A1F, 0xBFF0), |
419 | bn_pack4(0x06A1, 0xD58B, 0xB7C5, 0xDA76), |
420 | bn_pack4(0xA797, 0x15EE, 0xF29B, 0xE328), |
421 | bn_pack4(0x14CC, 0x5ED2, 0x0F80, 0x37E0), |
422 | bn_pack4(0xCC8F, 0x6D7E, 0xBF48, 0xE1D8), |
423 | bn_pack4(0x4BD4, 0x07B2, 0x2B41, 0x54AA), |
424 | bn_pack4(0x0F1D, 0x45B7, 0xFF58, 0x5AC5), |
425 | bn_pack4(0x23A9, 0x7A7E, 0x36CC, 0x88BE), |
426 | bn_pack4(0x59E7, 0xC97F, 0xBEC7, 0xE8F3), |
427 | bn_pack4(0xB5A8, 0x4031, 0x900B, 0x1C9E), |
428 | bn_pack4(0xD55E, 0x702F, 0x4698, 0x0C82), |
429 | bn_pack4(0xF482, 0xD7CE, 0x6E74, 0xFEF6), |
430 | bn_pack4(0xF032, 0xEA15, 0xD172, 0x1D03), |
431 | bn_pack4(0x5983, 0xCA01, 0xC64B, 0x92EC), |
432 | bn_pack4(0x6FB8, 0xF401, 0x378C, 0xD2BF), |
433 | bn_pack4(0x3320, 0x5151, 0x2BD7, 0xAF42), |
434 | bn_pack4(0xDB7F, 0x1447, 0xE6CC, 0x254B), |
435 | bn_pack4(0x44CE, 0x6CBA, 0xCED4, 0xBB1B), |
436 | bn_pack4(0xDA3E, 0xDBEB, 0xCF9B, 0x14ED), |
437 | bn_pack4(0x1797, 0x27B0, 0x865A, 0x8918), |
438 | bn_pack4(0xB06A, 0x53ED, 0x9027, 0xD831), |
439 | bn_pack4(0xE5DB, 0x382F, 0x4130, 0x01AE), |
440 | bn_pack4(0xF8FF, 0x9406, 0xAD9E, 0x530E), |
441 | bn_pack4(0xC975, 0x1E76, 0x3DBA, 0x37BD), |
442 | bn_pack4(0xC1D4, 0xDCB2, 0x6026, 0x46DE), |
443 | bn_pack4(0x36C3, 0xFAB4, 0xD27C, 0x7026), |
444 | bn_pack4(0x4DF4, 0x35C9, 0x3402, 0x8492), |
445 | bn_pack4(0x86FF, 0xB7DC, 0x90A6, 0xC08F), |
446 | bn_pack4(0x93B4, 0xEA98, 0x8D8F, 0xDDC1), |
447 | bn_pack4(0xD006, 0x9127, 0xD5B0, 0x5AA9), |
448 | bn_pack4(0xB81B, 0xDD76, 0x2170, 0x481C), |
449 | bn_pack4(0x1F61, 0x2970, 0xCEE2, 0xD7AF), |
450 | bn_pack4(0x233B, 0xA186, 0x515B, 0xE7ED), |
451 | bn_pack4(0x99B2, 0x964F, 0xA090, 0xC3A2), |
452 | bn_pack4(0x287C, 0x5947, 0x4E6B, 0xC05D), |
453 | bn_pack4(0x2E8E, 0xFC14, 0x1FBE, 0xCAA6), |
454 | bn_pack4(0xDBBB, 0xC2DB, 0x04DE, 0x8EF9), |
455 | bn_pack4(0x2583, 0xE9CA, 0x2AD4, 0x4CE8), |
456 | bn_pack4(0x1A94, 0x6834, 0xB615, 0x0BDA), |
457 | bn_pack4(0x99C3, 0x2718, 0x6AF4, 0xE23C), |
458 | bn_pack4(0x8871, 0x9A10, 0xBDBA, 0x5B26), |
459 | bn_pack4(0x1A72, 0x3C12, 0xA787, 0xE6D7), |
460 | bn_pack4(0x4B82, 0xD120, 0xA921, 0x0801), |
461 | bn_pack4(0x43DB, 0x5BFC, 0xE0FD, 0x108E), |
462 | bn_pack4(0x08E2, 0x4FA0, 0x74E5, 0xAB31), |
463 | bn_pack4(0x7709, 0x88C0, 0xBAD9, 0x46E2), |
464 | bn_pack4(0xBBE1, 0x1757, 0x7A61, 0x5D6C), |
465 | bn_pack4(0x521F, 0x2B18, 0x177B, 0x200C), |
466 | bn_pack4(0xD876, 0x0273, 0x3EC8, 0x6A64), |
467 | bn_pack4(0xF12F, 0xFA06, 0xD98A, 0x0864), |
468 | bn_pack4(0xCEE3, 0xD226, 0x1AD2, 0xEE6B), |
469 | bn_pack4(0x1E8C, 0x94E0, 0x4A25, 0x619D), |
470 | bn_pack4(0xABF5, 0xAE8C, 0xDB09, 0x33D7), |
471 | bn_pack4(0xB397, 0x0F85, 0xA6E1, 0xE4C7), |
472 | bn_pack4(0x8AEA, 0x7157, 0x5D06, 0x0C7D), |
473 | bn_pack4(0xECFB, 0x8504, 0x58DB, 0xEF0A), |
474 | bn_pack4(0xA855, 0x21AB, 0xDF1C, 0xBA64), |
475 | bn_pack4(0xAD33, 0x170D, 0x0450, 0x7A33), |
476 | bn_pack4(0x1572, 0x8E5A, 0x8AAA, 0xC42D), |
477 | bn_pack4(0x15D2, 0x2618, 0x98FA, 0x0510), |
478 | bn_pack4(0x3995, 0x497C, 0xEA95, 0x6AE5), |
479 | bn_pack4(0xDE2B, 0xCBF6, 0x9558, 0x1718), |
480 | bn_pack4(0xB5C5, 0x5DF0, 0x6F4C, 0x52C9), |
481 | bn_pack4(0x9B27, 0x83A2, 0xEC07, 0xA28F), |
482 | bn_pack4(0xE39E, 0x772C, 0x180E, 0x8603), |
483 | bn_pack4(0x3290, 0x5E46, 0x2E36, 0xCE3B), |
484 | bn_pack4(0xF174, 0x6C08, 0xCA18, 0x217C), |
485 | bn_pack4(0x670C, 0x354E, 0x4ABC, 0x9804), |
486 | bn_pack4(0x9ED5, 0x2907, 0x7096, 0x966D), |
487 | bn_pack4(0x1C62, 0xF356, 0x2085, 0x52BB), |
488 | bn_pack4(0x8365, 0x5D23, 0xDCA3, 0xAD96), |
489 | bn_pack4(0x6916, 0x3FA8, 0xFD24, 0xCF5F), |
490 | bn_pack4(0x98DA, 0x4836, 0x1C55, 0xD39A), |
491 | bn_pack4(0xC200, 0x7CB8, 0xA163, 0xBF05), |
492 | bn_pack4(0x4928, 0x6651, 0xECE4, 0x5B3D), |
493 | bn_pack4(0xAE9F, 0x2411, 0x7C4B, 0x1FE6), |
494 | bn_pack4(0xEE38, 0x6BFB, 0x5A89, 0x9FA5), |
495 | bn_pack4(0x0BFF, 0x5CB6, 0xF406, 0xB7ED), |
496 | bn_pack4(0xF44C, 0x42E9, 0xA637, 0xED6B), |
497 | bn_pack4(0xE485, 0xB576, 0x625E, 0x7EC6), |
498 | bn_pack4(0x4FE1, 0x356D, 0x6D51, 0xC245), |
499 | bn_pack4(0x302B, 0x0A6D, 0xF25F, 0x1437), |
500 | bn_pack4(0xEF95, 0x19B3, 0xCD3A, 0x431B), |
501 | bn_pack4(0x514A, 0x0879, 0x8E34, 0x04DD), |
502 | bn_pack4(0x020B, 0xBEA6, 0x3B13, 0x9B22), |
503 | bn_pack4(0x2902, 0x4E08, 0x8A67, 0xCC74), |
504 | bn_pack4(0xC4C6, 0x628B, 0x80DC, 0x1CD1), |
505 | bn_pack4(0xC90F, 0xDAA2, 0x2168, 0xC234), |
506 | bn_pack4(0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF) |
507 | }; |
508 | |
509 | const BIGNUM bn_group_8192 = { |
510 | (BN_ULONG *)bn_group_8192_value, |
511 | OSSL_NELEM(bn_group_8192_value), |
512 | OSSL_NELEM(bn_group_8192_value), |
513 | 0, |
514 | BN_FLG_STATIC_DATA |
515 | }; |
516 | |
517 | static const BN_ULONG bn_generator_19_value[] = { 19 }; |
518 | |
519 | const BIGNUM bn_generator_19 = { |
520 | (BN_ULONG *)bn_generator_19_value, |
521 | 1, |
522 | 1, |
523 | 0, |
524 | BN_FLG_STATIC_DATA |
525 | }; |
526 | static const BN_ULONG bn_generator_5_value[] = { 5 }; |
527 | |
528 | const BIGNUM bn_generator_5 = { |
529 | (BN_ULONG *)bn_generator_5_value, |
530 | 1, |
531 | 1, |
532 | 0, |
533 | BN_FLG_STATIC_DATA |
534 | }; |
535 | static const BN_ULONG bn_generator_2_value[] = { 2 }; |
536 | |
537 | const BIGNUM bn_generator_2 = { |
538 | (BN_ULONG *)bn_generator_2_value, |
539 | 1, |
540 | 1, |
541 | 0, |
542 | BN_FLG_STATIC_DATA |
543 | }; |
544 | |
545 | #endif |
546 | |