I have a Linux machine (box 1) with Internet service connected to a Wifi router sitting right next to it, through Ethernet (eth0). The purpose of this router is so I can share this Internet connection with another machine (box 2) over Wifi.
BOX 1 --> eth0 --> ROUTER --> wifi --> BOX 2
In the router configuration, LAN is 10.42.43.1 (the Ethernet cable with Internet) and WAN is 10.42.42.x
The output of 'ifconfig -a' on BOX 1 identifies eth0 as 10.42.43.1 as expected, but I can't access the router configuration through that address. I can't figure out what address that would be. I can only access the router from BOX 2. That is not ideal, but I can live with it.
BOX 2 has IP number 10.42.42.101, assigned to it by the Wifi router.
BOX 2 finds BOX 1 on 10.42.43.1. BOX 1 runs a Web server on port 8001 and I can view the pages served by BOX 1 browsing 10.42.43.1:8001 on BOX 2.
I have created on BOX 1 an SSH tunnel to a remote machine that runs an email server. Something like this:
ssh -f -q -f -N -C -T email@example.com -L 9110:0.0.0.0:110
So, on BOX 1, I can configure my email client to poll 127.0.0.1:9110 to download my email securely.
Now I want to do the same on BOX 2, but I can't. I thought I would be able to poll 10.42.43.1:9110, but that doesn't work.
I am running iptables, but the entire eth0 interface is marked as trusted, and that is probably proven by the fact that I can browse web pages served by BOX 1 from BOX 2. For that reason, I don't believe that iptables is blocking this particular attempt.
What else could it be?
Note: I've searched high and low and found quite a few recipes for making sort of a "multiple hop" tunnel, sort of like two or three connected tunnels. I don't want that. I don't want to have to run sshd on BOX 1 or even ssh on BOX 2. I want to use the tunnel on BOX 1 directly from BOX 2.