]> The Tcpdump Group git mirrors - tcpdump/commit
(for 4.9.3) CVE-2018-16230/BGP: fix decoding of MP_REACH_NLRI
authorDenis Ovsienko <[email protected]>
Thu, 23 Aug 2018 21:09:16 +0000 (22:09 +0100)
committerFrancois-Xavier Le Bail <[email protected]>
Tue, 27 Aug 2019 09:20:42 +0000 (11:20 +0200)
commit13d52e9c0e7caf7e6325b0051bc90a49968be67f
tree460c573dcf5543fce54b371e66200dd32a9fc151
parent9a6eb27650463ad65dc75d1bfc972a0d0ad673ae
(for 4.9.3) CVE-2018-16230/BGP: fix decoding of MP_REACH_NLRI

When bgp_attr_print() tried to decode the variable-length nexthop value
for the NSAP VPN case, it did not check that the declared length is good
to interpret the value as a mapped IPv4 or IPv6 address. Add missing
checks to make this safe.

This fixes a buffer over-read discovered by Include Security working
under the Mozilla SOS program in 2018 by means of code audit.

Bhargava Shastry, SecT/TU Berlin, had independently identified this
vulnerability by means of fuzzing and provided the packet capture file
for the test.
print-bgp.c
tests/TESTLIST
tests/bgp_mp_reach_nlri-oobr.out [new file with mode: 0644]
tests/bgp_mp_reach_nlri-oobr.pcap [new file with mode: 0644]