From: "Omar Garcia" <omar.garcia@fractalia.biz>
To: netfilter@lists.netfilter.org
Subject: Re: Differences between -j MARK and -j CONNMARK
Date: Fri, 11 Feb 2005 13:59:08 +0100 [thread overview]
Message-ID: <00f301c51039$79a7d670$910010ac@coco> (raw)
In-Reply-To: 1108125634.4489.24.camel@hubcap.ljm.dom
----- Original Message -----
From: "Jason Opperisano" <opie@817west.com>
To: <netfilter@lists.netfilter.org>
Sent: Friday, February 11, 2005 1:40 PM
Subject: Re: Differences between -j MARK and -j CONNMARK
>
> first off--i'm sure this is just your typed example, but you *do*
> realize that using -I in every rule results in your rules ending up in
> reverse order, right? that is, your first group of commands will result
> in the following rules:
>
> *mangle
> -A POSTROUTING -j CONNMARK --save-mark
> -A POSTROUTING -m ipp2p --bit -j MARK --set-mark 30
> -A POSTROUTING -m ipp2p --ipp2p -j MARK --set-mark 30
> -A POSTROUTING -m mark ! --mark 0 -j ACCEPT
> -A POSTROUTING -j CONNMARK --restore-mark
>
> which is most certainly *not* the order you want when using
> --restore-mark and --save mark.
Yes, of course. It was a mistake.
Thanks.
> anyways--to your actual question--i have found that version 1; i.e using
> -j MARK --set-mark instead of -j CONNMARK --set-mark, is more reliable.
> i have no idea why this is. i have a feeling that the CONNMARK target
> uses more intelligence to determine whether this packet should be marked
> or not. -j MARK --set-mark will just simply mark the packet; no fuss,
> no muss, and then -j CONNMARK --save-mark will save it to the conntrack
> table to be restored on the next packet in the connection--which is
> exactly what you want.
Thanks
>
> --
> "Alright brain, you don't like me and I don't like you. But let's just
> get through this and then I can get back to killing you with beer."
> --The Simpsons
>
>
>
next prev parent reply other threads:[~2005-02-11 12:59 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-02-11 9:52 Differences between -j MARK and -j CONNMARK Omar Garcia
2005-02-11 10:05 ` Vinod Chandran
2005-02-11 12:40 ` Jason Opperisano
2005-02-11 12:59 ` Omar Garcia [this message]
2005-02-20 23:33 ` Ian! D. Allen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='00f301c51039$79a7d670$910010ac@coco' \
--to=omar.garcia@fractalia.biz \
--cc=netfilter@lists.netfilter.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.