# HG changeset patch # User Matt Johnston # Date 1328869938 -28800 # Node ID 4222a1039b065920882d7d55fb39b3ebd3374c0d # Parent a98e2ced7bfa5bf776930c625b421b9f5aee8e2e Clear a few buffers when possible diff -r a98e2ced7bfa -r 4222a1039b06 circbuffer.c --- a/circbuffer.c Tue Nov 08 00:01:47 2011 +0800 +++ b/circbuffer.c Fri Feb 10 18:32:18 2012 +0800 @@ -48,6 +48,7 @@ void cbuf_free(circbuffer * cbuf) { + m_burn(cbuf->data, cbuf->size); m_free(cbuf->data); m_free(cbuf); } diff -r a98e2ced7bfa -r 4222a1039b06 common-kex.c --- 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")) }