[krbdev.mit.edu #2885] krb5 1-4 introduced memory leak in krb5_get_credentials

Ezra Peisach via RT rt-comment at krbdev.mit.edu
Sun Jan 16 09:42:15 EST 2005


I have tracked down the problem... It is in krb5/krb/gc_frm_kdc.c...
This was changed in ticket 2541... (which has not been pulled up yet
but is flagged).

If there is already a tgt in the cache, then memory is leaked....
About line 127 - alot of code is skipped.  otgt is never assigned tgt,
free_tgt is never set and memory is leaked.

The introduction of otgt confuses matters... At one place
otgt is assigned tgt - so keeping track of what memory needs to be freed
is tricky and needs careful examination.


More information about the krb5-bugs mailing list