Latest working kernel version: N/A
Earliest failing kernel version: since introduction of IPv6 conntrack?
Hardware Environment: all
Software Environment: IPv6 + netfilter + IPv6 conntrack
The only two ICMPv6 packet types which IPv6 conntrack allows at present to initiate new connections are "echo request" and "node information query"; all other types appearing in this context are considered invalid. In particular, this includes two neighbour-discovery types specified in RFC 2461: "router solicitation" and "neighbour solicitation" - meaning that if a server drops all INVALID packets early in its INPUT or OUTPUT chain of IPv6 netfilter's filter table, neither of the two can be received from clients. Given that router solicitation is used for stateless network autoconfiguration and neighbour solicitation is an IPv6 equivalent of ARP requests, having these two dropped can be quite bad - especially the latter, as it pretty much kills IPv6 over Ethernet.
Steps to reproduce:
1. Obtain an IPv6 address assigned to an Ethernet interface of host A (link-local will do);
2. If necesssary, flush all ip6tables filter chains on host A and set their policies to ACCEPT;
3. From host B on the same Ethernet network, ping6 the aforementioned IP address to verify that everything works;
4. On host A, run something like "ip6tables -I INPUT 1 -m state --state INVALID -j DROP";
5. Try to repeat step 3. This time the ping should fail and counters associated with the aforementioned rule should increment;
6. Repeat all the above using OUTPUT instead of INPUT, with the same final result.
Created attachment 18387 [details]
A patch to add the two ICMPv6 solicitation types to the "valid new" list.
Attaching a proposed solution to the problem - the patch adds "router solicitation" and "neighbour solicitation" to the list of ICMPv6 types IPv6 conntrack considers allowed to initiate new connections.
PS. This problem was discovered and (hopefully) fixed collaboratively by Łukasz Stelmach <email@example.com> and myself, please attribute both of us should the patch make it into the kernel tree.
Thanks for the report and patch. This makes sense to me, but please send the patch and the problem description to firstname.lastname@example.org and CC Yasuyuki KOZAKAI <email@example.com>, who is more knowledgable about this subject than me (bugzilla doesn't allow me to CC him myself).
According to this post by Yasuyuki Kozakai to netfilter-devel
the issue requires a more complex solution. As such, this bug report was requested to be rejected.