Linux Netfilter discussions
 help / color / mirror / Atom feed
* upgrade to iptabels from ipchains
@ 2003-05-27 22:02 Esteban
  0 siblings, 0 replies; 5+ messages in thread
From: Esteban @ 2003-05-27 22:02 UTC (permalink / raw)
  To: netfilter

i used to have this:

$IPCHAINS -N soporte
$IPCHAINS -A FORWARD -s 10.0.0.0/25  -j soporte
$IPCHAINS -A soporte -s 10.0.1.1 -j MASQUERADE
$IPCHAINS -A soporte -j DENY

how can i do this with iptables?
the idea is to use chains for each group.

thanks!





^ permalink raw reply	[flat|nested] 5+ messages in thread
* RE: upgrade to iptabels from ipchains
@ 2003-05-27 23:11 George Vieira
  2003-05-28 14:22 ` Esteban
  0 siblings, 1 reply; 5+ messages in thread
From: George Vieira @ 2003-05-27 23:11 UTC (permalink / raw)
  To: Esteban, netfilter

Yes you can? You haven't reasearch much have you?

Do this...

IPCHAINS="/sbin/iptables"   # ;)

Just remember that iptables structure is different to ipchains in that INPUT is no longer part of the forwarding line.. it handles packets destined for itself ONLY..

Thanks,
____________________________________________
George Vieira
Systems Manager
georgev@citadelcomputer.com.au

Citadel Computer Systems Pty Ltd
http://www.citadelcomputer.com.au

 

-----Original Message-----
From: Esteban [mailto:eribicic@sinectis.com]
Sent: Wednesday, May 28, 2003 8:02 AM
To: netfilter@lists.netfilter.org
Subject: upgrade to iptabels from ipchains


i used to have this:

$IPCHAINS -N soporte
$IPCHAINS -A FORWARD -s 10.0.0.0/25  -j soporte
$IPCHAINS -A soporte -s 10.0.1.1 -j MASQUERADE
$IPCHAINS -A soporte -j DENY

how can i do this with iptables?
the idea is to use chains for each group.

thanks!






^ permalink raw reply	[flat|nested] 5+ messages in thread
* RE: upgrade to iptabels from ipchains
@ 2003-05-28 18:31 John Friel III
  0 siblings, 0 replies; 5+ messages in thread
From: John Friel III @ 2003-05-28 18:31 UTC (permalink / raw)
  To: 'netfilter@lists.samba.org'
  Cc: 'Leonardo Rodrigues Magalhães'

>     would became this in iptables
> 
> iptables -N soporte
> iptables -A soporte -s 10.0.1.1 -j ACCEPT
> iptables -A soporte -j DROP
> iptables -A FORWARD -s 10.0.0.0/25 -j soporte
> iptables -t nat -A POSTROUTING -s 10.0.1.1 -j MASQUERADE

And it should be noted that with these rules in place, all packets that get
forwarded to the soporte chain will get DROPPED because the forward rule
only forwards IP's in the range of 10.0.0.0-10.0.0.127 and the accept range
is restricted to -only- IP 10.0.1.1.  

The 4th rule should be:

iptables -A FORWARD -s 10.0.0.0/16 -j soporte




Cheers!
John Friel III
Frieltek Consulting, Inc.


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2003-05-28 18:31 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-05-27 22:02 upgrade to iptabels from ipchains Esteban
  -- strict thread matches above, loose matches on Subject: below --
2003-05-27 23:11 George Vieira
2003-05-28 14:22 ` Esteban
2003-05-28 16:05   ` Leonardo Rodrigues Magalhães
2003-05-28 18:31 John Friel III

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox