All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vigneswaran R <vignesh@atc.tcs.com>
To: mart.frauenlob@chello.at
Cc: Fabio Pedretti <fabio.pedretti@unibs.it>, netfilter@vger.kernel.org
Subject: Re: About using -i with MASQUERADE
Date: Fri, 29 Jan 2016 17:04:42 +0530	[thread overview]
Message-ID: <56AB4E52.4030802@atc.tcs.com> (raw)
In-Reply-To: <56AB4C4A.7020709@chello.at>

On 01/29/2016 04:56 PM, Mart Frauenlob wrote:
> On 29.01.2016 11:10, Vigneswaran R wrote:
> [...]
>>
>> In the FORWARDING chain, you can mark the packets based on incoming
>> Interface. Then use the mark to MASQUERADE the packets at the
>> POSTROUTING chain. eg.,
>>
>> -t nat -A FORWARD -i eth3 -j MARK --set-mark 0xffff
>> -t nat -A POSTROUTING -m mark --mark 0xffff  -j MASQUERADE
>>
>> (I hope this should work. However, I haven't tried this by myself.)
>>
>> Vignesh
>
>
> Hello,
>
> there is no FORWARD chain in the nat table. And marking in the nat 
> table will only mark packets of conntrack state NEW.
> Better do the marking in the mangle or filter table.

Oops, I intended filter table only. (copy paste error).

-t filter -A FORWARD -i eth3 -j MARK --set-mark 0xffff

Vignesh

>
> Best regards,
>
> Mart
>


  reply	other threads:[~2016-01-29 11:34 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-22 11:53 About using -i with MASQUERADE Fabio Pedretti
2016-01-22 14:07 ` Bastian Bittorf
2016-01-29 10:10 ` Vigneswaran R
2016-01-29 11:26   ` Mart Frauenlob
2016-01-29 11:34     ` Vigneswaran R [this message]
2016-01-29 21:25     ` Pascal Hambourg

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=56AB4E52.4030802@atc.tcs.com \
    --to=vignesh@atc.tcs.com \
    --cc=fabio.pedretti@unibs.it \
    --cc=mart.frauenlob@chello.at \
    --cc=netfilter@vger.kernel.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.