Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9277207d authored by Ashwanth Goli's avatar Ashwanth Goli Committed by Gerrit - the friendly Code Review server
Browse files

ipv6: remove min MTU check for ipsec tunnels



With 749439bfac ipsec dst's that report a MTU less than
IPV6_MIN_MTU are broken even for packets that are smaller
than IPV6_MIN_MTU.

According to rfc2473#section-7.1

    if the original IPv6 packet is equal or  smaller  than  the
    IPv6 minimum link MTU, the tunnel entry-point node
    encapsulates the original packet, and subsequently
    fragments the resulting IPv6 tunnel packet into IPv6
    fragments that do not exceed the Path MTU to the tunnel
    exit-point.

This patch drops the MTU check for ipsec tunnel destinations.

Change-Id: I36152ec99a955e20ded707fd7269ba11b94a9cfc
Signed-off-by: default avatarAshwanth Goli <ashwanth@codeaurora.org>
Signed-off-by: default avatarChinmay Agarwal <chinagar@codeaurora.org>
parent 88d29d2a
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1226,7 +1226,7 @@ static int ip6_setup_cork(struct sock *sk, struct inet_cork_full *cork,
		if (np->frag_size)
			mtu = np->frag_size;
	}
	if (mtu < IPV6_MIN_MTU)
	if (!(rt->dst.flags & DST_XFRM_TUNNEL) && mtu < IPV6_MIN_MTU)
		return -EINVAL;
	cork->base.fragsize = mtu;
	cork->base.gso_size = sk->sk_type == SOCK_DGRAM &&