View | Details | Raw Unified | Return to bug 1200
Collapse All | Expand All

(-)openssh-krb5-3.8.1p1/auth2-hostbased.c (-4 / +5 lines)
Lines 142-156 Link Here
142
	debug2("userauth_hostbased: chost %s resolvedname %s ipaddr %s",
142
	debug2("userauth_hostbased: chost %s resolvedname %s ipaddr %s",
143
	    chost, resolvedname, ipaddr);
143
	    chost, resolvedname, ipaddr);
144
144
145
	if (((len = strlen(chost)) > 0) && chost[len - 1] == '.') {
146
		debug2("stripping trailing dot from chost %s", chost);
147
		chost[len - 1] = '\0';
148
	}
149
145
	if (options.hostbased_uses_name_from_packet_only) {
150
	if (options.hostbased_uses_name_from_packet_only) {
146
		if (auth_rhosts2(pw, cuser, chost, chost) == 0)
151
		if (auth_rhosts2(pw, cuser, chost, chost) == 0)
147
			return 0;
152
			return 0;
148
		lookup = chost;
153
		lookup = chost;
149
	} else {
154
	} else {
150
		if (((len = strlen(chost)) > 0) && chost[len - 1] == '.') {
151
			debug2("stripping trailing dot from chost %s", chost);
152
			chost[len - 1] = '\0';
153
		}
154
		if (strcasecmp(resolvedname, chost) != 0)
155
		if (strcasecmp(resolvedname, chost) != 0)
155
			logit("userauth_hostbased mismatch: "
156
			logit("userauth_hostbased mismatch: "
156
			    "client sends %s, but we resolve %s to %s",
157
			    "client sends %s, but we resolve %s to %s",

Return to bug 1200