]> The Tcpdump Group git mirrors - tcpdump/commit
BGP: Fix parsing the AIGP attribute
authorFrancois-Xavier Le Bail <[email protected]>
Wed, 9 Feb 2022 13:01:40 +0000 (14:01 +0100)
committerFrancois-Xavier Le Bail <[email protected]>
Wed, 9 Feb 2022 13:34:17 +0000 (14:34 +0100)
commitd1e77f9887bf21eecdbbd14b5c1a7d16ec12ce58
tree29d9ccb71db0840cc915a638893cb86b05c96703
parent255f852f5ab5314c144aa0287296487f3e36ba44
BGP: Fix parsing the AIGP attribute

There was an invalid ND_TCHECK_LEN(), thus the AIGP metric attribute
at the end of an update message was incorrectly shown as truncated.

Remove it because the data fetching is secured by GET_BE_U_8 and
print_unknown_data.

Add a test file with AIGP attribute at the end of an update message.

This should fix GitHub issue #975.

Remark:
This code need more updates on length checks to change some 'truncated'
process to 'invalid' process.

(cherry picked from commit 255c1cbcf3300216bcd23a0df63493ae37e6d70f)
print-bgp.c
tests/TESTLIST
tests/bgp-aigp-2.out [new file with mode: 0644]
tests/bgp-aigp-2.pcap [new file with mode: 0644]