Skip Menu |
 

Subject: memory leak in SPNEGO
Date: Tue, 2 Mar 2010 20:50:21 -0500
From: "Arlene Berry" <aberry@likewise.com>
To: <krb5-bugs@mit.edu>
We caught a memory leak in SPNEGO. This fixed it for us:

Index: src/lib/gssapi/spnego/spnego_mech.c
===================================================================
--- src/lib/gssapi/spnego/spnego_mech.c (revision 23762)
+++ src/lib/gssapi/spnego/spnego_mech.c (working copy)
@@ -1739,9 +1739,12 @@
}
if (ret == GSS_S_COMPLETE) {
*context_handle = (gss_ctx_id_t)sc->ctx_handle;
- if (sc->internal_name != GSS_C_NO_NAME &&
- src_name != NULL) {
+ if (sc->internal_name != GSS_C_NO_NAME) {
+ if (src_name != NULL) {
*src_name = sc->internal_name;
+ } else {
+ gss_release_name(&tmpmin, &sc->internal_name);
+ }
}
release_spnego_ctx(&sc);
} else if (ret != GSS_S_CONTINUE_NEEDED) {
From: ghudson@mit.edu
Subject: SVN Commit

Release the internal_name field of a SPNEGO context if it has not been
claimed for a caller argument.


https://github.com/krb5/krb5/commit/48a8cb4a973b23c3c11598eb4742fea36a37c4b5
Commit By: ghudson
Revision: 23772
Changed Files:
U trunk/src/lib/gssapi/spnego/spnego_mech.c
From: tlyu@mit.edu
Subject: SVN Commit

pull up r23772 from trunk

------------------------------------------------------------------------
r23772 | ghudson | 2010-03-05 15:35:26 -0500 (Fri, 05 Mar 2010) | 7 lines

ticket: 6674
target_version: 1.8.1
tags: pullup

Release the internal_name field of a SPNEGO context if it has not been
claimed for a caller argument.

https://github.com/krb5/krb5/commit/bfbb07dc7832a497d68190161ffd46ec86fcd597
Commit By: tlyu
Revision: 23808
Changed Files:
U branches/krb5-1-8/src/lib/gssapi/spnego/spnego_mech.c