Getting password prompt when trying to access server via a proxy server
I am trying to access from Mac and the proxy server and destination servers are both debian 10
Keys have been provided but still getting password promt, tried from a linux server also but still getting this password promt.
Checked from windows server with the same conf and it is working.
➜ ~ ssh dest-01 -v
OpenSSH_9.6p1, LibreSSL 3.3.6
debug1: Reading configuration data /Users/c.chandran/.ssh/config
debug1: /Users/xxxxx/.ssh/config line 7: Applying options for proxy-01
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 21: include /etc/ssh/ssh_config.d/* matched no files
debug1: /etc/ssh/ssh_config line 54: Applying options for *
debug1: Authenticator provider $SSH_SK_PROVIDER did not resolve; disabling
debug1: Executing proxy command: exec ssh -W proxy-01:22 ops-01
debug1: identity file /Users/xxxxx/.ssh/id_rsa type 0
debug1: identity file /Users/xxxxx/.ssh/id_rsa-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_9.6
[email protected]'s password:
➜ ~
➜ ~ cat .ssh/config
Host proxy_server
hostname 10.x.x.21
user root
IdentityFile ~/.ssh/id_rsa
ForwardAgent yes
Host dest-01
user root
IdentityFile ~/.ssh/id_rsa
ProxyCommand ssh -W %h:%p ops-01
➜ ~
Tried below given way also, but still asks for password
➜ ~ ssh -i .ssh/id_rsa -W proxy-01:22 root@ops-01 -v
OpenSSH_9.6p1, LibreSSL 3.3.6
debug1: Reading configuration data /Users/c.chandran/.ssh/config
debug1: /Users/xxxxxx/.ssh/config line 1: Applying options for ops-01
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 21: include /etc/ssh/ssh_config.d/* matched no files
debug1: /etc/ssh/ssh_config line 54: Applying options for *
debug1: Authenticator provider $SSH_SK_PROVIDER did not resolve; disabling
debug1: Connecting to 10.x.x.21 [10.x.x.21] port 22.
debug1: Connection established.
debug1: identity file .ssh/id_rsa type 0
debug1: identity file .ssh/id_rsa-cert type -1
debug1: identity file /Users/c.chandran/.ssh/id_rsa type 0
debug1: identity file /Users/c.chandran/.ssh/id_rsa-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_9.6
debug1: Remote protocol version 2.0, remote software version OpenSSH_8.4p1 Debian-5+deb11u1
debug1: compat_banner: match: OpenSSH_8.4p1 Debian-5+deb11u1 pat OpenSSH* compat 0x04000000
debug1: Authenticating to 10.x.x.21:22 as 'root'
debug1: load_hostkeys: fopen /Users/xxxxx/.ssh/known_hosts2: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts2: No such file or directory
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: algorithm: curve25519-sha256
debug1: kex: host key algorithm: ssh-ed25519
debug1: kex: server->client cipher: [email protected] MAC: <implicit> compression: none
debug1: kex: client->server cipher: [email protected] MAC: <implicit> compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: SSH2_MSG_KEX_ECDH_REPLY received
debug1: Server host key: ssh-ed25519 SHA256:kz1KTXarjthuyr8SrW0
debug1: load_hostkeys: fopen /Users/xxxx/.ssh/known_hosts2: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts2: No such file or directory
debug1: Host '10.x.x.21' is known and matches the ED25519 host key.
debug1: Found key in /Users/xxxx/.ssh/known_hosts:3
debug1: rekey out after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: rekey in after 134217728 blocks
debug1: SSH2_MSG_EXT_INFO received
debug1: kex_ext_info_client_parse: server-sig-algs=<ssh-ed25519,[email protected],ssh-rsa,rsa-sha2-256,rsa-sha2-512,ssh-dss,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,[email protected],[email protected]>
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey,password
debug1: Next authentication method: publickey
debug1: get_agent_identities: bound agent to hostkey
debug1: get_agent_identities: ssh_fetch_identitylist: agent contains no identities
debug1: Will attempt key: .ssh/id_rsa RSA SHA256:S+8QZlCgHD0As6iyOfWKrv3I explicit
debug1: Will attempt key: /Users/c.chandran/.ssh/id_rsa RSA SHA256:S+8QZlCgHDQI explicit
debug1: Offering public key: .ssh/id_rsa RSA SHA256:S+Krv3I explicit
debug1: Authentications that can continue: publickey,password
debug1: Offering public key: /Users/c.chandran/.ssh/id_rsa RSA SHA256:S+8QZlCgHDQi9ME1IGlLL7NuXoE320As6iyOfWKrv3I explicit
debug1: Authentications that can continue: publickey,password
debug1: Next authentication method: password
[email protected]'s password:
➜ ~
Tried accessing via direct proxy command
Chiju Chandran is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.