Linux Netfilter discussions
 help / color / mirror / Atom feed
From: Pascal Hambourg <pascal@plouf.fr.eu.org>
To: Christoph Anton Mitterer
	<christoph.anton.mitterer@physik.uni-muenchen.de>
Cc: netfilter <netfilter@vger.kernel.org>
Subject: Re: dropping UNTRACKED packets, breaks IPv6 - why?
Date: Sun, 28 Jul 2013 09:51:03 +0200	[thread overview]
Message-ID: <51F4CD67.8010600@plouf.fr.eu.org> (raw)
In-Reply-To: <1374958401.5194.13.camel@fermat.scientia.net>

Christoph Anton Mitterer a écrit :
> 
> On Sat, 2013-07-27 at 21:49 +0200, Pascal Hambourg wrote:
>> You should not blindly drop UNTRACKED or INVALID IPv6 packets.
> 
> Why not INVALID IPv6 packets? AFAICS, the patch you've mentioned only
> removes tracking for these kinds of packets, but doesn't mark them
> invalid.

Because before the patch, older kernels marked NDP packets INVALID.

> 1) So... are there any other reasonable default rules one should make
> for IPv6 (or IPv4) then?

Sure. On an ethernet-like interface, accept the following ICMPv6 types,
with hop limit 255 as these packets are link-local only :
- neighbour solicitation and neighbour advertisement in both directions
- router solicitation in output and router advertisement in input if the
box is an IPv6 host using stateless autoconfiguration
- router solicitation in input and router advertisement in output if the
box is an IPv6 router with radvd or the like listening on this interface.
Then you can drop anything else you (don't) like.

> I guess the kernel itself already assures that any address of his own
> interfaces are not accepted as source address for packages coming over
> the wire? I.e. to prevent spoofing of the hosts own addresses.

Yes.

> 2) What about INVALID/UNTRACKED with respect to IPv4? Is it there still
> advisable to DROP them unconditionally?

AFAIK, IPv4 has nothing like NDP, so
- INVALID : normally, yes.
- UNTRACKED : AFAIK, it can only be the result of the NOTRACK target, so
you would know about it.

> Oh and btw: Does the IPsec handling I do still work with IPv6 or has
> anything changed there as well?

I don't use IPSec and don't know about its handling by iptables.

      reply	other threads:[~2013-07-28  7:51 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-26  1:59 dropping UNTRACKED packets, breaks IPv6 - why? Christoph Anton Mitterer
2013-07-26  7:07 ` Arturo Borrero Gonzalez
2013-07-26 20:20   ` Christoph Anton Mitterer
2013-07-27 19:49 ` Pascal Hambourg
2013-07-27 20:53   ` Christoph Anton Mitterer
2013-07-28  7:51     ` Pascal Hambourg [this message]

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=51F4CD67.8010600@plouf.fr.eu.org \
    --to=pascal@plouf.fr.eu.org \
    --cc=christoph.anton.mitterer@physik.uni-muenchen.de \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox