hdb: Fix crashes with WRONG_REALM
With HDB_ERR_WRONG_REALM the backend needs to expose the principal, so we should not free the entry otherwise the main kdc code will crash. Signed-off-by: Stefan Metzmacher <metze@samba.org>
This commit is contained in:

committed by
Luke Howard

parent
19b337a0fb
commit
7d103f8657
@@ -1575,7 +1575,7 @@ fetch_it(krb5_context context,
|
||||
}
|
||||
|
||||
out:
|
||||
if (ret)
|
||||
if (ret != 0 && ret != HDB_ERR_WRONG_REALM)
|
||||
hdb_free_entry(context, db, ent);
|
||||
krb5_free_principal(context, nsprinc);
|
||||
free(host);
|
||||
|
Reference in New Issue
Block a user