[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: iptables forwarding question



On Fri, 17 Mar 2006, James Pifer wrote:

Is it possible to forward all traffic, not just a port, that comes from
a specific ip address to another address? Let's say you're running
iptables on a machine that is acting as a router on an internal network,
so traffic by port is not blocked.

I've been searching for rules and everything I'm finding is forwarding a
specific port. Is this possible? If so, an example rule(s) would be
appreciated.

Try

iptables -i ppp0 -t nat -A PREROUTING -j DNAT -s $remote_ip -d $local_ip --to-destination $internal_ip

--
Benjamin Franz


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]