]> git.puffer.fish Git - mirror/frr.git/commit
bgpd: Fix error handling when receiving BGP Prefix SID attribute
authorDonatas Abraitis <donatas@opensourcerouting.org>
Wed, 27 Mar 2024 16:42:56 +0000 (18:42 +0200)
committerMergify <37929162+mergify[bot]@users.noreply.github.com>
Tue, 2 Apr 2024 15:19:03 +0000 (15:19 +0000)
commit0486f4f04dd1338dbfb5fb1cb4ae09d4be8f11ae
tree3ee0409824b3761e789f30458d2fe92106260567
parent9772b2c585e7d1e76fa4f970f1328e9efc4f4eea
bgpd: Fix error handling when receiving BGP Prefix SID attribute

Without this patch, we always set the BGP Prefix SID attribute flag without
checking if it's malformed or not. RFC8669 says that this attribute MUST be discarded.

Also, this fixes the bgpd crash when a malformed Prefix SID attribute is received,
with malformed transitive flags and/or TLVs.

Reported-by: Iggy Frankovic <iggyfran@amazon.com>
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
(cherry picked from commit ba6a8f1a31e1a88df2de69ea46068e8bd9b97138)
bgpd/bgp_attr.c