i have some problems with the ssh proxycommand. The authentication on the proxy works fine, but when i want to login to the remote-host it fails. The problem seems to be, that the proxy tries to login with my local rsa_key and not with the key stored on the proxy. Is there a way to fix this?This is what i want:Local -- local rsa --> Proxy -- proxy rsa --> hostThe Config-file i use:Host 192.168.178.32HostName 192.168.178.32User userPort 22IdentityFile ~/.ssh/id_rsa.pubHost 192.168.178.30HostName 192.168.178.30User userPort 22IdentityFile home/user/.ssh/id_rsa.pubProxyCommand ssh -W %h:%p -F ssh_config -p 22 192.168.178
Problems with SSH ProxyCommand
ssh;ssh tunneling;openssh
This probably isn't the answer you want to hear, but you can't do what you're trying to do.The ProxyCommand option in ssh expects to STDIN & STDOUT of the command to be connected directly to the destination host (%h) and port (%p). Thus it is the local ssh process which is talking to the remote sshd, not the proxy host's ssh process. And since it's the local ssh process talking to the remote, it doesn't have access to any ssh keys sitting on the proxy.Ultimately you only have 2 options:Copy the ssh key off the proxy host and install it locally.Set up a local command which transparently executes ssh on the proxy. For example: alias sshp='ssh -t 1.2.3.4 ssh'