]> git.puffer.fish Git - matthieu/frr.git/commit
bgpd: Fix session reset issue caused by malformed core attributes
authorSamanvitha B Bhargav <bsamanvitha@vmware.com>
Wed, 2 Aug 2023 06:10:35 +0000 (23:10 -0700)
committerSamanvitha B Bhargav <bsamanvitha@vmware.com>
Wed, 2 Aug 2023 06:17:19 +0000 (23:17 -0700)
commit70ff940fd1cbf920958116c558150ca5d3200eb8
tree3eecc6226025982c3a3d3b8d6454b6d0b8ca2b50
parentea59d5e08d511d950f3d23742d105cbea383b0ea
bgpd: Fix session reset issue caused by malformed core attributes

RCA:
On encountering any attribute error for core attributes in update message,
the error handling is set to 'treat as withdraw' and
further parsing of the remaining attributes is skipped.
But the stream pointer is not being correctly adjusted to
point to the next NLRI field skipping the rest of the attributes.
This leads to incorrect parsing of the NLRI field,
which causes BGP session to reset.

Fix:
The stream pointer offset is rightly adjusted to point to the NLRI field correctly
when the malformed attribute is encountered and remaining attribute parsing is skipped.

Signed-off-by: Samanvitha B Bhargav <bsamanvitha@vmware.com>
bgpd/bgp_attr.c