bugzilla-daemon at bugzilla.mindrot.org
2016-Aug-22 20:06 UTC
[Bug 2607] New: accept location off ssh binary via environment variable or deduce it from /proc/
https://bugzilla.mindrot.org/show_bug.cgi?id=2607
Bug ID: 2607
Summary: accept location off ssh binary via environment
variable or deduce it from /proc/
Product: Portable OpenSSH
Version: 7.3p1
Hardware: All
OS: Linux
Status: NEW
Severity: enhancement
Priority: P5
Component: ssh
Assignee: unassigned-bugs at mindrot.org
Reporter: stefan.tomanek-mindrot at wertarbyte.de
Created attachment 2864
--> https://bugzilla.mindrot.org/attachment.cgi?id=2864&action=edit
use /proc/self/exe or environment variable to launch port forwarding
for ProxyJump
When testing the relatively new JumpHost (-J) functionality, ssh
constructed several command lines to facilitate the port forwarding;
the command line however always starts with "ssh", picking the wrong
binary from $PATH (and not from my development directory). This patch
adds the option to use an environment variable (SSH_CUSTOM_CMD) to
specify the command line to start with; on platforms that support it
(Linux), it can also use /proc/self/exe to identify the ssh binary
currently run and use it to create the port forwarding, avoiding
confusions and possible problems when using different versions of ssh.
github reference:
https://github.com/wertarbyte/openssh-portable/compare/master...proxyjump_custom_cmd
--
You are receiving this mail because:
You are watching the assignee of the bug.
bugzilla-daemon at bugzilla.mindrot.org
2016-Aug-22 23:51 UTC
[Bug 2607] accept location off ssh binary via environment variable or deduce it from /proc/
https://bugzilla.mindrot.org/show_bug.cgi?id=2607
Darren Tucker <dtucker at zip.com.au> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |dtucker at zip.com.au
--- Comment #1 from Darren Tucker <dtucker at zip.com.au> ---
Since /proc/self is not portable I don't think we should be cluttering
up the code with it, and if you're going to set an environment variable
to tell it where to find ssh, why not $PATH?
--
You are receiving this mail because:
You are watching someone on the CC list of the bug.
You are watching the assignee of the bug.
bugzilla-daemon at bugzilla.mindrot.org
2016-Aug-23 05:37 UTC
[Bug 2607] accept location off ssh binary via environment variable or deduce it from /proc/
https://bugzilla.mindrot.org/show_bug.cgi?id=2607
Bert Wesarg <Bert.Wesarg at googlemail.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |Bert.Wesarg at googlemail.com
--- Comment #2 from Bert Wesarg <Bert.Wesarg at googlemail.com> ---
I missed the initial discussion about -J, but why not using av[0]?
--
You are receiving this mail because:
You are watching someone on the CC list of the bug.
You are watching the assignee of the bug.
bugzilla-daemon at bugzilla.mindrot.org
2016-Aug-23 06:16 UTC
[Bug 2607] accept location off ssh binary via environment variable or deduce it from /proc/
https://bugzilla.mindrot.org/show_bug.cgi?id=2607 --- Comment #3 from Darren Tucker <dtucker at zip.com.au> --- (In reply to Bert Wesarg from comment #2)> I missed the initial discussion about -J, but why not using av[0]?That's a better idea. It doesn't cover all cases, but it might cover enough. The cases I can think of are: 1) full path: currently will exhibit the described behaviour, using argv[0] would fix it. 2) relative path: ditto, assuming ssh(1) doesn't chdir, which I don't think it does. 3) no path, $PATH set and exported. should work. 4) no path, $PATH set but not exported. could potentially pick up a different ssh. -- You are receiving this mail because: You are watching the assignee of the bug. You are watching someone on the CC list of the bug.
bugzilla-daemon at bugzilla.mindrot.org
2018-Jun-09 03:19 UTC
[Bug 2607] accept location off ssh binary via environment variable or deduce it from /proc/
https://bugzilla.mindrot.org/show_bug.cgi?id=2607
Damien Miller <djm at mindrot.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |WORKSFORME
Status|NEW |RESOLVED
CC| |djm at mindrot.org
--- Comment #4 from Damien Miller <djm at mindrot.org> ---
ssh now tries to use argv[0] and falls back to $PATH if it doesn't look
like an executable
--
You are receiving this mail because:
You are watching the assignee of the bug.
You are watching someone on the CC list of the bug.
bugzilla-daemon at mindrot.org
2021-Apr-23 05:03 UTC
[Bug 2607] accept location off ssh binary via environment variable or deduce it from /proc/
https://bugzilla.mindrot.org/show_bug.cgi?id=2607
Damien Miller <djm at mindrot.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |CLOSED
--- Comment #5 from Damien Miller <djm at mindrot.org> ---
closing resolved bugs as of 8.6p1 release
--
You are receiving this mail because:
You are watching someone on the CC list of the bug.
You are watching the assignee of the bug.
Possibly Parallel Threads
- [Bug 2606] New: IPv6 bind address vs autoconfiguration privacy
- [Bug 1883] New: use setproctitle for persistent mux master
- [Bug 2679] New: ssh mux process (and maybe others) should perhaps cd /
- [PATCH] mux: fix memory leak of control path if bind() fails
- [Bug 1815] New: RemoteCommand and PseudoTTY config options