Bug 3015 - ssh: usability issue with -J and multiple jump hosts
Summary: ssh: usability issue with -J and multiple jump hosts
Status: CLOSED FIXED
Alias: None
Product: Portable OpenSSH
Classification: Unclassified
Component: ssh (show other bugs)
Version: 7.9p1
Hardware: All Linux
: P5 minor
Assignee: Assigned to nobody
URL: https://bugs.debian.org/929669
Keywords:
Depends on:
Blocks: V_8_1
  Show dependency treegraph
 
Reported: 2019-05-29 09:55 AEST by Paul Wise
Modified: 2023-01-13 13:42 AEDT (History)
2 users (show)

See Also:


Attachments
slightly more helpful error message (544 bytes, patch)
2019-06-07 14:08 AEST, Damien Miller
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Paul Wise 2019-05-29 09:55:24 AEST
When I try to proxy jump through multiple hosts using the most intuitive way to do that (multiple -J options), ssh misleads me into believing that ssh only supports a single jump host but if I use the right syntax by separating the hosts with commas then it works fine.

I suggest that ssh either automatically combine the values of all the proxy jump options using commas or print an error directing the user to manually combine the values of all the proxy jump options using commas.

   $ ssh -J master.debian.org -J paradis.debian.org draghi.debian.org echo yay
   Only a single -J option permitted

   $ ssh -J master.debian.org,paradis.debian.org draghi.debian.org echo yay
   yay
Comment 1 Damien Miller 2019-05-31 13:30:21 AEST
Unfortunately, combining options as you suggest would make the handling of -J inconsistent with other command-line options as everything is first-match-wins. I don't think introducing an inconsistency is worth it for this case.
Comment 2 Paul Wise 2019-05-31 13:40:33 AEST
What about my other suggestion?

> print an error directing the user to manually combine the values of all the proxy jump options using commas.
Comment 3 Damien Miller 2019-06-07 14:08:46 AEST
Created attachment 3290 [details]
slightly more helpful error message
Comment 4 Paul Wise 2019-06-07 14:20:53 AEST
Looks good, thanks.
Comment 5 Damien Miller 2019-07-19 13:05:57 AEST
This is applied and will be in OpenSSH 8.1.
Comment 6 Damien Miller 2019-10-09 15:11:43 AEDT
Close bugs fixed in openssh-8.1 release cycle