Thread (6 messages) flat view 6 messages, 4 authors, 2018-09-18

Re: [PATCH v2 net] net/ipv4: defensive cipso option parsing

From: David Miller <davem@davemloft.net>
Date: 2018-09-18 02:38:48
Also in: stable

From: Stefan Nuernberger <redacted>
Date: Mon, 17 Sep 2018 19:46:53 +0200
commit 40413955ee26 ("Cipso: cipso_v4_optptr enter infinite loop") fixed
a possible infinite loop in the IP option parsing of CIPSO. The fix
assumes that ip_options_compile filtered out all zero length options and
that no other one-byte options beside IPOPT_END and IPOPT_NOOP exist.
While this assumption currently holds true, add explicit checks for zero
length and invalid length options to be safe for the future. Even though
ip_options_compile should have validated the options, the introduction of
new one-byte options can still confuse this code without the additional
checks.

Signed-off-by: Stefan Nuernberger <redacted>
Applied to net-next.

This is not 'net' nor -stable material.  I'm hesitent about this
change as-is, and ip_options_compile() is not changing semantics in
-stable in the way that you say can cause problems.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help