summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2007-04-13 05:37:08 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 14:50:38 -0500
commit2bedec23eeeed0ef7559fad927be9d70df71538a (patch)
treeff286e9341777d949b1619e9641af81a3dfdb687 /source4
parentf2e611f355b5f937ed03d622e46ddeefe859d564 (diff)
downloadsamba-2bedec23eeeed0ef7559fad927be9d70df71538a.tar.gz
samba-2bedec23eeeed0ef7559fad927be9d70df71538a.tar.bz2
samba-2bedec23eeeed0ef7559fad927be9d70df71538a.zip
r22208: Print the target principal name, to help with kdc unreachable errors.
Andrew Bartlett (This used to be commit bbde5b6a2f85f22110d6840857eaceb6b923c1b4)
Diffstat (limited to 'source4')
-rw-r--r--source4/auth/gensec/gensec_gssapi.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/source4/auth/gensec/gensec_gssapi.c b/source4/auth/gensec/gensec_gssapi.c
index a59aa8a07c..11f94b7708 100644
--- a/source4/auth/gensec/gensec_gssapi.c
+++ b/source4/auth/gensec/gensec_gssapi.c
@@ -320,20 +320,17 @@ static NTSTATUS gensec_gssapi_client_start(struct gensec_security *gensec_securi
principal = gensec_get_target_principal(gensec_security);
if (principal && lp_client_use_spnego_principal()) {
- name_token.value = discard_const_p(uint8_t, principal);
- name_token.length = strlen(principal);
-
name_type = GSS_C_NULL_OID;
} else {
principal = talloc_asprintf(gensec_gssapi_state, "%s@%s",
gensec_get_target_service(gensec_security),
hostname);
- name_token.value = discard_const_p(uint8_t, principal);
- name_token.length = strlen(principal);
-
name_type = GSS_C_NT_HOSTBASED_SERVICE;
}
+ name_token.value = discard_const_p(uint8_t, principal);
+ name_token.length = strlen(principal);
+
maj_stat = gss_import_name (&min_stat,
&name_token,
@@ -351,7 +348,7 @@ static NTSTATUS gensec_gssapi_client_start(struct gensec_security *gensec_securi
case 0:
break;
case KRB5_KDC_UNREACH:
- DEBUG(3, ("Cannot reach a KDC we require\n"));
+ DEBUG(3, ("Cannot reach a KDC we require to contact %s\n", principal));
return NT_STATUS_INVALID_PARAMETER; /* Make SPNEGO ignore us, we can't go any further here */
default:
DEBUG(1, ("Aquiring initiator credentails failed\n"));