diff options
Diffstat (limited to 'source4/kdc')
-rw-r--r-- | source4/kdc/pac-glue.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/source4/kdc/pac-glue.c b/source4/kdc/pac-glue.c index 52685083bd..c986d60fdf 100644 --- a/source4/kdc/pac-glue.c +++ b/source4/kdc/pac-glue.c @@ -37,6 +37,7 @@ struct auth_serversupplied_info *server_info; char *username, *p; const char *realm; + DATA_BLOB tmp_blob; TALLOC_CTX *mem_ctx = talloc_named(config, 0, "samba_get_pac context"); if (!mem_ctx) { return ENOMEM; @@ -73,9 +74,16 @@ context, krbtgt_keyblock, server_keyblock, - pac); + &tmp_blob); + if (ret) { + DEBUG(1, ("PAC encoding failed: %s\n", + smb_get_krb5_error_message(context, ret, mem_ctx))); + talloc_free(mem_ctx); + return ret; + } + + ret = krb5_data_copy(pac, tmp_blob.data, tmp_blob.length); talloc_free(mem_ctx); - return ret; } |