All of lore.kernel.org
 help / color / mirror / Atom feed
From: Duncan Roe <duncan_roe@optusnet.com.au>
To: netfilter@vger.kernel.org
Subject: Re: nftables: How to filter only ipv6 SSH traffic in an inet table?
Date: Wed, 7 Feb 2018 11:32:51 +1100	[thread overview]
Message-ID: <20180207003251.GA2621@dimstar.local.net> (raw)
In-Reply-To: <20180206172809.f7a238e06cef71d52ec92ae0@bluenox07.de>

On Tue, Feb 06, 2018 at 05:28:09PM +0100, Merlin Büge wrote:
> Hey all,
>
> I'm playing around with nftables and wonder how I could filter e.g.
> only ipv6 SSH traffic in an inet table?
>
> I've set up a basic inet filter table with the three chains input,
> forward and output.
>
> When I then do:
>
> "nft add rule inet filter input ip6 nexthdr tcp tcp dport ssh drop"
>
> ... "nft list ruleset" is showing my only "tcp dport ssh drop", so it
> seems the ipv6 bit got missed. I also tried:
>
> "nft add rule inet filter input meta nfproto ipv6 tcp dport ssh drop"
>
> ... but it yields to the same output.
>
> What am I doing wrong here?
>
> Note that I'm not wanting to actually drop IPv6 SSH traffic, I'm just
> trying to get used to nftables :)
>
> I'm using nftables v0.8.2 on an up-to-date archlinux.
>
> Any pointer appreciated!
>
> Thanks!
> --
> Merlin Büge <toni@bluenox07.de>

Hi Merlin,

Could you possibly post all of the output from nft list ruleset?

That would give us some context around the one-liner,

Cheers ... Duncan.

  reply	other threads:[~2018-02-07  0:32 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-06 16:28 nftables: How to filter only ipv6 SSH traffic in an inet table? Merlin Büge
2018-02-07  0:32 ` Duncan Roe [this message]
2018-02-07 19:26   ` Pablo Neira Ayuso
2018-02-08  3:14     ` Merlin Büge
2018-02-18  4:00       ` Duncan Roe
2018-02-18  4:10         ` Duncan Roe
2018-02-18  8:52         ` Duncan Roe

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=20180207003251.GA2621@dimstar.local.net \
    --to=duncan_roe@optusnet.com.au \
    --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.