can't tunnel through iptables
alex at alexandrite.boisestate.edu
Wed Nov 22 21:03:16 CET 2006
This is probably really an ssh question, but I'll try it here anyway. I
am running tptables v. 1.3.5 on FC5.
I am running iptables on my server. It locks down most everything for
INPUT, only opening up a few ports for mail and http.
I have a second script I can run besides my usual one. The only
difference between the two ar the following two lines in the second
iptables -A INPUT -p tcp -i eth0 --dport 143 -m state --state NEW -j ACCEPT
iptables -A INPUT -p udp -i eth0 --dport 143 -m state --state NEW -j ACCEPT
With those two lines in place, I can use an IMAP mail client
(thunderbird) from my laptop to connect with my server and everything
works great. Without them, thunderbird just hangs.
I would like to run the IMAP protocol through an ssh tunnel. So leaving
the orignal script in place, I su'd to root on my laptop and entered the
ssh -L 143:myserver:143 myserver
and it let me login to the server after performing the RSA
authentication, but I cannot connect my local thunderbird client to the
server - it hangs just as would if had not tried to establish the
I have tried several variations on this, including telling the
thunderbird on my laptop to use a non-well-known port, e.g., 8118, and
then not suing to root on the laptop but just as myself entering the
ssh -L 8118:myserver:143 myserver
to try to set up the tunnel without being root, but nothing seems to
work - thunderbird always tries and retries and eventually gives up
trying to establish a connection.
Thanks for any ideas.
--alex alex at math.boisestate.edu
<a href="http://math.boisestate.edu/~alex/">Alex Feldman</a>
More information about the netfilter