[krbdev.mit.edu #8698] Resource leak in aname_replacer()

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

[krbdev.mit.edu #8698] Resource leak in aname_replacer()

Norm Green via RT
Hi Team,

aname_replacer() in krb5-1.16.1/src/lib/krb5/os/localauth_rule.c
assigns a allocated memory by calling strdup() to pointer current,
later if runs into any "goto cleanup", the allocated momory
"current" points to will not be freed when leaves this function.

The fix is to call free(current) before "goto cleanup".

Could someone help to take a look?


krb5-bugs mailing list
[hidden email]