From 383a33d160cefbfd1b40fef81f72eadbf9303a66 Mon Sep 17 00:00:00 2001 From: "djm@openbsd.org" Date: Fri, 21 Sep 2018 03:11:36 +0000 Subject: upstream: Treat connections with ProxyJump specified the same as ones with a ProxyCommand set with regards to hostname canonicalisation (i.e. don't try to canonicalise the hostname unless CanonicalizeHostname is set to 'always'). Patch from Sven Wegener via bz#2896 OpenBSD-Commit-ID: 527ff501cf98bf65fb4b29ed0cb847dda10f4d37 --- ssh.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'ssh.c') diff --git a/ssh.c b/ssh.c index f4204c88d..849fae355 100644 --- a/ssh.c +++ b/ssh.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ssh.c,v 1.492 2018/09/20 03:31:49 djm Exp $ */ +/* $OpenBSD: ssh.c,v 1.493 2018/09/21 03:11:36 djm Exp $ */ /* * Author: Tatu Ylonen * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland @@ -1137,10 +1137,9 @@ main(int ac, char **av) if (addrs == NULL && options.num_permitted_cnames != 0 && (direct || options.canonicalize_hostname == SSH_CANONICALISE_ALWAYS)) { if ((addrs = resolve_host(host, options.port, - option_clear_or_none(options.proxy_command), - cname, sizeof(cname))) == NULL) { + direct, cname, sizeof(cname))) == NULL) { /* Don't fatal proxied host names not in the DNS */ - if (option_clear_or_none(options.proxy_command)) + if (direct) cleanup_exit(255); /* logged in resolve_host */ } else check_follow_cname(direct, &host, cname); -- cgit v1.2.3