Project

General

Profile

Actions

Bug #14396

closed

Reassembled packets received on a VTI are not forwarded

Added by Christopher de Haas over 1 year ago. Updated over 1 year ago.

Status:
Resolved
Priority:
Normal
Category:
IPsec
Target version:
Start date:
Due date:
% Done:

100%

Estimated time:
Plus Target Version:
23.05.1
Release Notes:
Default
Affected Version:
Affected Architecture:
All

Description

Larger than MTU backets, which require fragmentation, cannot be routed on an IPsec VTI interface. Here is an example trace:

Incoming over VTI interface:

15:34:41.576981 AF IPv4 (2), length 1400: (tos 0x0, ttl 127, id 62903, offset 0, flags [+], proto ICMP (1), length 1396)
172.20.130.53 > 172.20.140.100: ICMP echo request, id 1, seq 464, length 1376
15:34:41.577000 AF IPv4 (2), length 656: (tos 0x0, ttl 127, id 62903, offset 1376, flags [none], proto ICMP (1), length 652)
172.20.130.53 > 172.20.140.100: ip-proto-1

Outgoing on LAN interface:

15:35:52.961652 1a:cb:63:20:dd:3f > 00:50:56:9a:dd:a2, ethertype IPv4 (0x0800), length 2042: (tos 0x0, ttl 126, id 62905, offset 0, flags [none], proto ICMP (1), length 2028)
172.20.130.53 > 172.20.140.100: ICMP echo request, id 1, seq 466, length 2008

It looks like fragmentation is applied correctly over the tunnel, but it is forwarded to the client on the LAN interface without fragmenting.

I found this bug from 2017, which seems to be related: https://redmine.pfsense.org/issues/7801. Unfortunately the pull request references no longer work, thus I cannot find the exact changes.

I have tried all combinations for the System / Advanced / Firewall & NAT / VPN Packet Processing / Reassemble IP Fragments until they form a complete packet, but it does not have any effect on the issue. I seems like something is wrong specifically when using a VTI interface.

I think it is related to the default scrub rule with fragment reassemble as indicated here https://forum.netgate.com/topic/26822/allow-fragments-in-rules.

So, I have now tried, in a lab, to disable Firewall Scrub in System / Advanced / Firewall & NAT. With this, packets which require fragmentation are now working correctly over the VTI link.

However, I do not really want to disable pf scrub entirely, I do not consider this a work-around. I am also a bit unsure whether this will break a lot of over parts of the network.

As this breaks all UDP traffic which requires fragmentation, the impact of this bug is high. A common scenario would be RADIUS for 802.1x over a VTI link completely breaks.


Files

clipboard-202306111050-2kw7z.png (55.1 KB) clipboard-202306111050-2kw7z.png Christopher de Haas, 06/11/2023 08:50 AM
Actions

Also available in: Atom PDF