-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Memory leak in XECKEY computeECDHSecret #387
Comments
jasonkatonica
added a commit
to jasonkatonica/OpenJCEPlus
that referenced
this issue
Dec 11, 2024
The context allocated in the method `XECKEY.computeECDHSecret` was never freed when a key was successfully generated. This update frees memory associated with the context prior to return of the secret key bytes. Whitespace and formatting was also done to make use of brackets for if statements. Fixes IBM#387 Signed-off-by: Jason Katonica <[email protected]>
jasonkatonica
added a commit
to jasonkatonica/OpenJCEPlus
that referenced
this issue
Dec 18, 2024
The context allocated in the method `XECKEY.computeECDHSecret` was never freed when a key was successfully generated. This update frees memory associated with the context prior to return of the secret key bytes. Whitespace and formatting was also done to make use of brackets for if statements. Fixes IBM#387 Signed-off-by: Jason Katonica <[email protected]>
jasonkatonica
added a commit
to jasonkatonica/OpenJCEPlus
that referenced
this issue
Dec 18, 2024
The context allocated in the method `XECKEY.computeECDHSecret` was never freed when a key was successfully generated. This update frees memory associated with the context prior to return of the secret key bytes. Whitespace and formatting was also done to make use of brackets for if statements. Fixes IBM#387 Signed-off-by: Jason Katonica <[email protected]>
jasonkatonica
added a commit
to jasonkatonica/OpenJCEPlus
that referenced
this issue
Jan 2, 2025
The context allocated in the method `XECKEY.computeECDHSecret` was never freed when a key was successfully generated. This update frees memory associated with the context prior to return of the secret key bytes. Whitespace and formatting was also done to make use of brackets for if statements. Fixes IBM#387 Signed-off-by: Jason Katonica <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
By placing the test
BaseTestXDH
classes variationtestXDH_X25519
into a tight loop with many iterations it can be observed that the following context is leaking as per a leak report:The context being allocated on this line is never released:
OpenJCEPlus/src/main/native/ECKey.c
Line 2127 in 8711f83
The text was updated successfully, but these errors were encountered: