android_kernel_motorola_sm6375/include
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Maciej Żenczykowski 2ecac8d06b net/ipv4: always honour route mtu during forwarding
Documentation/networking/ip-sysctl.txt:46 says:
  ip_forward_use_pmtu - BOOLEAN
    By default we don't trust protocol path MTUs while forwarding
    because they could be easily forged and can lead to unwanted
    fragmentation by the router.
    You only need to enable this if you have user-space software
    which tries to discover path mtus by itself and depends on the
    kernel honoring this information. This is normally not the case.
    Default: 0 (disabled)
    Possible values:
    0 - disabled
    1 - enabled

Which makes it pretty clear that setting it to 1 is a potential
security/safety/DoS issue, and yet it is entirely reasonable to want
forwarded traffic to honour explicitly administrator configured
route mtus (instead of defaulting to device mtu).

Indeed, I can't think of a single reason why you wouldn't want to.
Since you configured a route mtu you probably know better...

It is pretty common to have a higher device mtu to allow receiving
large (jumbo) frames, while having some routes via that interface
(potentially including the default route to the internet) specify
a lower mtu.

Note that ipv6 forwarding uses device mtu unless the route is locked
(in which case it will use the route mtu).

This approach is not usable for IPv4 where an 'mtu lock' on a route
also has the side effect of disabling TCP path mtu discovery via
disabling the IPv4 DF (don't frag) bit on all outgoing frames.

I'm not aware of a way to lock a route from an IPv6 RA, so that also
potentially seems wrong.

Signed-off-by: Maciej Żenczykowski <[email protected]>
Cc: Eric Dumazet <[email protected]>
Cc: Willem de Bruijn <[email protected]>
Cc: Lorenzo Colitti <[email protected]>
Cc: Sunmeet Gill (Sunny) <[email protected]>
Cc: Vinay Paradkar <[email protected]>
Cc: Tyler Wear <[email protected]>
Cc: David Ahern <[email protected]>
Reviewed-by: Eric Dumazet <[email protected]>
(Backported from commit 02a1b175b0e92d9e0fa5df3957ade8d733ceb6a0).

Change-Id: I26f336f891711f0149b2835d2c4a78fc8407b5ba
Git-Commit: 02a1b175b0e92d9e0fa5df3957ade8d733ceb6a0
Git-repo: https://kernel.googlesource.com/pub/scm/linux/kernel/git/stable/linux
Signed-off-by: Sauvik Saha <[email protected]>
2020-10-14 22:18:21 +05:30
..
acpi
asm-generic This is the 5.4.59 stable release 2020-08-19 08:40:57 +02:00
clocksource
crypto Merge android11-5.4.60 (8ae87ad) into msm-5.4 2020-08-31 13:04:44 -07:00
drm ANDROID: include/linux: add low power mode and fps to notifier 2020-08-12 15:43:27 +00:00
dt-bindings Merge "dt-bindings: thermal: Add support for modem skin sensor via QMI" 2020-10-01 13:35:01 -07:00
keys
kvm
linux Merge "dwc3-msm: Map IPA GSI channel doorbell register for different UDC core" 2020-10-03 04:38:40 -07:00
math-emu
media media: v4l2-core: remove the unused code 2020-09-11 12:30:05 +05:30
misc
net net/ipv4: always honour route mtu during forwarding 2020-10-14 22:18:21 +05:30
pcmcia
ras
rdma
scsi
soc soc: qcom: Add a die notifier for qcom watchdog 2020-09-18 12:23:57 +05:30
sound Merge android11-5.4.58 (3a9b53b) into msm-5.4 2020-08-28 10:11:12 -07:00
target
trace Merge android11-5.4.61+ (e32adae) into msm-5.4 2020-09-28 11:25:52 -07:00
uapi Support full CONE NAT and ADDRESS RESTRICTED CONE NAT 2020-09-25 21:26:24 +05:30
vdso
video
xen