comparison common-algo.c @ 762:a78a38e402d1 ecc

- Fix various hardcoded uses of SHA1 - rename curves to nistp256 etc - fix svr-auth.c TRACE problem
author Matt Johnston <matt@ucc.asn.au>
date Mon, 08 Apr 2013 00:10:57 +0800
parents ac2158e3e403
children d1575fdc29a6
comparison
equal deleted inserted replaced
761:ac2158e3e403 762:a78a38e402d1
225 static struct dropbear_kex kex_dh_group1 = {dh_p_1, DH_P_1_LEN, NULL, &sha1_desc }; 225 static struct dropbear_kex kex_dh_group1 = {dh_p_1, DH_P_1_LEN, NULL, &sha1_desc };
226 static struct dropbear_kex kex_dh_group14 = {dh_p_14, DH_P_14_LEN, NULL, &sha1_desc }; 226 static struct dropbear_kex kex_dh_group14 = {dh_p_14, DH_P_14_LEN, NULL, &sha1_desc };
227 227
228 #ifdef DROPBEAR_ECDH 228 #ifdef DROPBEAR_ECDH
229 #ifdef DROPBEAR_ECC_256 229 #ifdef DROPBEAR_ECC_256
230 static struct dropbear_kex kex_ecdh_secp256r1 = {NULL, 0, &ecc_curve_secp256r1, &sha256_desc }; 230 static struct dropbear_kex kex_ecdh_nistp256 = {NULL, 0, &ecc_curve_nistp256, &sha256_desc };
231 #endif 231 #endif
232 #ifdef DROPBEAR_ECC_384 232 #ifdef DROPBEAR_ECC_384
233 static struct dropbear_kex kex_ecdh_secp384r1 = {NULL, 0, &ecc_curve_secp384r1, &sha384_desc }; 233 static struct dropbear_kex kex_ecdh_nistp384 = {NULL, 0, &ecc_curve_nistp384, &sha384_desc };
234 #endif 234 #endif
235 #ifdef DROPBEAR_ECC_521 235 #ifdef DROPBEAR_ECC_521
236 static struct dropbear_kex kex_ecdh_secp521r1 = {NULL, 0, &ecc_curve_secp521r1, &sha512_desc }; 236 static struct dropbear_kex kex_ecdh_nistp521 = {NULL, 0, &ecc_curve_nistp521, &sha512_desc };
237 #endif 237 #endif
238 #endif // DROPBEAR_ECDH 238 #endif // DROPBEAR_ECDH
239 239
240 240
241 algo_type sshkex[] = { 241 algo_type sshkex[] = {
242 #ifdef DROPBEAR_ECDH 242 #ifdef DROPBEAR_ECDH
243 #ifdef DROPBEAR_ECC_256 243 #ifdef DROPBEAR_ECC_256
244 {"ecdh-sha2-secp256r1", 0, &kex_ecdh_secp256r1, 1, NULL}, 244 {"ecdh-sha2-nistp256", 0, &kex_ecdh_nistp256, 1, NULL},
245 #endif 245 #endif
246 #ifdef DROPBEAR_ECC_384 246 #ifdef DROPBEAR_ECC_384
247 {"ecdh-sha2-secp384r1", 0, &kex_ecdh_secp384r1, 1, NULL}, 247 {"ecdh-sha2-nistp384", 0, &kex_ecdh_nistp384, 1, NULL},
248 #endif 248 #endif
249 #ifdef DROPBEAR_ECC_521 249 #ifdef DROPBEAR_ECC_521
250 {"ecdh-sha2-secp521r1", 0, &kex_ecdh_secp521r1, 1, NULL}, 250 {"ecdh-sha2-nistp521", 0, &kex_ecdh_nistp521, 1, NULL},
251 #endif 251 #endif
252 #endif 252 #endif
253 {"diffie-hellman-group1-sha1", 0, &kex_dh_group1, 1, NULL}, 253 {"diffie-hellman-group1-sha1", 0, &kex_dh_group1, 1, NULL},
254 {"diffie-hellman-group14-sha1", 0, &kex_dh_group14, 1, NULL}, 254 {"diffie-hellman-group14-sha1", 0, &kex_dh_group14, 1, NULL},
255 {NULL, 0, NULL, 0, NULL} 255 {NULL, 0, NULL, 0, NULL}