How to do SSH agent forwarding on Mac terminal?
1) One way to use it is correct, the other is commandline argument -A
.
2) Agent is storing pass-phrases for keys. Agent forwarding is for using local identities (with or without pass-phrase) on remote servers without the need to copy them into possibly unsafe environment.
3) You can test with one server, fur example localhost.
4) echo "$SSH_AUTH_SOCK"
should verify it is set up, but doing ssh-add -L
would verify it more reliably, because it will test the connection to agent.