comparison common-session.c @ 761:ac2158e3e403 ecc

ecc kind of works, needs fixing/testing
author Matt Johnston <matt@ucc.asn.au>
date Sun, 07 Apr 2013 01:36:42 +0800
parents 2e573f39b88e
children 7dcb46da72d9
comparison
equal deleted inserted replaced
760:f336d232fc63 761:ac2158e3e403
101 ses.keys->trans.crypt_mode = &dropbear_mode_none; 101 ses.keys->trans.crypt_mode = &dropbear_mode_none;
102 102
103 ses.keys->recv.algo_mac = &dropbear_nohash; 103 ses.keys->recv.algo_mac = &dropbear_nohash;
104 ses.keys->trans.algo_mac = &dropbear_nohash; 104 ses.keys->trans.algo_mac = &dropbear_nohash;
105 105
106 ses.keys->algo_kex = -1; 106 ses.keys->algo_kex = NULL;
107 ses.keys->algo_hostkey = -1; 107 ses.keys->algo_hostkey = -1;
108 ses.keys->recv.algo_comp = DROPBEAR_COMP_NONE; 108 ses.keys->recv.algo_comp = DROPBEAR_COMP_NONE;
109 ses.keys->trans.algo_comp = DROPBEAR_COMP_NONE; 109 ses.keys->trans.algo_comp = DROPBEAR_COMP_NONE;
110 110
111 #ifndef DISABLE_ZLIB 111 #ifndef DISABLE_ZLIB
233 if (!sessinitdone) { 233 if (!sessinitdone) {
234 TRACE(("leave session_cleanup: !sessinitdone")) 234 TRACE(("leave session_cleanup: !sessinitdone"))
235 return; 235 return;
236 } 236 }
237 237
238 m_free(ses.session_id); 238 if (ses.session_id) {
239 buf_burn(ses.session_id);
240 buf_free(ses.session_id);
241 ses.session_id = NULL;
242 }
243 if (ses.hash) {
244 buf_burn(ses.hash);
245 buf_free(ses.hash);
246 ses.hash = NULL;
247 }
239 m_burn(ses.keys, sizeof(struct key_context)); 248 m_burn(ses.keys, sizeof(struct key_context));
240 m_free(ses.keys); 249 m_free(ses.keys);
241 250
242 chancleanup(); 251 chancleanup();
243 252