diff common-kex.c @ 648:4222a1039b06

Clear a few buffers when possible
author Matt Johnston <matt@ucc.asn.au>
date Fri, 10 Feb 2012 18:32:18 +0800
parents 3aa74a4d83ae
children 03073a27abb3 4edea9f363d0
line wrap: on
line diff
--- a/common-kex.c	Tue Nov 08 00:01:47 2011 +0800
+++ b/common-kex.c	Fri Feb 10 18:32:18 2012 +0800
@@ -366,6 +366,11 @@
 	ses.keys = ses.newkeys;
 	ses.newkeys = NULL;
 
+	m_burn(C2S_IV, sizeof(C2S_IV));
+	m_burn(C2S_key, sizeof(C2S_key));
+	m_burn(S2C_IV, sizeof(S2C_IV));
+	m_burn(S2C_key, sizeof(S2C_key));
+
 	TRACE(("leave gen_new_keys"))
 }