I hope I'm phrasing this question correctly. I have a SSH server that I use for testing that has 2 internet connections running on it. The LAN connection is always on, but the USB connection is on intermittently. Is it possible to restrict the tunnel so that it only ever uses the IP address of the USB connection to browse the internet?
This is what I'm currently using:
ssh -v -D 3456 email@example.com;
This is great, but it doesn't tell me if the server's secondary USB connection changes. As I know the IP (for arguments sake 199.90.09.78) of the USB connection, I was hoping I could restrict the tunnel to only using the USB and breaking if the USB went down. I've been playing around with the following:
ssh -v -D *:3456 -R *:3456:199.90.09.78:80 firstname.lastname@example.org;
But I think I'm using -R wrong. Is there a better way to achieve this?