aboutsummaryrefslogtreecommitdiffstats
path: root/vnet/vnet/ip/ip6_neighbor.c
diff options
context:
space:
mode:
authorNeale Ranns <nranns@cisco.com>2016-10-07 15:14:33 +0100
committerDamjan Marion <dmarion.lists@gmail.com>2016-10-10 18:58:22 +0000
commit33a7dd5ad9a3d3ecd9bd8472ca20ee5f82ae9542 (patch)
tree039a067b44b25df78a3aa2d14d4dc558c79dc9d7 /vnet/vnet/ip/ip6_neighbor.c
parentbfe737a1b29afea2e10248b8c9fa800148fbd573 (diff)
FIB2.0: memory leaks during load-balance update (VPP-475)
some other fixes and enhancemets to address failures in the IPv6 Scale testing: - The rate at which VPP sends ARP/ND requests, 1 per-millisecond, is too high. This is reduced to 1 every 10 ms. probably still too high. - If an ARP/ND response is received that does not contain a change to the known MAC address, no further processing is done. - Added stats to get info about the async FIB walks. - When walking FIB entries and performing a load-balance update, it is not necessary to re-insert the LB in the forwarding table. Change-Id: Ifd47e4bdbce94495f44aaf1b78e7d1395ed870d1 Signed-off-by: Neale Ranns <nranns@cisco.com>
Diffstat (limited to 'vnet/vnet/ip/ip6_neighbor.c')
-rw-r--r--vnet/vnet/ip/ip6_neighbor.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/vnet/vnet/ip/ip6_neighbor.c b/vnet/vnet/ip/ip6_neighbor.c
index 57359f7adf3..fdec2d4a0f2 100644
--- a/vnet/vnet/ip/ip6_neighbor.c
+++ b/vnet/vnet/ip/ip6_neighbor.c
@@ -427,6 +427,17 @@ vnet_set_ip6_ethernet_neighbor (vlib_main_t * vm,
n->key = k;
n->adj_index = ADJ_INDEX_INVALID;
}
+ else
+ {
+ /*
+ * prevent a DoS attack from the data-plane that
+ * spams us with no-op updates to the MAC address
+ */
+ if (0 == memcmp(n->link_layer_address,
+ link_layer_address,
+ n_bytes_link_layer_address))
+ return -1;
+ }
/* Update time stamp and ethernet address. */
clib_memcpy (n->link_layer_address,