diff options
author | Damien Miller <djm@cvs.openbsd.org> | 2023-04-26 01:36:04 +0000 |
---|---|---|
committer | Damien Miller <djm@cvs.openbsd.org> | 2023-04-26 01:36:04 +0000 |
commit | 2784d1cf038080c4f66455c5bebbfa3d5d4eb9b6 (patch) | |
tree | 1475a20e8b40f5f75782ad4bbfd8cc09ef8c973e /usr.bin | |
parent | 39f499bb8b2635fc8b7b2eff69e2898f53c28302 (diff) |
Check for ProxyJump=none in CanonicalizeHostname logic.
Previously ssh would incorrectly refuse to canonicalise the hostname
if ProxyJump was explicitly set to "none" when CanonicalizeHostname=yes
bz3567; ok dtucker
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/ssh/ssh.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/ssh/ssh.c b/usr.bin/ssh/ssh.c index 2f59969f852..d31b1a19585 100644 --- a/usr.bin/ssh/ssh.c +++ b/usr.bin/ssh/ssh.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ssh.c,v 1.587 2023/03/30 07:19:50 dtucker Exp $ */ +/* $OpenBSD: ssh.c,v 1.588 2023/04/26 01:36:03 djm Exp $ */ /* * Author: Tatu Ylonen <ylo@cs.hut.fi> * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland @@ -445,7 +445,7 @@ resolve_canonicalize(char **hostp, int port) * a proxy unless the user specifically requests so. */ direct = option_clear_or_none(options.proxy_command) && - options.jump_host == NULL; + option_clear_or_none(options.jump_host); if (!direct && options.canonicalize_hostname != SSH_CANONICALISE_ALWAYS) return NULL; @@ -1179,7 +1179,7 @@ main(int ac, char **av) * CanonicalizeHostname=always */ direct = option_clear_or_none(options.proxy_command) && - options.jump_host == NULL; + option_clear_or_none(options.jump_host); if (addrs == NULL && config_has_permitted_cnames(&options) && (direct || options.canonicalize_hostname == SSH_CANONICALISE_ALWAYS)) { if ((addrs = resolve_host(host, options.port, |