Run Command Before Starting SSH Connection

This a quick hack I found while I was looking to run a knock script before connecting to servers which I have the SSH service protected with a knock sequence. In my setup I used the ProxyCommand option in the ssh_config file to loop over my loop-back interface.


Related Post

1 Response

  1. Damo says:

    SSHing to localhost is a bit too much IMO, you can replace it with nc %h %p

Leave a Reply

Your email address will not be published. Required fields are marked *