From b8ab896c0a3c0ee3459e16178f4192d1f0be2d36 Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Tue, 4 Jun 2019 21:15:43 -0400 Subject: [PATCH] isisd: The RFC states that v6 addresses are limited to 16 in a hello packet The RFC states we can send only up to 16 v6 addresses in a hello packet and cannot send sub tlv's of that type. Signed-off-by: Donald Sharp --- isisd/isis_tlvs.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/isisd/isis_tlvs.c b/isisd/isis_tlvs.c index a433fcdb41..9de2ed35ea 100644 --- a/isisd/isis_tlvs.c +++ b/isisd/isis_tlvs.c @@ -2828,13 +2828,18 @@ void isis_tlvs_add_ipv6_addresses(struct isis_tlvs *tlvs, { struct listnode *node; struct prefix_ipv6 *ip_addr; + unsigned int addr_count = 0; for (ALL_LIST_ELEMENTS_RO(addresses, node, ip_addr)) { + if (addr_count >= 15) + break; + struct isis_ipv6_address *a = XCALLOC(MTYPE_ISIS_TLV, sizeof(*a)); a->addr = ip_addr->prefix; append_item(&tlvs->ipv6_address, (struct isis_item *)a); + addr_count++; } } -- 2.39.5