summaryrefslogtreecommitdiffstats
path: root/src
AgeCommit message (Expand)AuthorFilesLines
2021-08-30tls: use default OpenSSL built-in DH parametersOfer Heifetz1-0/+8
2021-08-30tcp: Allow accepting session to send custom packetliuyacan1-1/+9
2021-08-27vppinfra: add compress functions for u64, u16 and u8Mohsin Kazmi3-4/+352
2021-08-27vlib: vpp banner is outputted to non-interactive vppctl sessionSteven Luong1-0/+11
2021-08-27snort: fix incorrect data length for snort inspectionSivaprasad Tummala1-0/+1
2021-08-27bufmon: add buffer monitoring pluginBenoît Ganne7-24/+417
2021-08-27snort: fix snort hang issue when interruptedSivaprasad Tummala1-1/+20
2021-08-26vhost: migrate to new TX infraSteven Luong3-88/+67
2021-08-26ikev2: check for valid cipher + integrityBenoît Ganne1-6/+6
2021-08-26ikev2: fix DNS resolution overflowBenoît Ganne1-1/+7
2021-08-26af_xdp: fix stale rx/tx pointers in xsk objectsBenoît Ganne1-10/+47
2021-08-26sr: extend the srv6 sid list structureAhmed Abdelsalam2-42/+51
2021-08-26acl: fix prefetch out of struct bound on ArmTianyu Li1-1/+1
2021-08-25fib: fix source address get error for p2p ifjxm1-0/+24
2021-08-23af_xdp: fix xsk_socket__delete left un-cleanuparikachen1-3/+3
2021-08-20ip: check if interface has link-local addressStanislav Zaikin1-1/+6
2021-08-20ikev2: fix use-after-freeBenoît Ganne1-2/+3
2021-08-20rdma: decrease inliningBenoît Ganne1-26/+19
2021-08-20vppinfra: fix clib_random_buffer_get_data cachingBenoît Ganne1-2/+2
2021-08-20buffers: fix buffer linearizationBenoît Ganne2-131/+376
2021-08-20perfmon: fix perf event user page readBenoît Ganne1-45/+76
2021-08-20vlib: add format_vnet_buffer_no_chainBenoît Ganne8-21/+36
2021-08-20ikev2: decrease inliningBenoît Ganne1-26/+26
2021-08-20build: fix external plugin buildBenoît Ganne1-0/+1
2021-08-19nat: handle ED in2out ICMP errors with workersMatthew Smith1-0/+22
2021-08-19acl: add API call for setting the toggle to select between linear and bihash-...Andrew Yourtchenko3-1/+148
2021-08-18vhost: interrupt mode support with mqSteven Luong3-138/+209
2021-08-18vat2: add shared memory argumentOle Troan5-99/+226
2021-08-17nat: fix counters increment for output featureAlexander Chernavin3-68/+93
2021-08-17ip: reassembly cleanupKlement Sekera4-246/+139
2021-08-17build: install ethernet/ethernet_types_api.hMohammed Hawari1-0/+1
2021-08-17build: remove dh-systemd from dependenciesAndrew Yourtchenko1-1/+0
2021-08-14ip: Fix crash in ip address add on sub-int without exact-matchPim van Pelt4-12/+32
2021-08-13ip: punt redirect add nh in apiNathan Skrzypczak9-100/+243
2021-08-13ip: source address selectionOle Troan7-201/+310
2021-08-13wireguard: add flag to check hmac for decryptionGabriel Oginski1-0/+1
2021-08-12nat: NAT44ED configuration refactorFilip Varga4-378/+365
2021-08-12nat: correct pool ops when disable nat44 pluginAlexander Skorichenko1-10/+10
2021-08-12session vcl: cert key add/del with socket apiFlorin Coras6-10/+218
2021-08-12tls: add start_listen openssl API return value checkOfer Heifetz1-4/+30
2021-08-12build: consistent debhelper 10 supportNick Brown2-3/+1
2021-08-11svm: make more fifo segment header fields privateFlorin Coras4-45/+28
2021-08-11fib: Compiile time option to use 8-8-8-8 stride tries for FIB ratherNeale Ranns3-0/+124
2021-08-11fib: A 16-8-8 and a 8-8-8-8 versions of an ip4_fib_tNeale Ranns14-423/+936
2021-08-11ip: [re]introduce the 8-8-8-8 stride MTRIENeale Ranns3-64/+229
2021-08-11ip: Rename the ip4 mtrie function to be 16_8_8 specificNeale Ranns4-218/+202
2021-08-10vppinfra: Fix bihash del warningNathan Skrzypczak2-0/+7
2021-08-10tls: picotls optimize rx pathFlorin Coras1-69/+113
2021-08-10tls: picotls optimize writesFlorin Coras2-113/+188
2021-08-10misc: do not capture tx packets twiceBenoît Ganne1-13/+30
an class="o">!= vft->fesv_activate) { if (vft->fesv_activate(best_src, fib_entry)) { /* * next best source activated ok, use its path list */ src->fes_pl = best_src->fes_pl; } } else { /* * next best source does not require activation, use its path list */ src->fes_pl = best_src->fes_pl; } } else { /* * find the covering prefix. become a dependent thereof. * for IP there should always be a cover, though it may be the default route. * For MPLS there is never a cover. */ if (FIB_PROTOCOL_MPLS == fib_entry->fe_prefix.fp_proto) { src->fes_pl = fib_path_list_create_special(DPO_PROTO_MPLS, FIB_PATH_LIST_FLAG_DROP, NULL); } else { src->u.interpose.fesi_cover = fib_table_get_less_specific(fib_entry->fe_fib_index, &fib_entry->fe_prefix); ASSERT(FIB_NODE_INDEX_INVALID != src->u.interpose.fesi_cover); cover = fib_entry_get(src->u.interpose.fesi_cover); src->u.interpose.fesi_sibling = fib_entry_cover_track(cover, fib_entry_get_index(fib_entry)); /* * if the cover is attached then install an attached-host path * (like an adj-fib). Otherwise inherit the forwarding from the cover */ if (FIB_ENTRY_FLAG_ATTACHED & fib_entry_get_flags_i(cover)) { fib_entry_src_rr_resolve_via_connected(src, fib_entry, cover); } else { fib_entry_src_rr_use_covers_pl(src, fib_entry, cover); } } } fib_path_list_unlock(old_pl); fib_path_list_lock(src->fes_pl); /* * return go for install */ return (!0); } /** * Source Deactivate. * Called when the source is no longer best source on the entry */ static void fib_entry_src_interpose_deactivate (fib_entry_src_t *src, const fib_entry_t *fib_entry) { fib_entry_t *cover; if (FIB_NODE_INDEX_INVALID != src->u.interpose.fesi_cover) { /* * remove the depednecy on the covering entry, if that's * what was contributing the path-list */ cover = fib_entry_get(src->u.interpose.fesi_cover); fib_entry_cover_untrack(cover, src->u.interpose.fesi_sibling); src->u.interpose.fesi_cover = FIB_NODE_INDEX_INVALID; } else { fib_entry_src_t *best_src; best_src = fib_entry_src_rr_get_next_best(src, fib_entry); if (best_src) { best_src->fes_flags &= ~FIB_ENTRY_SRC_FLAG_CONTRIBUTING; /* * there is another source for this entry. activate it so it * can provide forwarding */ FIB_ENTRY_SRC_VFT_INVOKE(best_src, fesv_deactivate, (best_src, fib_entry)); } } fib_path_list_unlock(src->fes_pl); src->fes_pl = FIB_NODE_INDEX_INVALID; src->fes_entry_flags &= ~FIB_ENTRY_FLAGS_RR_INHERITED; } static int fib_entry_src_interpose_reactivate (fib_entry_src_t *src, const fib_entry_t *fib_entry) { fib_entry_src_interpose_deactivate(src, fib_entry); return (fib_entry_src_interpose_activate(src, fib_entry)); } static fib_entry_src_cover_res_t fib_entry_src_interpose_cover_change (fib_entry_src_t *src, const fib_entry_t *fib_entry) { fib_entry_src_cover_res_t res = { .install = !0, .bw_reason = FIB_NODE_BW_REASON_FLAG_NONE, }; if (FIB_NODE_INDEX_INVALID == src->u.interpose.fesi_cover) { /* * the source may be added, but it is not active * if it is not tracking the cover. */ return (res); } /* * this function is called when this entry's cover has a more specific * entry inserted benaeth it. That does not necessarily mean that this * entry is covered by the new prefix. check that */ if (src->u.interpose.fesi_cover != fib_table_get_less_specific(fib_entry->fe_fib_index, &fib_entry->fe_prefix)) { fib_entry_src_interpose_deactivate(src, fib_entry); fib_entry_src_interpose_activate(src, fib_entry); /* * dependent children need to re-resolve to the new forwarding info */ res.bw_reason = FIB_NODE_BW_REASON_FLAG_EVALUATE; } return (res); } static void fib_entry_src_interpose_add (fib_entry_src_t *src, const fib_entry_t *entry, fib_entry_flag_t flags, dpo_proto_t proto, const dpo_id_t *dpo) { dpo_copy(&src->u.interpose.fesi_dpo, dpo); } static void fib_entry_src_interpose_remove (fib_entry_src_t *src) { dpo_reset(&src->u.interpose.fesi_dpo); } static void fib_entry_src_interpose_set_data (fib_entry_src_t *src, const fib_entry_t *fib_entry, const void *data) { const dpo_id_t *dpo = data; dpo_copy(&src->u.interpose.fesi_dpo, dpo); } /** * Contribute forwarding to interpose in the chain */ const dpo_id_t* fib_entry_src_interpose_contribute(const fib_entry_src_t *src, const fib_entry_t *fib_entry) { return (&src->u.interpose.fesi_dpo); } static void fib_entry_src_interpose_copy (const fib_entry_src_t *orig_src, const fib_entry_t *fib_entry, fib_entry_src_t *copy_src) { copy_src->u.interpose.fesi_cover = orig_src->u.interpose.fesi_cover; if (FIB_NODE_INDEX_INVALID != copy_src->u.interpose.fesi_cover) { fib_entry_t *cover; cover = fib_entry_get(orig_src->u.interpose.fesi_cover); copy_src->u.interpose.fesi_sibling = fib_entry_cover_track(cover, fib_entry_get_index(fib_entry)); } dpo_copy(&copy_src->u.interpose.fesi_dpo, &orig_src->u.interpose.fesi_dpo); } static void fib_entry_src_interpose_flag_change (fib_entry_src_t *src, const fib_entry_t *fib_entry, fib_entry_flag_t new_flags) { if (!(new_flags & FIB_ENTRY_FLAG_INTERPOSE)) { /* * stop tracking the source contributing forwarding * and reset the interposer DPO */ fib_entry_src_interpose_deactivate(src, fib_entry); fib_entry_src_interpose_deinit(src); } } static u8* fib_entry_src_interpose_format (fib_entry_src_t *src, u8* s) { s = format(s, " cover:%d interpose:\n%U%U", src->u.interpose.fesi_cover, format_white_space, 6, format_dpo_id, &src->u.interpose.fesi_dpo, 8); return (s); } const static fib_entry_src_vft_t interpose_src_vft = { .fesv_init = fib_entry_src_interpose_init, .fesv_deinit = fib_entry_src_interpose_deinit, .fesv_activate = fib_entry_src_interpose_activate, .fesv_reactivate = fib_entry_src_interpose_reactivate, .fesv_deactivate = fib_entry_src_interpose_deactivate, .fesv_cover_change = fib_entry_src_interpose_cover_change, .fesv_cover_update = fib_entry_src_rr_cover_update, .fesv_format = fib_entry_src_interpose_format, .fesv_add = fib_entry_src_interpose_add, .fesv_remove = fib_entry_src_interpose_remove, .fesv_contribute_interpose = fib_entry_src_interpose_contribute, .fesv_set_data = fib_entry_src_interpose_set_data, .fesv_copy = fib_entry_src_interpose_copy, .fesv_flags_change = fib_entry_src_interpose_flag_change, }; void fib_entry_src_interpose_register (void) { fib_entry_src_register(FIB_SOURCE_INTERPOSE, &interpose_src_vft); }