summaryrefslogtreecommitdiff
path: root/isisd/isis_tlvs.c
AgeCommit message (Collapse)Author
2025-04-11isisd: fix asla memory leakLouis Scalbert
> ==713776==ERROR: LeakSanitizer: detected memory leaks > > Direct leak of 120 byte(s) in 1 object(s) allocated from: > #0 0x7fdfcbeb4a57 in __interceptor_calloc ../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:154 > #1 0x7fdfcb86f8dd in qcalloc lib/memory.c:105 > #2 0x55ce707739b6 in isis_tlvs_find_alloc_asla isisd/isis_tlvs.c:8500 > #3 0x55ce7072fae0 in isis_link_params_update_asla isisd/isis_te.c:191 > #4 0x55ce70733881 in isis_link_params_update isisd/isis_te.c:499 > #5 0x55ce70693f2a in isis_circuit_up isisd/isis_circuit.c:776 > #6 0x55ce7069a120 in isis_csm_state_change isisd/isis_csm.c:135 > #7 0x55ce7068dd80 in isis_circuit_enable isisd/isis_circuit.c:79 > #8 0x55ce70699346 in isis_ifp_create isisd/isis_circuit.c:1618 > #9 0x7fdfcb81f47f in hook_call_if_real lib/if.c:55 > #10 0x7fdfcb82056e in if_new_via_zapi lib/if.c:188 > #11 0x7fdfcb9d17da in zclient_interface_add lib/zclient.c:2706 > #12 0x7fdfcb9df842 in zclient_read lib/zclient.c:4843 > #13 0x7fdfcb97798e in event_call lib/event.c:2011 > #14 0x7fdfcb842ff1 in frr_run lib/libfrr.c:1216 > #15 0x55ce7067cbf2 in main isisd/isis_main.c:360 > #16 0x7fdfcb229d8f in __libc_start_call_main ../sysdeps/nptl/libc_start_call_main.h:58 > > Indirect leak of 8 byte(s) in 1 object(s) allocated from: > #0 0x7fdfcbeb4a57 in __interceptor_calloc ../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:154 > #1 0x7fdfcb86f8dd in qcalloc lib/memory.c:105 > #2 0x7fdfcb79a7b7 in admin_group_init lib/admin_group.c:186 > #3 0x55ce707739ca in isis_tlvs_find_alloc_asla isisd/isis_tlvs.c:8501 > #4 0x55ce7072fae0 in isis_link_params_update_asla isisd/isis_te.c:191 > #5 0x55ce70733881 in isis_link_params_update isisd/isis_te.c:499 > #6 0x55ce70693f2a in isis_circuit_up isisd/isis_circuit.c:776 > #7 0x55ce7069a120 in isis_csm_state_change isisd/isis_csm.c:135 > #8 0x55ce7068dd80 in isis_circuit_enable isisd/isis_circuit.c:79 > #9 0x55ce70699346 in isis_ifp_create isisd/isis_circuit.c:1618 > #10 0x7fdfcb81f47f in hook_call_if_real lib/if.c:55 > #11 0x7fdfcb82056e in if_new_via_zapi lib/if.c:188 > #12 0x7fdfcb9d17da in zclient_interface_add lib/zclient.c:2706 > #13 0x7fdfcb9df842 in zclient_read lib/zclient.c:4843 > #14 0x7fdfcb97798e in event_call lib/event.c:2011 > #15 0x7fdfcb842ff1 in frr_run lib/libfrr.c:1216 > #16 0x55ce7067cbf2 in main isisd/isis_main.c:360 > #17 0x7fdfcb229d8f in __libc_start_call_main ../sysdeps/nptl/libc_start_call_main.h:58 PR: 95719 Fixes: 5749ac83a8 ("isisd: add ASLA support") Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2025-04-08isisd: clean up -Wshadow warningsMark Stapp
Clean up various "shadow" warnings. Signed-off-by: Mark Stapp <mjs@cisco.com>
2025-01-29isisd: fix erroneous srv6 information in databasePhilippe Guibert
The show isis database detail command dumps invalid srv6 information: > SRv6 Locator: fc00:0:6::/64 (Metric: 0) ipv6-unicast > Sub-TLVs: > SRv6 End SID Endpoint Behavior: unknown, SID value: fc00:0:6:0:1:: > > MT Reachability: 0123.6452.1973.03 (Metric: 10) ipv6-unicast > Local Interface IPv6 Address(es): 192::4:3 > SRv6 Lan End.X SID: fc00:0:3:0:43::, Algorithm: SPF, Weight: 0, Endpoint Behavior: End.DX6, Flags: B:0, S:0, P:0 Neighbor-ID: 0123.6452.1975 > SRv6 SID Structure Locator Block length: 40, Locator Node length: 24, Function length: 16, Argument length: 0, The behavior codepoint should use the IANA definitions to display the correct value. Fix this by calling the appropriate convert function. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
2024-11-12isisd: properly display srv6 algorithmDmytro Shytyi
When the segment-routing ipv6 is configured, the SPF algoritm shows S-SPF is used: > rt1# show isis segment-routing srv6 node > Area 1: > IS-IS L1 SRv6-Nodes: > > System ID Algorithm SRH Max SL SRH Max End Pop SRH Max H.encaps SRH Max End D > ----------------------------------------------------------------------------------------- > 0000.0000.0001 S-SPF 3 3 2 5 Actually, the segment-routing ipv6 algo capabilities (SPF) are rewritten. Don't rewrite the algo[0]. > rt1# show isis segment-routing srv6 node > Area 1: > IS-IS L1 SRv6-Nodes: > > System ID Algorithm SRH Max SL SRH Max End Pop SRH Max H.encaps SRH Max End D > ----------------------------------------------------------------------------------------- > 0000.0000.0001 SPF 3 3 2 5 Fixes: ("78774bbcd51b") isisd: add isis flex-algo lsp advertisement Signed-off-by: Dmytro Shytyi <dmytro.shytyi@6wind.com>
2024-09-19isisd: Remove deprecated JSON fieldsDonatas Abraitis
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2024-09-16isisd: fix rcap tlv double-free crashLouis Scalbert
A double-free crash happens when a subTLV of the "Router Capability" TLV is not readable and a previous "Router Capability" TLV was read. rcap was supposed to be freed later by isis_free_tlvs() -> free_tlv_router_cap(). In 78774bbcd5 ("isisd: add isis flex-algo lsp advertisement"), this was not the case because rcap was not saved to tlvs->router_cap when the function returned early because of a subTLV length issue. Always set tlvs->router_cap to free the memory. Note that this patch has the consequence that in case of subTLV error, the previously read "Router Capability" subTLVs are kept in memory. Fixes: 49efc80d34 ("isisd: Ensure rcap is freed in error case") Fixes: 78774bbcd5 ("isisd: add isis flex-algo lsp advertisement") Reported-by: Iggy Frankovic <iggyfran@amazon.com> Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2024-09-03isisd: fix crash when reading aslaLouis Scalbert
isisd is crashing when reading a ASLA sub-TLV with Application Identifier Bit Mask length greater than 1 octet. Set a limit of 8 bytes in accordance with RFC9479 and check that the received value does not exceed the limit. Reported-by: Iggy Frankovic <iggyfran@amazon.com> Link: https://www.rfc-editor.org/rfc/rfc9479.html#name-application-identifier-bit- Fixes: 5749ac83a8 ("isisd: add ASLA support") Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2024-06-24isisd: fix srv6 endx sid key nameLouis Scalbert
srv6EndSID is actually srv6EndXSID. Fixes: d5879267aa ("isisd: fix show database json format") Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2024-06-24isisd: fix neighbor id json keyLouis Scalbert
d5879267aa ("isisd: fix show database json format") renamed JSON keys to a standard format but forgot to rename the neighbor-id key. Fixes: d5879267aa ("isisd: fix show database json format") Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2024-06-24isisd: remane flags_json variableLouis Scalbert
The variable flags_json was incorrectly named, leading to confusion and causing the bug fixed in the previous commit. Rename the variable to refer to SRv6 End SID instead. Cosmetic change. Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2024-06-21isisd: fix display crash srv6 sid structure in jsonLouis Scalbert
Fix a crash when doing "show isis database detail json" in isis_srv6_topo1 topotest. > #0 raise (sig=<optimized out>) at ../sysdeps/unix/sysv/linux/raise.c:50 > #1 0x00007fad89524e2c in core_handler (signo=6, siginfo=0x7ffe86a4b8b0, context=0x7ffe86a4b780) at lib/sigevent.c:258 > #2 <signal handler called> > #3 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50 > #4 0x00007fad8904e537 in __GI_abort () at abort.c:79 > #5 0x00007fad8904e40f in __assert_fail_base (fmt=0x7fad891c5688 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x7fad8a3e70e8 "json_object_get_type(jso) == json_type_object", > file=0x7fad8a3e7064 "./json_object.c", line=590, function=<optimized out>) at assert.c:92 > #6 0x00007fad8905d662 in __GI___assert_fail (assertion=0x7fad8a3e70e8 "json_object_get_type(jso) == json_type_object", file=0x7fad8a3e7064 "./json_object.c", line=590, > function=0x7fad8a3e7440 "json_object_object_add_ex") at assert.c:101 > #7 0x00007fad8a3dfe93 in json_object_object_add_ex () from /lib/x86_64-linux-gnu/libjson-c.so.5 > #8 0x000055708e3f8f7f in format_subsubtlv_srv6_sid_structure (sid_struct=0x602000172b70, buf=0x0, json=0x6040000a21d0, indent=6) at isisd/isis_tlvs.c:2880 > #9 0x000055708e3f9acb in isis_format_subsubtlvs (subsubtlvs=0x602000172b50, buf=0x0, json=0x6040000a21d0, indent=6) at isisd/isis_tlvs.c:3022 > #10 0x000055708e3eefb0 in format_item_ext_subtlvs (exts=0x614000047440, buf=0x0, json=0x6040000a2190, indent=2, mtid=2) at isisd/isis_tlvs.c:1313 > #11 0x000055708e3fd599 in format_item_extended_reach (mtid=2, i=0x60300015aed0, buf=0x0, json=0x6040000a1bd0, indent=0) at isisd/isis_tlvs.c:3763 > #12 0x000055708e40d46a in format_item (mtid=2, context=ISIS_CONTEXT_LSP, type=ISIS_TLV_MT_REACH, i=0x60300015aed0, buf=0x0, json=0x6040000a1bd0, indent=0) at isisd/isis_tlvs.c:6789 > #13 0x000055708e40d4fc in format_items_ (mtid=2, context=ISIS_CONTEXT_LSP, type=ISIS_TLV_MT_REACH, items=0x60600021d160, buf=0x0, json=0x6040000a1bd0, indent=0) at isisd/isis_tlvs.c:6804 > #14 0x000055708e40edbc in format_mt_items (context=ISIS_CONTEXT_LSP, type=ISIS_TLV_MT_REACH, m=0x6180000845d8, buf=0x0, json=0x6040000a1bd0, indent=0) at isisd/isis_tlvs.c:7147 > #15 0x000055708e4111e9 in format_tlvs (tlvs=0x618000084480, buf=0x0, json=0x6040000a1bd0, indent=0) at isisd/isis_tlvs.c:7572 > #16 0x000055708e4114ce in isis_format_tlvs (tlvs=0x618000084480, json=0x6040000a1bd0) at isisd/isis_tlvs.c:7613 > #17 0x000055708e36f167 in lsp_print_detail (lsp=0x612000058b40, vty=0x0, json=0x6040000a1bd0, dynhost=1 '\001', isis=0x60d00001f800) at isisd/isis_lsp.c:785 > #18 0x000055708e36f31f in lsp_print_all (vty=0x0, json=0x6040000a0490, head=0x61f000005488, detail=1 '\001', dynhost=1 '\001', isis=0x60d00001f800) at isisd/isis_lsp.c:820 > #19 0x000055708e4379fc in show_isis_database_lspdb_json (json=0x6040000a0450, area=0x61f000005480, level=0, lspdb=0x61f000005488, sysid_str=0x0, ui_level=1) at isisd/isisd.c:2683 > #20 0x000055708e437ef9 in show_isis_database_json (json=0x6040000a0310, sysid_str=0x0, ui_level=1, isis=0x60d00001f800) at isisd/isisd.c:2754 > #21 0x000055708e438357 in show_isis_database_common (vty=0x62e000060400, json=0x6040000a0310, sysid_str=0x0, ui_level=1, isis=0x60d00001f800) at isisd/isisd.c:2788 > #22 0x000055708e438591 in show_isis_database (vty=0x62e000060400, json=0x6040000a0310, sysid_str=0x0, ui_level=1, vrf_name=0x7fad89806300 <vrf_default_name> "default", all_vrf=false) > at isisd/isisd.c:2825 > #23 0x000055708e43891d in show_database (self=0x55708e5519c0 <show_database_cmd>, vty=0x62e000060400, argc=5, argv=0x6040000a02d0) at isisd/isisd.c:2855 > #24 0x00007fad893a9767 in cmd_execute_command_real (vline=0x60300015f220, vty=0x62e000060400, cmd=0x0, up_level=0) at lib/command.c:1002 > #25 0x00007fad893a9adc in cmd_execute_command (vline=0x60300015f220, vty=0x62e000060400, cmd=0x0, vtysh=0) at lib/command.c:1061 > #26 0x00007fad893aa728 in cmd_execute (vty=0x62e000060400, cmd=0x621000025900 "show isis database detail json ", matched=0x0, vtysh=0) at lib/command.c:1227 Note that prior to 2e670cd779, there was no crash but only the last "srv6-sid-structure" was displayed. A "srv6-sid-structure" should be displayed for each "sid". This commit also fix this. Was: > "srv6-lan-endx-sid": [ > { > "sid": "fc00:0:1:1::", > "weight": 0, > "algorithm": "SPF", > "neighbor-id": "0000.0000.0002" > }, > { > "sid": "fc00:0:1:2::", > "weight": 0, > "algorithm": "SPF", > "neighbor-id": "0000.0000.0003" > } > ], > "srv6-sid-structure": { > "loc-block-len": 32, > "loc-node-len": 16, > "func-len": 16, > "arg-len": 0 > }, Now (srv6-sid-structure are identical but they are not always): > "srv6-lan-endx-sid": [ > { > "sid": "fc00:0:1:1::", > "algorithm": "SPF", > "neighbor-id": "0000.0000.0002", > "srv6-sid-structure": { > "loc-block-len": 32, > "loc-node-len": 16, > "func-len": 8, > "arg-len": 0 > }, > }, > { > "sid": "fc00:0:1:2::", > "algorithm": "SPF", > "neighbor-id": "0000.0000.0003", > "srv6-sid-structure": { > "loc-block-len": 32, > "loc-node-len": 16, > "func-len": 16, > "arg-len": 0 > }, > } > ], Fixes: 2e670cd779 ("isisd: fix display of srv6 subsubtlvs") Fixes: 648a158802 ("isisd: Add SRv6 End.X SID to Sub-TLV format func") Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2024-05-23isisd: fix crash when displaying asla in jsonLouis Scalbert
Fix crash when displaying ASLAs (Application Specific Link-Attributes) with JSON Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2024-05-23isisd: add json display of extended admin groupsLouis Scalbert
Add JSON display of extended admin groups Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2024-05-23isisd: fix show database json formatLouis Scalbert
"show isis database [detail] json" returns invalid or incorrect JSON that is difficult to parse. Fix key with '-' characters, add booleans and null data when possible. Deprecate the old format. Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2024-05-23isisd: fix display of srv6 subsubtlvsLouis Scalbert
Fix display of srv6 subsubtlvs Fixes: 648a158802 ("isisd: Add SRv6 End.X SID to Sub-TLV format func") Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2024-05-23isisd: display MT name in show isis database detail jsonLouis Scalbert
Only the MT ID is displayed. Display the MT description as well. Fixes: a2cac12a63 ("isisd: Add json to show isis database command.") Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2024-05-23isisd: fix keys display in show isis database detail jsonLouis Scalbert
Some keys are wrongly displayed at the JSON parent level. Add the key at the current level. Fixes: a2cac12a63 ("isisd: Add json to show isis database command.") Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2024-05-23isisd: fix multiple values display in show isis database detail jsonLouis Scalbert
Multiple occurrences of the same (sub-)TLVs are mixed into a single JSON object. Last values replaces the previous. Display all the occurrences in an array for the following (sub-)TLVs: - is-reach - ip-reach - ext-reach - ext-ip-reach - ipv6-reach - MT - prefix-SID Fixes: a2cac12a63 ("isisd: Add json to show isis database command.") Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2024-04-02isisd: fix ip/ipv6 reachability tlvsIgor Ryzhov
Don't allocate subtlvs container if there's nothing to add to it. If the container is allocated, the "sub-TLVs presence" bit is set in the TLVs even if there's no actual sub-TLVs, what violates the RFC. Fixes #14514. Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
2024-01-04*: Remove Crypto openSSL define from zebra.hDonald Sharp
Only a couple of places use this. Move these to a better spot. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-09-15isisd: Fix CID 1568129 (Null pointer dereference)Carmine Scarpitta
Fix this coverity issue: *** CID 1568129: Null pointer dereferences (REVERSE_INULL) /isisd/isis_tlvs.c: 2813 in unpack_item_srv6_end_sid() 2807 sid->subsubtlvs = NULL; 2808 } 2809 2810 append_item(&subtlvs->srv6_end_sids, (struct isis_item *)sid); 2811 return 0; 2812 out: >>> CID 1568129: Null pointer dereferences (REVERSE_INULL) >>> Null-checking "sid" suggests that it may be null, but it has already been dereferenced on all paths leading to the check. 2813 if (sid) 2814 free_item_srv6_end_sid((struct isis_item *)sid); 2815 return 1; 2816 } 2817 2818 /* Functions related to TLVs 1 Area Addresses */ Signed-off-by: Carmine Scarpitta <cscarpit@cisco.com>
2023-09-11isisd: Add support for SRv6 Adjacency SIDsCarmine Scarpitta
An SRv6 adjacency SID is a SID that is associated with a particular adjacency. Adjacency SIDs are advertised using the SRv6 End.X SID Sub-TLV (RFC 9352 section #8.1) or SRv6 LAN End.X SID Sub-TLV (RFC 9352 section #8.2). This commit defines the following Adj SIDs management functions: * srv6_endx_sid_add_single: add a new SRv6 Adjacency SID * srv6_endx_sid_del: delete an SRv6 Adjacency SID * isis_srv6_endx_sid_find: lookup SRv6 End.X SID by type It also attaches some callbacks to the hooks isis_adj_state_change_hook, isis_adj_ip_enabled_hook, isis_adj_ip_disabled_hook, which are responsible for installing/removing an SRv6 Adjacency SID automatically when the state of an IS-IS adjacency changes. Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Make MTYPE_ISIS_SUBSUBTLV non-staticCarmine Scarpitta
We need to allocate memory SRv6 SID Structure Sub-Sub-TLV in isis_srv6.c. MTYPE_ISIS_SUBSUBTLV is statically defined in isis_tlvs.c and therefore is not visible in isis_srv6.c. Let's make MTYPE_ISIS_SUBSUBTLV non-static to provide visibility to the external world.. Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Unpack SRv6 (LAN) End.X SID Sub-TLVCarmine Scarpitta
Extend the Extended IS Reachability TLV unpack function to unpack the SRv6 End.X SID Sub-TLV and SRv6 LAN End.X SID Sub-TLV, if present. Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Pack SRv6 (LAN) End.X SID Sub-TLVCarmine Scarpitta
Extend the Extended IS Reachability TLV pack function to pack the SRv6 End.X SID Sub-TLV and SRv6 LAN End.X SID Sub-TLV, if present. Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Add SRv6 End.X SID to Sub-TLV format funcCarmine Scarpitta
Extend the Extended IS Reachability TLV format function to show the SRv6 End.X SID Sub-TLV and SRv6 LAN End.X SID Sub-TLV, if present. Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Add SRv6 End.X SID to Sub-TLV copy funcCarmine Scarpitta
Extend the Extended IS Reachability TLV copy function to copy the SRv6 End.X SID Sub-TLV and SRv6 LAN End.X SID Sub-TLV, if present. Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Add SRv6 End.X SID to IS ext reach Sub-TLVsCarmine Scarpitta
Add SRv6 End.X SID Sub-TLV and SRv6 LAN End.X SID Sub-TLV to the Extended IS Reachability Sub-TLVs data structure and perform proper initialization/free when the Sub-TLVs data structure is allocated/destroyed. Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Update copyright info in isis_tlvs.[c,h]Carmine Scarpitta
Add copyright claim for "IS-IS Extensions to Support SRv6" (RFC 9352) to isis_tlvs.c and isis_tlvs.h. Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Add structure when building End SID Sub-TLVCarmine Scarpitta
Encode SRv6 SID Structure Sub-Sub-TLV when building the SRv6 End SID Sub-TLV. Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Add func to build Sub-Sub-TLV from End SIDCarmine Scarpitta
Add a function to build an SRv6 SID Structure Sub-Sub-TLV (RFC 9352 section #9) to advertise the structure of a specific SRv6 End SID passed as an argument. Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Add End SID when building SRv6 Locator TLVCarmine Scarpitta
Encode SRv6 End SID Sub-TLVs when building the SRv6 Locator TLV. Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Add func to build Sub-TLV from SRv6 End SIDCarmine Scarpitta
Add a function to build an SRv6 End SID TLV (RFC 9352 section #7.2) to advertise a specific SRv6 End SID passed as an argument. Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Add function to build TLV from SRv6 LocatorCarmine Scarpitta
Add a function to build an SRv6 Locator TLV (RFC 9352 section #7.1) to advertise a specific SRv6 Locator passed as an argument. Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Bind SRv6 SID Struct ops to TLV typeCarmine Scarpitta
General Sub-Sub-TLV processing functions (i.e., copy, format, free, pack, and unpack) perform a lookup of the handler specific for a Sub-Sub-TLV in the `tlv_table`, and then call the specific handler to process the Sub-Sub-TLV. This commit adds the handlers for the SRv6 Structure Sub-Sub-TLV (stored in `subsubtlv_srv6_sid_structure_ops`) to the `tlv_table`. Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Define TLV ops for SID Struct Sub-Sub-TLVCarmine Scarpitta
Use the SUBSUBTLV_OPS macro to define the TLV operations for the SRv6 SID Structure Sub-Sub-TLV (RFC 9352 section #9). Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Add unpack func for SID Struct Sub-Sub-TLVCarmine Scarpitta
Add a function to unpack an SRv6 SID Structure Sub-Sub-TLV (RFC 9352 section #9). Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Pack SID Struct when packing Sub-Sub-TLVsCarmine Scarpitta
Extend generic Sub-Sub-TLVs pack function to pack SRv6 SID Structure Sub-Sub-TLVs (RFC 9352 section FRRouting#9). Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Add pack func for SID Structure Sub-Sub-TLVCarmine Scarpitta
Add a function to pack an SRv6 SID Structure Sub-Sub-TLV (RFC 9352 section #9). Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Free SID Struct when freeing Sub-Sub-TLVsCarmine Scarpitta
Extend generic Sub-Sub-TLVs free function to free SRv6 SID Structure Sub-Sub-TLVs (RFC 9352 section #9). Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Add free func for SID Structure Sub-Sub-TLVCarmine Scarpitta
Add a function to free an SRv6 SID Structure Sub-Sub-TLV (RFC 9352 section #9). Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Add SID Struct to Sub-Sub-TLVs format funcCarmine Scarpitta
Extend generic Sub-Sub-TLVs format function to return information about SRv6 SID Structure Sub-Sub-TLVs (RFC 9352 section #9). Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Add format func for SID Struct Sub-Sub-TLVCarmine Scarpitta
Add a function to return information about an SRv6 SID Structure Sub-Sub-TLV (RFC 9352 section #9). Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Copy SID Struct when copying Sub-Sub-TLVsCarmine Scarpitta
Extend generic Sub-Sub-TLVs copy function to copy SRv6 SID Structure Sub-Sub-TLVs (RFC 9352 section #9). Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Add copy func for SID Structure Sub-Sub-TLVCarmine Scarpitta
Add a function to copy an SRv6 SID Structure Sub-Sub-TLV (RFC 9352 section #9). Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Unpack Sub-Sub-TLVs of SRv6 End SID Sub-TLVCarmine Scarpitta
Extend SRv6 End SID Sub-TLV unpack function to unpack Sub-Sub-TLVs (RFC 9352 section #9). Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Pack Sub-Sub-TLVs of SRv6 End SID Sub-TLVCarmine Scarpitta
Extend SRv6 End SID Sub-TLV pack function to pack Sub-Sub-TLVs (RFC 9352 section #9). Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Free Sub-Sub-TLVs of SRv6 End SID Sub-TLVCarmine Scarpitta
Extend SRv6 End SID Sub-TLV free function to free Sub-Sub-TLVs (RFC 9352 section #9). Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Add Sub-Sub-TLVs to End SID format funcCarmine Scarpitta
Extend SRv6 End SID Sub-TLV format function to return information about Sub-Sub-TLVs (RFC 9352 section #7.2). Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11isisd: Copy Sub-Sub-TLVs of SRv6 End SID Sub-TLVCarmine Scarpitta
Extend SRv6 End SID Sub-TLV copy function to copy Sub-Sub-TLVs (RFC 9352 section #7.2). Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>