krb5_error_code code;
krb5_creds in_creds, *out_creds = NULL;
+ *output_cred = NULL;
memset(&in_creds, 0, sizeof(in_creds));
- memset(&out_creds, 0, sizeof(out_creds));
in_creds.client = user->princ;
in_creds.server = impersonator_cred->name->princ;
time_rec,
context);
- *output_cred_handle = (gss_cred_id_t)cred;
+ if (!GSS_ERROR(major_status))
+ *output_cred_handle = (gss_cred_id_t)cred;
k5_mutex_unlock(&((krb5_gss_cred_id_t)impersonator_cred_handle)->lock);
krb5_free_context(context);
krb5_error_code code;
krb5_gss_cred_id_t cred = NULL;
+ *output_cred = NULL;
k5_mutex_assert_locked(&impersonator_cred->lock);
if (!kg_is_initiator_cred(impersonator_cred) ||