netfilter-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Florian Westphal <fw@strlen.de>
To: Phil Sutter <phil@nwl.cc>,
	Quentin Armitage <quentin@armitage.org.uk>,
	netfilter-devel@vger.kernel.org, Florian Westphal <fw@strlen.de>
Subject: Re: [PATCH] netfilter: nftables: fix documentation for dup statement
Date: Thu, 27 Aug 2020 19:40:15 +0200	[thread overview]
Message-ID: <20200827174015.GC7319@breakpoint.cc> (raw)
In-Reply-To: <20200827170203.GM23632@orbyte.nwl.cc>

Phil Sutter <phil@nwl.cc> wrote:
> Hi,
> 
> On Thu, Aug 27, 2020 at 04:42:00PM +0100, Quentin Armitage wrote:
> > The dup statement requires an address, and the device is optional,
> > not the other way round.
> > 
> > Signed-off-by: Quentin Armitage <quentin@armitage.org.uk>
> > ---
> >  doc/statements.txt | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/doc/statements.txt b/doc/statements.txt
> > index 9155f286..835db087 100644
> > --- a/doc/statements.txt
> > +++ b/doc/statements.txt
> > @@ -648,7 +648,7 @@ The dup statement is used to duplicate a packet and send the
> > copy to a different
> >  destination.
> >  
> >  [verse]
> > -*dup to* 'device'
> > +*dup to* 'address'
> >  *dup to* 'address' *device* 'device'
> >  
> >  .Dup statement values
> 
> The examples are wrong, too. I wonder if this is really just a mistake
> and all three examples given (including the "advanced" usage using a
> map) are just wrong or if 'dup' actually was meant to support
> duplicating to a device in mirror port fashion.

Right, 'dup to eth0' can be used in the netdev ingress hook.

For dup from ipv4/ipv6 families the address is needed.

  reply	other threads:[~2020-08-27 17:40 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-27 15:42 [PATCH] netfilter: nftables: fix documentation for dup statement Quentin Armitage
2020-08-27 17:02 ` Phil Sutter
2020-08-27 17:40   ` Florian Westphal [this message]
2020-08-27 18:59     ` Quentin Armitage
2020-08-31 16:49       ` Phil Sutter
2020-09-03  8:15         ` Quentin Armitage
2020-08-27 17:55 ` Pablo Neira Ayuso

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=20200827174015.GC7319@breakpoint.cc \
    --to=fw@strlen.de \
    --cc=netfilter-devel@vger.kernel.org \
    --cc=phil@nwl.cc \
    --cc=quentin@armitage.org.uk \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).