]> git.puffer.fish Git - mirror/frr.git/commit
bgpd: Limit processing to what is needed in rpki validation
authorDonald Sharp <sharpd@nvidia.com>
Sun, 15 Aug 2021 14:15:38 +0000 (10:15 -0400)
committerDonald Sharp <sharpd@nvidia.com>
Mon, 16 Aug 2021 15:04:06 +0000 (11:04 -0400)
commit35a1e798f8bacf1bcfec7cfabe7c05432323ca23
tree898c9e03724205287a3432162564529c33336a25
parentc5be0ad63176bad076d29342c9538eeb902e1cb5
bgpd: Limit processing to what is needed in rpki validation

The processing was looping over all bgp instances then
over all peers then over all safi's to find a match
for a prefix received in order to validate it.

Suppose you have 100 peers each sending you the same
prefix.  This code will cause it to look at each node 100
times since we look at for each peer.  This is especially
egregarious because we never ever do anything with the peer
when we are looping over them.

Remove the peer loop, significantly reduce processing.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
bgpd/bgp_rpki.c