Solved using ssh-agent to forward ssh session

Hello all,
I am trying to solve the following task:
Log-in from putty(with agent forwarding enabled) to FreeBSD server by SSH and then log-in to another server using FreeBSD server as hopper. No keys are going to be stored under .ssh folder in hopper. Recently I am not able to configure and start ssh-agent(1) which (I guess) holds the necessary keys after user log-in. I.e. agent has been started from cli, but ssh-add(1) replies it can't connect to the agent. Have no idea what could be wrong and how to start it properly.
Vadim
 
You don't need to start ssh-agent(1) or ssh-add(1). It works pretty much out of the box. You do need to have your public key in ~/.ssh/authorized_keys on all machines, including the intermediates.

With PuTTY and Windows make sure you have Pageant running and your key is loaded there. Within PuTTY make sure Connection -> SSH -> Auth -> "Allow agent forwarding" is enabled. Everything else pretty much works "automagically".
 
You are right - it works automagically when I have started Pageant. No need to configure agent
 
Back
Top