HostKey check for remote hosts via local ports

Tobias Karlsson jtkarlsson1973 at yahoo.com
Sat Jun 28 04:28:12 EST 2008


Another issue for which there might be some tricks that I don't know of:

I have a set of ports on my local machine forwarded (via ssh LocalForward) to machines that I can't directly reach on the localhost. However, as I connect to those machines I get HostKey warnings since it looks for the HostKey of the 'localhost' and depending on the port, it is of course different.

Is there a way around this? Could the host key be associated to another name like:

Host amsterdam
  Hostname = localhost
  Port = 40022
  KeyHostname = amsterdam

Host paris
  Hostname = localhost
  Port = 41022
  Keyhostname = paris

Host europe
  Hostname = ...
  Localforward = 40022 amsterdam.localnet:22
  Localforward = 41022 paris.localnet:22

Or, if you let me dream away a bit:

Host amsterdam
  Hostname = amsterdam.localnet via europe

Host paris
  Hostname = paris.localnet via europe

Host europe
  Hostname = ...

/Tobias



      


More information about the openssh-unix-dev mailing list