Hi,
I found and fixed some memory leaks which are occurring when calling the Tspi_TPM_Quote() and Tspi_TPM_Quote2() functions.
Attached are the patches relative to the trousers-0.3.9 tarball. Looking at the source code I suspect that there are some more leaks of a similar kind around.
Best regards
Andreas
======================================================================
Andreas Steffen andreas.steffen@strongswan.org
strongSwan - the Linux VPN Solution! www.strongswan.org
Institute for Internet Technologies and Applications
University of Applied Sciences Rapperswil
CH-8640 Rapperswil (Switzerland)
===========================================================[ITA-HSR]==
View and moderate all "bugs Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Bugs"
Patch fixing some memory leaks in libtspi
Last edit: Anonymous 2013-11-26
View and moderate all "bugs Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Bugs"
Hi Andreas, thanks for the patch!
In hunk 3 of this patch, when unloading pcrComp using Trspi_UnloadBlob_PCR_COMPOSITE, if Trspi_UnloadBlob_PCR_SELECTION fails, we'll try to free pcrComp.select.pcrSelect, which hasn't been initialized yet. If you can add a memset to 0 of pcrComp at the top, that would fix this issue.
Also to include this patch I need a Signed-off-by line at the top from you, which shows you agree to to the trousers DCO: http://trousers.sourceforge.net/dco.text
Thanks,
Kent
View and moderate all "bugs Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Bugs"
Updated and signed-off patch fixing some memory leaks in libtspi
View and moderate all "bugs Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Bugs"
Hi Kent,
I added the memset to 0 of pcrComp and signed-off and uploaded the updated patch.
Regards
Andreas
Thanks Andreas, applied!