All of lore.kernel.org
 help / color / mirror / Atom feed
* [LARTC] about fw marks  on netfilter
@ 2003-07-26  4:56 Rio Martin.
  2003-07-26 12:12 ` Jose Luis Domingo Lopez
  0 siblings, 1 reply; 2+ messages in thread
From: Rio Martin. @ 2003-07-26  4:56 UTC (permalink / raw)
  To: lartc

Dear all,
Is it okay if i put many different rules on single mark.
example:

iptables -t mangle -A PREROUTING -p tcp -s 192.168.1.0/24 -j MARK --set-mark 1
iptables -t mangle -A PREROUTING -p tcp -s 192.168.2.0/24 -j MARK --set-mark 1
...
iptables -t mangle -A PREROUTING -p tcp -s 192.168.10.0/24 -j MARK--set-mark 1

Regards,
Rio Martin.
-- 
Q:  How many mathematicians does it take to screw in a lightbulb?
A:  One.  He gives it to six Californians, thereby reducing the problem
    to the earlier joke.

_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

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

* Re: [LARTC] about fw marks  on netfilter
  2003-07-26  4:56 [LARTC] about fw marks on netfilter Rio Martin.
@ 2003-07-26 12:12 ` Jose Luis Domingo Lopez
  0 siblings, 0 replies; 2+ messages in thread
From: Jose Luis Domingo Lopez @ 2003-07-26 12:12 UTC (permalink / raw)
  To: lartc

On Saturday, 26 July 2003, at 11:56:55 +0700,
Rio Martin. wrote:

> Is it okay if i put many different rules on single mark.
> iptables -t mangle -A PREROUTING -p tcp -s 192.168.1.0/24 -j MARK --set-mark 1
> iptables -t mangle -A PREROUTING -p tcp -s 192.168.2.0/24 -j MARK --set-mark 1
> ...
> iptables -t mangle -A PREROUTING -p tcp -s 192.168.10.0/24 -j MARK--set-mark 1
> 
What you show is perfectly legal with iptables/netfilter. MARK target
just associates some number (the mark) to the packets it applies to, and
this mark travels along the (inmodified) packet all its way through the
linux kernel (that it, marks won't propagate trough the network, the
have just local significance).

Don't forget to do "iptables --match mark --mark 1 --jump ACCEPT" or
whatever as soon as possible, because a later "--set-mark 2" would
overwrite the previously set mark.

Regards,

-- 
Jose Luis Domingo Lopez
Linux Registered User #189436     Debian Linux Sid (Linux 2.6.0-test1)
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

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

end of thread, other threads:[~2003-07-26 12:12 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-07-26  4:56 [LARTC] about fw marks on netfilter Rio Martin.
2003-07-26 12:12 ` Jose Luis Domingo Lopez

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.