-
Notifications
You must be signed in to change notification settings - Fork 8.1k
Closed
Closed
Copy link
Labels
Resolution-FixedThe issue is fixed.The issue is fixed.
Description
Prerequisites
- Write a descriptive title.
- Make sure you are able to repro it on the latest released version
- Search the existing issues.
- Refer to the FAQ.
- Refer to Differences between Windows PowerShell 5.1 and PowerShell.
Steps to reproduce
When using an ssh command with a proxy host (-J) parameter on a Mac, it tries to relaunch the command using exec. Before 7.3.0 this worked through a workaround exec file that was created in /usr/local/microsoft/powershell/7:
#!/usr/bin/env pwsh
param($command)
& $command @argsNow, after 7.3.0 upgrade, with or without the "exec" file, the command returns an error whenever attempting to spawn a proxy command.
Expected behavior
(bash)$ ssh 10.1.0.12 -J proxyhost.local -v
OpenSSH_8.6p1, LibreSSL 3.3.6
debug1: Setting implicit ProxyCommand from ProxyJump: ssh -v -W '[%h]:%p' proxyhost.local
debug1: Authenticator provider $SSH_SK_PROVIDER did not resolve; disabling
debug1: Executing proxy command: exec ssh -v -W '[10.1.0.12]:22' proxyhost.local
debug1: identity file /Users/user/.ssh/id_rsa type 0
debug1: identity file /Users/user/.ssh/id_rsa-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_8.6
OpenSSH_8.6p1, LibreSSL 3.3.6
debug1: Authenticator provider $SSH_SK_PROVIDER did not resolve; disabling
debug1: Connecting to proxyhost.local port 22.
debug1: Connection established.Actual behavior
PS> ssh 10.1.0.12 -J proxyhost.local -v
OpenSSH_8.6p1, LibreSSL 3.3.6
debug1: Setting implicit ProxyCommand from ProxyJump: /usr/bin/ssh -v -W '[%h]:%p' proxyhost.local
debug1: Authenticator provider $SSH_SK_PROVIDER did not resolve; disabling
debug1: Executing proxy command: exec /usr/bin/ssh -v -W '[10.1.0.12]:22' proxyhost.local
debug1: identity file /Users/user/.ssh/id_rsa type 0
debug1: identity file /Users/user/.ssh/id_rsa-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_8.6
debug1: kex_exchange_identification: banner line 0: \033[31;1mSwitch-Process: \033[31;1mA positional parameter cannot be found that accepts argument '/usr/bin/ssh'.\033[0m
kex_exchange_identification: Connection closed by remote host
Connection closed by UNKNOWN port 65535Error details
$nullEnvironment data
Name Value
---- -----
PSVersion 7.3.0
PSEdition Core
GitCommitId 7.3.0
OS Darwin 21.6.0 Darwin Kernel Version 21.6.0: Thu Sep 29 20:13:56 PDT 2022; root:xnu-8020.240.7~1/RELEASE_ARM64_T6000
Platform Unix
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0Visuals
Metadata
Metadata
Assignees
Labels
Resolution-FixedThe issue is fixed.The issue is fixed.
