]> git.ipfire.org Git - thirdparty/iproute2.git/commit
macsec: fix off-by-one when parsing attributes
authorSabrina Dubroca <sd@queasysnail.net>
Fri, 12 Oct 2018 15:34:12 +0000 (17:34 +0200)
committerStephen Hemminger <stephen@networkplumber.org>
Mon, 15 Oct 2018 16:35:48 +0000 (09:35 -0700)
commit9b45f8ec13b0d338c70ef0758f751c249be6c7f0
tree6c5a24544e03500e6bb1658ad49a292bf389848c
parent45ec4771d40cb367377e4148a2af22f25c20f3bf
macsec: fix off-by-one when parsing attributes

I seem to have had a massive brainfart with uses of
parse_rtattr_nested(). The rtattr* array must have MAX+1 elements, and
the call to parse_rtattr_nested must have MAX as its bound. Let's fix
those.

Fixes: b26fc590ce62 ("ip: add MACsec support")
Signed-off-by: Sabrina Dubroca <sd@queasysnail.net>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
ip/ipmacsec.c