summaryrefslogtreecommitdiffstats
path: root/test/test_ipip.py
AgeCommit message (Expand)AuthorFilesLines
2021-01-07ipip: Support MPLS over IPNeale Ranns1-1/+149
2020-09-17teib: Add adj-fibs for peers/adjacencies on p2mp interfaceNeale Ranns1-2/+47
2020-02-21ipsec: IPSec protection for multi-point tunnel interfacesNeale Ranns1-4/+4
2020-02-04teib: Rename NHRP to TEIBNeale Ranns1-5/+5
2020-01-27ipip: Multi-point interfaceNeale Ranns1-0/+111
2020-01-27tunnel: Common types for IP tunnelsNeale Ranns1-16/+24
2019-12-03ipip: Tunnel flags controlling copying data to/from payload/encapNeale Ranns1-81/+539
2019-11-05misc: Fix python scripts shebang lineRenato Botelho do Couto1-1/+1
2019-11-05ip: Fragmentation fixesNeale Ranns1-4/+21
2019-06-18fib: fib api updatesNeale Ranns1-5/+5
2019-05-27IPIP tunnel: use address types on APINeale Ranns1-21/+25
2019-05-22stats: support multiple works for error countersOle Troan1-5/+5
2019-05-20reassembly: prevent long chain attackKlement Sekera1-0/+10
2019-04-10Tests Cleanup: Fix missing calls to setUpClass/tearDownClass.Paul Vinciguerra1-0/+8
2019-03-28Typos. A bunch of typos I've been collecting.Paul Vinciguerra1-1/+1
2019-03-06test framework: vpp_papi_provider.py - further cleanupOle Troan1-12/+12
2019-02-04VTL Cleanup: Fix missing calls to setUpClass/tearDownClass, fix numerous Type...Paul Vinciguerra1-0/+1
2018-12-10Test framework: StringIO fixes for Python3Ole Troan1-20/+6
2018-11-29Trivial: test/test_ipip.pyPaul Vinciguerra1-3/+3
2018-09-27IPIP and IPv6 fragmentationOle Troan1-19/+206
2018-09-17STATS: Dynamically mapped shared memory segmentOle Troan1-7/+9
2018-09-11GBP Endpoint UpdatesNeale Ranns1-1/+2
2018-09-02STATS: Python binding to access VPP statistics and counters.Ole Troan1-0/+10
2018-08-22IPIP and SIXRD tunnels create API needs table-IDs not fib-indexesNeale Ranns1-1/+13
2018-08-10IP fragmentation buffer chains, part 2.Ole Troan1-12/+54
2018-08-10IP fragmentation to handle buffer chains.Ole Troan1-0/+51
2018-05-25VPP-1277: IPIP - Copy TOS/TC from inner packet to outer.Ole Troan1-16/+19
2018-04-13Revert "MTU: Setting of MTU on software interface (instead of hardware interf...Damjan Marion1-64/+6
2018-04-13MTU: Setting of MTU on software interface (instead of hardware interface)Ole Troan1-6/+64
2018-03-15IPIP: Linter on test_*.pyOle Troan1-63/+30
2018-03-14IPIP: Add IP{v4,v6} over IP{v4,v6} configured tunnel support.Ole Troan1-0/+248
k">const dpo_id_t *dpo) { src->fes_pl = fib_path_list_create_special(proto, FIB_PATH_LIST_FLAG_DROP, drop_dpo_get(proto)); } static void fib_entry_src_mpls_set_data (fib_entry_src_t *src, const fib_entry_t *entry, const void *data) { fib_protocol_t payload_proto; fib_node_index_t fei; mpls_label_t label; mpls_eos_bit_t eos; /* * post MPLS table alloc and the possible rea-alloc of fib entrys * the entry pointer will no longer be valid. so save its index */ payload_proto = entry->fe_prefix.fp_proto; fei = fib_entry_get_index(entry); label = *(mpls_label_t*)data; if (MPLS_LABEL_INVALID == label) { /* * removing the local label */ FOR_EACH_MPLS_EOS_BIT(eos) { fib_table_entry_delete_index(src->mpls.fesm_lfes[eos], FIB_SOURCE_SPECIAL); } fib_table_unlock(MPLS_FIB_DEFAULT_TABLE_ID, FIB_PROTOCOL_MPLS); src->mpls.fesm_label = label; } else { fib_prefix_t prefix = { .fp_proto = FIB_PROTOCOL_MPLS, .fp_label = label, }; fib_node_index_t fib_index; dpo_id_t dpo = DPO_INVALID; /* * adding a new local label. make sure the MPLS fib exists. */ if (MPLS_LABEL_INVALID == src->mpls.fesm_label) { fib_index = fib_table_find_or_create_and_lock(FIB_PROTOCOL_MPLS, MPLS_FIB_DEFAULT_TABLE_ID); } else { fib_index = mpls_fib_index_from_table_id(MPLS_FIB_DEFAULT_TABLE_ID); /* * if this is a change in label, reomve the old one first */ if (src->mpls.fesm_label != label) { FOR_EACH_MPLS_EOS_BIT(eos) { ASSERT(FIB_NODE_INDEX_INVALID != src->mpls.fesm_lfes[eos]); fib_table_entry_delete_index(src->mpls.fesm_lfes[eos], FIB_SOURCE_SPECIAL); } } } src->mpls.fesm_label = label; FOR_EACH_MPLS_EOS_BIT(eos) { prefix.fp_eos = eos; prefix.fp_payload_proto = fib_proto_to_dpo(payload_proto); fib_entry_contribute_forwarding(fei, (eos ? FIB_FORW_CHAIN_TYPE_MPLS_EOS : FIB_FORW_CHAIN_TYPE_MPLS_NON_EOS), &dpo); src->mpls.fesm_lfes[eos] = fib_table_entry_special_dpo_add(fib_index, &prefix, FIB_SOURCE_SPECIAL, FIB_ENTRY_FLAG_EXCLUSIVE, &dpo); dpo_reset(&dpo); } } } static const void * fib_entry_src_mpls_get_data (fib_entry_src_t *src, const fib_entry_t *entry) { return (&(src->mpls.fesm_label)); } static u8* fib_entry_src_mpls_format (fib_entry_src_t *src, u8* s) { return (format(s, "MPLS local-label:%d", src->mpls.fesm_label)); } const static fib_entry_src_vft_t mpls_src_vft = { .fesv_init = fib_entry_src_mpls_init, .fesv_deinit = fib_entry_src_mpls_deinit, .fesv_add = fib_entry_src_mpls_add, .fesv_remove = fib_entry_src_mpls_remove, .fesv_format = fib_entry_src_mpls_format, .fesv_set_data = fib_entry_src_mpls_set_data, .fesv_get_data = fib_entry_src_mpls_get_data, /* * .fesv_fwd_update = fib_entry_src_mpls_fwd_update, * When the forwarding for the IP entry is updated, any MPLS chains * it has created are also updated. Since the MPLS entry will have already * installed that chain/load-balance there is no need to update the netry * FIXME: later: propagate any walk to the children of the MPLS entry. for SR */ }; void fib_entry_src_mpls_register (void) { fib_entry_src_register(FIB_SOURCE_MPLS, &mpls_src_vft); }