ssh - Avoid port-forwarding -
i have dd-wrt router setup ssh port-forwarding rule redirect each wan request towards host in private lan @ moment unavailable. possible avoid firewall redirection ssh parameter , connect directly router via ssh ? note: @ moment haven't direct access router.
one effective solution setup single ssh port forward 1 host on network, , use ssh forwarding via host others.
this can added client ssh config:
host anynameyoulike     hostname remotehostnameorip         proxycommand ssh -q proxyuser@proxyhostname.remotely.accessible nc -q0 %h %p         user remotehostnameoripuser         identityfile ~/.ssh/remotehostnameorip_id_rsa you can omit identityfile line if prefer alternative authentication. if set entry proxyuser@proxyhostname.remotely.accessible can have passwordless , transparent proxying.
further, can use wildcards, , have ssh automatically ssh via proxy matching host, eg:
host 10.10.10.*     proxycommand ssh -q proxyuser@proxyhostname.remotely.accessible nc -q0 %h %p 
Comments
Post a Comment