summaryrefslogtreecommitdiff
path: root/lib/vauth
diff options
context:
space:
mode:
Diffstat (limited to 'lib/vauth')
-rw-r--r--lib/vauth/krb5_sspi.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/vauth/krb5_sspi.c b/lib/vauth/krb5_sspi.c
index da08f8f03..4ad5f3ac0 100644
--- a/lib/vauth/krb5_sspi.c
+++ b/lib/vauth/krb5_sspi.c
@@ -92,7 +92,7 @@ CURLcode Curl_auth_create_gssapi_user_message(struct SessionHandle *data,
return CURLE_OUT_OF_MEMORY;
}
- if(!krb5->credentials) {
+ if(!krb5->output_token) {
/* Query the security package for Kerberos */
status = s_pSecFn->QuerySecurityPackageInfo((TCHAR *)
TEXT(SP_NAME_KERBEROS),
@@ -110,7 +110,9 @@ CURLcode Curl_auth_create_gssapi_user_message(struct SessionHandle *data,
krb5->output_token = malloc(krb5->token_max);
if(!krb5->output_token)
return CURLE_OUT_OF_MEMORY;
+ }
+ if(!krb5->credentials) {
if(userp && *userp) {
/* Populate our identity structure */
result = Curl_create_sspi_identity(userp, passwdp, &krb5->identity);