-
Notifications
You must be signed in to change notification settings - Fork 179
Description
Important notices
Before you add a new report, we ask you kindly to acknowledge the following:
- [ x] I have read the contributing guide lines at https://github.com/opnsense/core/blob/master/CONTRIBUTING.md
- [ x] I am convinced that my issue is new after having checked both open and closed issues at https://github.com/opnsense/core/issues?q=is%3Aissue
Describe the bug
Preface:
So in IPv6 intermediate Devices like Firewalls or Routers are not allowed to fragment packets. In the IPv6 specifications it is clearly stated that fragmentation should only occour on the end-devices (Server and Client) and they should avoid fragmentation with PMTUD. If a device however recievs an bigger packet, they will send an ICMPv6 Type 2 Code 0 Message "Too Big" wich will transmit the MTU of the Server and will trigger fragmentation on the Client.
As you can see my Client is sending a packet with 1400bytes payload and the Servers responds with an "Too Big Message". My Client then fragments the icmp request but for reasons unknown to me, the Server does not respond to my then fragmented request and i get an error Message on my Client.
This however is fine, since opensene handles it correctly.
The BUG
If i ping the host ds.frankfurt.test-ipv6.com [2a01:7e01::f03c:94ff:fed0:4087] and the size of the ping is for example 2500bytes, sometimes it works and sometimes it does not. Actually most of the time it does not work and while I was writting this it suddenly started working. So first I was thinking that this is a clear cut case, but now i am very confused because of the sporadic nature of this bug and I would love some insight from someone that understands it better hopfully.
Here is an example of it Working:

And i can see in the Pcaps taken from WAN and LAN that the packet are the same on WAN and LAN, so ignoring the first ping getting lost, i can see no issue on the opensense side.
Pcap Download:
working_wan.zip
However most of the time, and reason for my report, ist that usually the packets on the WAN side, are getting malformed by opensense....
The first fragment, is missing 8 Bytes in the Payload:
LAN - 1448 bytes
WAN - 1440 bytes
This invalidates the icmpv6 checksum but most notably also adds a second ipv6 Fragmentation Header!

Pcap Download:
malformed_wan.zip
So either Opensense is not conform to the IPv6 specification and also tries to fragment the packet or there is some kind of error in the handling of this pakets.
To Reproduce
- start capture via Opensense GUI on WAN and LAN:
- run ping ds.frankfurt.test-ipv6.com -l 2500
If you get no response, you will most likely see in the WAN Pcap, that the packets are malformed.
Expected behavior
The packets on the WAN interface should not be malformed by opensene and opensense should not add a second ipv6 fragmentation header. This Ping should work all the time, nomatter the size specified.
Describe alternatives you considered
- It is not a driver / interface issue, since i can reproduce it on igc0 (Intel I225-V) and also on my ixl bond (Intel x-710)
-It is not a upstream ISP Router issue, since if the packet is malformed, it makes sense why it will drop the paket or can not handle the packet if there are multiple fragmentation headers
-Suricata and Traffic Shaping with FQ Codel seem to have no impact on this issue, the behaviour does not change if disabled or enabled
-The sporadic nature of this issue makes it hard to pinpoint.
Additional context
Previous Report: opnsense/core#8744
So this issue was hard for me to pinnpoint and I am no expert when it comes to ipv6, but something is clearly wrong here and I would appreciate it, if someone would test it on their end if it is reproducible. It did cost me alot of time to debug this because everything i looked at made no sense whatsoever or it started to work all of a sudden and then stopped again.
I really hope that someone here can reproduce it and find out why it is happening. I appreciate your time
Environment
Software version used and hardware type if relevant, e.g.:
Hardware: Minisofurm MS-01
i9-13900H + 32Gb ddr5
Intel x710
Intel I225-V
Bios Version
1.26
ISP Router: Fritzbox 7590
DSL Vectoring with PPPoe
Versions
OPNsense 25.1.7_4-amd64
FreeBSD 14.2-RELEASE-p3
OpenSSL 3.0.16



