kentpeacock / rpms / openssh

Forked from rpms/openssh 2 years ago
Clone
f09e2e
diff -up openssh-6.1p1/sshconnect2.c.canohost openssh-6.1p1/sshconnect2.c
f09e2e
--- openssh-6.1p1/sshconnect2.c.canohost	2012-10-30 10:52:59.593301692 +0100
f09e2e
+++ openssh-6.1p1/sshconnect2.c	2012-10-30 11:01:12.870301632 +0100
f09e2e
@@ -699,12 +699,15 @@ userauth_gssapi(Authctxt *authctxt)
f09e2e
 	static u_int mech = 0;
f09e2e
 	OM_uint32 min;
f09e2e
 	int ok = 0;
f09e2e
-	const char *gss_host;
f09e2e
+	const char *gss_host = NULL;
f09e2e
 
f09e2e
 	if (options.gss_server_identity)
f09e2e
 		gss_host = options.gss_server_identity;
f09e2e
-	else if (options.gss_trust_dns)
f09e2e
+	else if (options.gss_trust_dns) {
1d31ef
 		gss_host = get_canonical_hostname(active_state, 1);
f09e2e
+		if ( strcmp( gss_host, "UNKNOWN" )  == 0 )
f09e2e
+			gss_host = authctxt->host;
f09e2e
+	}
f09e2e
 	else
f09e2e
 		gss_host = authctxt->host;
f09e2e