Mercurial > dropbear
comparison algo.h @ 1318:10e2a7727253 coverity
merge coverity
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Fri, 22 Jul 2016 00:08:02 +0800 |
parents | 750ec4ec4cbe |
children | 06d52bcb8094 |
comparison
equal
deleted
inserted
replaced
1286:7d02b83c61fd | 1318:10e2a7727253 |
---|---|
81 eg sha1-96 */ | 81 eg sha1-96 */ |
82 const unsigned char hashsize; | 82 const unsigned char hashsize; |
83 }; | 83 }; |
84 | 84 |
85 enum dropbear_kex_mode { | 85 enum dropbear_kex_mode { |
86 #if DROPBEAR_NORMAL_DH | |
86 DROPBEAR_KEX_NORMAL_DH, | 87 DROPBEAR_KEX_NORMAL_DH, |
88 #endif | |
89 #if DROPBEAR_ECDH | |
87 DROPBEAR_KEX_ECDH, | 90 DROPBEAR_KEX_ECDH, |
91 #endif | |
92 #if DROPBEAR_CURVE25519 | |
88 DROPBEAR_KEX_CURVE25519, | 93 DROPBEAR_KEX_CURVE25519, |
94 #endif | |
89 }; | 95 }; |
90 | 96 |
91 struct dropbear_kex { | 97 struct dropbear_kex { |
92 enum dropbear_kex_mode mode; | 98 enum dropbear_kex_mode mode; |
93 | 99 |
94 /* "normal" DH KEX */ | 100 /* "normal" DH KEX */ |
95 const unsigned char *dh_p_bytes; | 101 const unsigned char *dh_p_bytes; |
96 const int dh_p_len; | 102 const int dh_p_len; |
97 | 103 |
98 /* elliptic curve DH KEX */ | 104 /* elliptic curve DH KEX */ |
99 #ifdef DROPBEAR_ECDH | 105 #if DROPBEAR_ECDH |
100 const struct dropbear_ecc_curve *ecc_curve; | 106 const struct dropbear_ecc_curve *ecc_curve; |
101 #else | 107 #else |
102 const void* dummy; | 108 const void* dummy; |
103 #endif | 109 #endif |
104 | 110 |
120 | 126 |
121 | 127 |
122 algo_type * buf_match_algo(buffer* buf, algo_type localalgos[], | 128 algo_type * buf_match_algo(buffer* buf, algo_type localalgos[], |
123 enum kexguess2_used *kexguess2, int *goodguess); | 129 enum kexguess2_used *kexguess2, int *goodguess); |
124 | 130 |
125 #ifdef ENABLE_USER_ALGO_LIST | 131 #if DROPBEAR_USER_ALGO_LIST |
126 int check_user_algos(const char* user_algo_list, algo_type * algos, | 132 int check_user_algos(const char* user_algo_list, algo_type * algos, |
127 const char *algo_desc); | 133 const char *algo_desc); |
128 char * algolist_string(algo_type algos[]); | 134 char * algolist_string(algo_type algos[]); |
129 #endif | 135 #endif |
130 | 136 |