Koozali.org: home of the SME Server
Legacy Forums => General Discussion (Legacy) => Topic started by: David Campbell on July 24, 2000, 06:44:37 PM
-
I know that the linux kernel allows port forwarding over a network - that is, when someone in the outside world accesses a certain port on the gateway, lets say.. port 40000 of IP xxx.xxx.xxx.xxx (xxx.xxx.xxx.xxx:40000) it will route all packets sent to that address to a machine in the network on a certain internal IP and port. (192.168.0.x:21)
Know what I mean? I'm wondering if anyone has figured out how to get this done with e-smith. I'm looking to use this wonderfull product as the base for my home network, but I need a solution that is capable of port forwarding.
Thanks,
Dave.
-
David,
Try the "search" link for port forwarding. Lots of answers are in the archieve.
See the comment following. ALL CREDIT TO THE ORIGINAL AUTHOR:b1tch-x.
Orville
>Author: b1tch-x
> Date: 07-16-2000 00:48
> There is a small packet forwarding program called "redir" It can listen on a set port and forward all the
> packets to the specified IP and port of another machine. It can also do transparent proxing so that the
> originating computers IP shows up at your internal machine instead of the forwarding machine. It also has is
> compatible with ftp servers.
> http://freshmeat.net/appindex/1999/03/14/921462694.html
> There is an RPM version for installation.
> usage:
> redir --lport= --cport= [options]
> redir --inetd --cport=
> Options are:-
> --lport= port to listen on
> --laddr=IP address of interface to listen on
> --cport= port to connect to
> --caddr= remote host to connect to
> --inetd run from inetd
> --debug output debugging info
> --timeout= set timeout to n seconds
> --syslog= log messages to syslog
> --name= tag syslog messages with 'str'
> --bind_addr=IP bind() outgoing IP to given addr
> --ftp redirect passive ftp connections
> --transproxy run in linux's transparent proxy mode
> Version 2.0 - $Id$
-
Do a search, hell get "rpmfind" (by far the greatest time saver for any rpm packaged linux suite) and do a rpmfind ipmasqadm. This allows for port forwarding. the syntax is quite easy and if i remember correctly ( my linux box is down as I test ou one of these linksys hardware internet routers ) is as follows
/usr/sbin/ipmasqadm portfw -L ip port -R "internal ip" port
you can also do ranges with autofw but i have heard this breaks down after running ot for some time, something about not syncing the resources with the kernel or something.
/usr/sbin/ipmasqadm autofw -L ip port:ports -R "internal ip" port:ports
I use just a small do until script with portfw on mine which I am not even going to try and remember at 5am