]> git.ipfire.org Git - thirdparty/krb5.git/commit
Fix minor leaks in principal conversions 793/head
authorGreg Hudson <ghudson@mit.edu>
Fri, 15 Jun 2018 15:20:34 +0000 (11:20 -0400)
committerGreg Hudson <ghudson@mit.edu>
Tue, 19 Jun 2018 13:50:25 +0000 (09:50 -0400)
commit971c5213f7c501d3943bc0ff8db918f1616aa35a
treef093f1b002c75c8597746f239d078fbb0c9e51ac
parentbeeb2828945a41d86488e391ce440bacee0ec8a4
Fix minor leaks in principal conversions

In krb5_524_conv_principal(), if the realm we read from the profile is
too long for the result buffer, free the profile value before
returning.

In krb5_425_conv_principal(), if krb5_get_realm_domain() fails, still
free any leftover allocated data using a cleanup label.  The only one
that could be left over is dummy_value which we could address easily
enough within the loop, but we shouldn't sidestep the cleanup code.

Both bugs were reported by Bean Zhang.

ticket: 8695
src/lib/krb5/krb/conv_princ.c