Blame SOURCES/openssh-6.1p1-gssapi-canohost.patch

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