public inbox for netdev@vger.kernel.org 
 help / color / mirror / Atom feed
From: "Gerd v. Egidy" <lists@egidy•de>
To: Patrick McHardy <kaber@trash•net>
Cc: hadi@cyberus•ca, netfilter-devel@vger•kernel.org, netdev@vger•kernel.org
Subject: Re: -j MARK in raw vs. mangle (was Re: xfrm by MARK: tcp problems when mark for in and out differ)
Date: Fri, 15 Oct 2010 10:05:32 +0200	[thread overview]
Message-ID: <201010151005.32973.lists@egidy.de> (raw)
In-Reply-To: <4CB7FCEB.5070804@trash.net>

Hi Patrick,

> > So it seems this has nothing to do with xfrm, but that the MARK target
> > has different effects when used in raw than in mangle. I was using raw
> > because I had to set conntrack zones too and it was more conveniant to
> > do both in one place.
> > 
> > Can one of the netfilter guys comment on this? Is using MARK in raw not
> > fully supported or has known deficiencies?
> 
> No, the problem is most likely that for outgoing packets, the XFRM
> lookup is done with the route lookup before the packet is even sent,
> so once it hits the raw or mangle table, it is too late. mangle however
> performs rerouting when the mark value changes, at which point a new
> XFRM lookup is performed.

ah, this would explain it. Thanks for the explanation. I'll just stick with 
mangle for marking.

Kind regards,

Gerd

-- 
Address (better: trap) for people I really don't want to get mail from:
jonas@cactusamerica•com

  reply	other threads:[~2010-10-15  8:05 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-14 14:16 -j MARK in raw vs. mangle (was Re: xfrm by MARK: tcp problems when mark for in and out differ) Gerd v. Egidy
2010-10-15  7:04 ` Patrick McHardy
2010-10-15  8:05   ` Gerd v. Egidy [this message]
  -- strict thread matches above, loose matches on Subject: below --
2010-10-13 13:57 xfrm by MARK: tcp problems when mark for in and out differ Gerd v. Egidy
2010-10-14 13:01 ` Gerd v. Egidy
2010-10-14 13:14   ` jamal
2010-10-14 14:14     ` -j MARK in raw vs. mangle (was Re: xfrm by MARK: tcp problems when mark for in and out differ) Gerd v. Egidy

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=201010151005.32973.lists@egidy.de \
    --to=lists@egidy$(echo .)de \
    --cc=hadi@cyberus$(echo .)ca \
    --cc=kaber@trash$(echo .)net \
    --cc=netdev@vger$(echo .)kernel.org \
    --cc=netfilter-devel@vger$(echo .)kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox