Commit Graph

3066 Commits

Author SHA1 Message Date
Nathan Skrzypczak
bd23b405fb docs: nitfixes in FEATURE.yaml
Type: improvement

Change-Id: Iec585880085b12b08594a0640822cd831455d594
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2021-10-11 09:05:43 +00:00
Joshua Roys
5e5f800480 af_xdp: ensure at least one queue is created
Attempting to create an af_xdp interface with zerocopy where the
underlying driver didn't support it would lead to a crash due to
queue creation silently failing.

Type: fix

Signed-off-by: Joshua Roys <roysjosh@gmail.com>
Change-Id: Ifd9070b8c2b3023d71120c5cf20f7e89d04e4cb3
2021-10-11 07:37:52 +00:00
Florin Coras
6fff5ef8a9 tls: shutdown openssl context on app close
Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ie0fde16fb4e41637169474628808fddf343884f3
2021-10-08 20:39:54 +00:00
Artem Glazychev
ea96292985 vxlan-gpe: add udp-port configuration support
similar behavior as here: 839dcc0fb7

Type: improvement

Signed-off-by: Artem Glazychev <artem.glazychev@xored.com>
Change-Id: I1b0a8f8f3dab48839e27df7065cf5f786cf0b5e9
2021-10-08 11:38:56 +00:00
Benoît Ganne
3f59c63960 ikev2: lazy initialization
- do not initialize resources if ikev2 is not used.
 - process IKE packets only if we have profile(s) configured

Type: improvement

Change-Id: I57c95a888532eafd70989096c0555ebb1d7bef25
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-10-08 11:18:23 +00:00
Artem Glazychev
adf1497ee0 wireguard: peers dump fix
Type: fix

Signed-off-by: Artem Glazychev <artem.glazychev@xored.com>
Change-Id: I4450b8c8b50a3be8d6a399f6a58bc0e8eb500b28
2021-10-07 15:38:50 +00:00
Benoît Ganne
9685624a50 vppinfra: asan: improve overflow semantic
Type: improvement

Change-Id: Ia63899b82e34f179f9efa921e4630b598f2a86cb
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-10-07 15:36:04 +00:00
Fan Zhang
f50aab0184 build: fix ipsecmb version check
Type: fix

This patch fixes the chacha20-poly1305 support check in ipsecmb
engine build.

Signed-off-by: Fan Zhang <roy.fan.zhang@intel.com>
Signed-off-by: PiotrX Kleski <piotrx.kleski@intel.com>
Change-Id: I74b52a27f78a0f6a65c867dbd44a44a8f4a2ed60
2021-10-07 15:34:48 +00:00
Benoît Ganne
c7cceeebb7 ikev2: do not require optional IDr on IKE AUTH
IDr is optional in IKE AUTH from the initiator. In that case, the
responder is free to use any matching profile and fills the
corresponding IDr in the response.
The initiator is then free to accept or reject it.

Type: improvement

Change-Id: I07a1c64a40ed22bd41767c259406238bbbab5cf4
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-10-07 15:22:17 +00:00
Benoît Ganne
b37342c5a7 ikev2: add logs in case of parsing errors
Type: improvement

Change-Id: Id0a6a9e68725ea7aa0b7da14cf54d14405a907fb
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-10-07 15:21:55 +00:00
Benoît Ganne
9d22cb363e ikev2: do not send IDi on responder AUTH
The IDi is not mentioned in the RFC for the responder AUTH message, and
it confuses some IKE implementations.

Type: fix

Change-Id: I2bcefa1efd315412a6f5fa592668d4e0da510264
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-10-07 15:21:11 +00:00
Ray Kinsella
12ba95bff5 perfmon: Topdown Level 1 support on Snowridge
Enable Topdown Level 1 support on Snowridge,
enabled with standard CPU events on small core.

Type: improvement

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: I58ad09383de7464265ac1b69e683f253591e3b5e
2021-10-07 13:23:06 +00:00
Ray Kinsella
ce45b16156 perfmon: check bundle is supported
Add a check bundle is supported before futher activation.
Enable different bundles with same name, supported on different platforms.

Type: improvement

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: I73e8bbd1e07c05ebccd9146d48a234eb598a2388
2021-10-07 13:23:06 +00:00
Ray Kinsella
0d3914c026 perfmon: fix peusdo events
Fix peusdo events, missed populating "core" events with peusdo events.

Type: fix
Fixes: bf37bf6f7

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: I569fa876f1b58540adac0b095be0ff4ade664dec
2021-10-07 13:23:06 +00:00
Artem Glazychev
dd630d15d3 wireguard: add events for peer
we can receive events from peer about its state:
-WIREGUARD_PEER_STATUS_DEAD
-WIREGUARD_PEER_ESTABLISHED

Type: improvement
Change-Id: Ide83fbe2cfafa79ded5bcf3f6a884c26a7583db0
Signed-off-by: Artem Glazychev <artem.glazychev@xored.com>
2021-10-06 21:32:33 +00:00
Artem Glazychev
7dd3b5b5e3 wireguard: add ipv6 support
Type: improvement
Signed-off-by: Artem Glazychev <artem.glazychev@xored.com>
Change-Id: If1a7e82ce163c4c4acaa5acf45ad2b88371396f6
2021-10-06 17:57:46 +00:00
Nathan Skrzypczak
5e6a1651c4 docs: more nitfixes
Type: fix

Change-Id: I41455e1cdc62e7c0baa148630b0701b042f3b156
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2021-10-06 15:04:00 +02:00
Ray Kinsella
ede7143386 perfmon: bundles with multiple types
Allow perfmon bundles to support more than one bundle type, either node
or thread. Only used for topdown bundle for the moment.

Type: improvement

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: Iba3653a4deb39b0a8ee8ad448a7e8f954283ccd8
2021-10-05 10:44:39 +00:00
Filip Varga
4189108e1d nat: NAT44 ED api fix and improvement
Backward compatibility fix returns erroneous behavior that lets user
add internally unused inside interface for the purpose
of complying with the old add/dump/details API behavior.
Change introduced in https://gerrit.fd.io/r/c/vpp/+/32951 removed
extra inside interface that wasn't required or any how used by the
output feature. This patch also changed outside interface flags to
inside & outside. This fix returns the old behavior by imitating
the old behavior through dummy registratoin data.

Added new API calls nat44_ed_add_del_output_interface
and nat44_ed_output_interface_get/details as a
replacement of old API's. New API introduces
simplified and cleaner way of configuring outside
feature without requirement of config flags.

Type: improvement
Signed-off-by: Filip Varga <fivarga@cisco.com>
Change-Id: I7a170f7325727c04da5e2e3ffbe3f02179531284
2021-10-05 07:36:14 +00:00
Nick Brown
ee1ca438b3 build: Allow ipsec-mb plugin to build with libipsec_mb 0.55
The 0.55 version of libipsec_mb does not support the chacha functions
used in the plugin.

The missing symobls are:
ipsecmb_ops_chacha_poly
ipsecmb_ops_chacha_poly_chained
IMB_CIPHER_DIRECTION

Check for ipsecmb_ops_chacha_poly() and conditionalise the chacha code
in the plugin on this.

ipsec_mb 0.55 is the version currently found in Debian Stable (bullseye)

Type: make
Signed-off-by: Nick Brown <nickbroon@gmail.com>
Change-Id: I88c962ac4f99a58b5cd61fb9b75f692e27d4ec30
2021-10-04 18:31:46 +00:00
Mohsin Kazmi
3effb4e630 memif: integrate with new tx infra
Type: improvement

Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: I7c2b9891e269f23c3aa2a0abfee3cf0a0f1e2135
2021-10-04 18:27:58 +00:00
Filip Tehlar
4223ff14b2 hsa: do not drop the barrier when creating echo server
Type: fix

Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
Change-Id: I25d3ac72360bea130f567095b486d8e295d2f2f7
2021-10-04 18:09:47 +00:00
Artem Glazychev
9e24f7eb91 wireguard: use the same udp-port for multi-tunnel
now we can reuse udp-port for many wireguard interfaces

Type: improvement
Change-Id: I14b5a9dbe917d83300ccb4d6907743d88355e5c5
Signed-off-by: Artem Glazychev <artem.glazychev@xored.com>
2021-10-04 16:21:34 +00:00
Jieqiang Wang
039f289e51 vppinfra: fix potential memory access error in _pool_init_fixed
_pool_init_fixed uses mmap to initialize a fixed-size and preallocated
pool, whose size is the sum of vector_size and free_index_size with
alignment to the CLIB_CACHE_LINE_BYTES and page size. In this way
vector_size equals to pool_header_t + vec_header_t + elt_size * max_elts
so moving to the end of the pool space should be pool_header_t pointer +
vector_size, instead of vec_header_t pointer + vector_size.

Simple code to reproduce this error:

u64 *pool;
pool_init_fixed(pool, 2042);

Improve unit test to cover this case

Type: fix

Signed-off-by: Jieqiang Wang <jieqiang.wang@arm.com>
Reviewed-by: Lijian Zhang <lijian.zhang@arm.com>
Reviewed-by: Tianyu Li <tianyu.li@arm.com>
Change-Id: If088ef89b3dcb2d874ee837ae9da60983b14615c
Signed-off-by: Dave Barach <dave@barachs.net>
2021-10-04 10:30:54 -04:00
Ray Kinsella
bf37bf6f79 perfmon: topdown events as peusdo events
Topdown events are peusdo events exposed by linux,
and are only present on Intel platforms.
Change to clarifies this.

Type: fix

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: I6a3dcea5f43f53dbb96475329baf5e596a24d54f
2021-10-04 09:14:24 +00:00
Nathan Skrzypczak
d0ea764a5d docs: plugin comment nitfixes
Type: improvement

Change-Id: Ib7e2f5f314144064de7b6be0fade3db2f9c943fe
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2021-10-04 08:26:43 +00:00
Sivaprasad Tummala
aca308d8f9 hsa: proxy app worker thread deadlock
proxy main lock not released in certain cases and resulting in deadlock.

Type: fix

Signed-off-by: Sivaprasad Tummala <Sivaprasad.Tummala@intel.com>
Change-Id: Ib869f459b447189bb921c05fd260f3691c2ac787
2021-10-03 20:38:05 +00:00
Mohsin Kazmi
f5462369f3 devices: add support for pseudo header checksum
Type: improvement

Linux uses pseudo header checksum when checksum of l4 is offloaded.
This patch adds similar support in virtual interfaces.

Change-Id: I6a94d1104e59356f95057e7c122e3be9cd8659a3
Signed-off-by: Aloys Augustin <aloaugus@cisco.com>
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2021-10-01 10:04:24 +00:00
Artem Glazychev
de3caf37c6 wireguard: move adjacency processing from wireguard_peer to wireguard_interface
now we should add routes manually

Type: improvement
Change-Id: I877511a18854efdfad02939267d38a216b2ccec3
Signed-off-by: Artem Glazychev <artem.glazychev@xored.com>
2021-09-30 14:15:58 +00:00
Nathan Skrzypczak
33b3092d70 nat: doc nitfixes
Type: improvement

Change-Id: I9a4303030b9657c28bbd73168def72c7daa13483
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2021-09-30 08:40:37 +00:00
Alexander Chernavin
c7164827a9 nat: nat44-ed add session timing out indicator in api (2)
Type: improvement

Currently, NAT44-ED users sessions details are returned for both active
and timed out NAT sessions. It may confuse users that expect to see only
active sessions in the response and make them think that timeouts for
NAT sessions do not work.

With this change, introduce an indicator of timing out for NAT sessions
returned in NAT44-ED user session details.

Signed-off-by: Alexander Chernavin <achernavin@netgate.com>
Change-Id: Ib4d689f77cec4b0b0cc8484019e13733cc8bdc0d
2021-09-29 21:21:14 +00:00
Filip Tehlar
a5504a47cf ikev2: build only when deps requirements are met
Type: improvement

Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
Change-Id: I89bcc1ba804ded676b194dbda52704cd0c54a67e
2021-09-29 14:44:03 +00:00
Filip Tehlar
36217e3ca8 api: API trace improvements
Type: improvement

 * add support for JSON format in API trace
 * add ability to replay JSON API trace in both VPP and VAT2
 * use CRC for backward compatibility check during JSON API replay
 * fix API trace CLI (and remove duplicits)
 * remove custom dump
 * remove vppapitrace.py
 * update docs accordingly

Change-Id: I5294f68bebe6cbe738630f457f3a87720e06486b
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
Signed-off-by: Ole Troan <ot@cisco.com>
2021-09-28 16:06:19 +00:00
Ole Troan
3459ece6da misc: vpe.api messages dynamically allocated
This is the last in the series of moving API messages from vpp/api/vpe.api to vlibmemory/memclnt.api.
This patch makes the remaining vpe.api messages dynamic, to help VAT2 binary-api command.
Moves the VAT test code to a separate file and removes the now unnused API meta files.

Type: improvement
Signed-off-by: Ole Troan <ot@cisco.com>
Change-Id: I01dd78eaff1d3715dff17d2643bf0f7f0089935b
Signed-off-by: Ole Troan <ot@cisco.com>
2021-09-28 15:17:37 +00:00
arikachen
1ae9819908 af_xdp: fix init lock for shared txq
Type: fix

Signed-off-by: arikachen <eaglesora@gmail.com>
Change-Id: Idb5e66d7a2a7ccb6fb5155341df54586186eb11f
2021-09-28 13:49:55 +00:00
Július Milan
11c7cdd590 nat: NAT44 ED & EI session filtering CLI
Improving session filtering capabilities of
show nat44 sessions CLI command for EI and ED NAT
plugins. Adding filtering options: saddr, sport,
daddr, dport, proto for both i2o and o2i flows.

Type: improvement

Change-Id: I70bc94a2e922cddf9451eb7dcbf4a7be21ebf0df
Signed-off-by: Filip Varga <fivarga@cisco.com>
2021-09-28 13:38:36 +00:00
arikachen
ca92091f95 af_xdp: fix free mem in tx while no free slot
Type: fix

Signed-off-by: arikachen <eaglesora@gmail.com>
Change-Id: Id305b9d311b2d0d11583db1a14a45d9187a1e628
2021-09-28 12:59:24 +00:00
Benoît Ganne
a427690b80 ikev2: support variable-length nonces
IKEv2 nonces can be 16 to 256 bytes.

Type: fix

Change-Id: Ib332028594355c9e5b462bddb7e4dffbcdc9a927
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-09-27 14:39:15 +00:00
Vladislav Grishenko
c022b2fe39 fib: fix crash on exporter tracker remove
Exported entries are tracked only when the prefix found in the export
FIB is really attached, exporter tracker is not set if the export
entry is not valid for export, ex. for special FIB entries - default
route, zeronet, mcast and broadcast prefixes.
When imported entries need to be purged, such unset exporter tracker is
being removed by non-initialized index with absent delegate entries,
causing corresponding assert and crash.

Type: fix
Signed-off-by: Vladislav Grishenko <themiron@yandex-team.ru>
Change-Id: Ib24a2e7853a03a960577872480213e1e8097da5a
2021-09-27 11:13:13 +00:00
Florin Coras
a1400cecb8 misc: api move continued
Move control ping and change dependencies from vpe.api_types to
memclnt.api_types

Type: refactor

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I9f8bc442e28738c48d64d1f6794082c8c4f5725b
2021-09-27 08:01:44 +00:00
Aloys Augustin
87f478be88 wireguard: fix wg-output-tun feature configuration
The removed code caused the feature to be wrongly removed on the wg
interface.

Type: fix
Signed-off-by: Aloys Augustin <aloaugus@cisco.com>
Change-Id: I998e01ec231527128eaeae78bcc7576ac00e5b12
2021-09-23 12:16:03 +00:00
Florin Coras
d60b432b13 svm: remove unused fifo functions
Type: refactor

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I4525bc669d1c42c41dbc398cf239a093b6853298
2021-09-23 12:15:47 +00:00
Artem Glazychev
0455431a00 ping: set fib_index for lookup_node
lookup node uses this field later to set fib_index for buffer

Type: fix

Signed-off-by: Artem Glazychev <artem.glazychev@xored.com>
Change-Id: I993cf80296e1713b4f13fc6ccdf49ebeaf295467
2021-09-22 16:59:10 +00:00
Andrew Yourtchenko
5aa06abf24 pnat: fix the version of the PNAT plugin from the hardcoded 0.0.1
Type: fix
Change-Id: I35db6763f3c5bd73169a222a4a93a917e8f468e6
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
Signed-off-by: Ole Troan <ot@cisco.com>
2021-09-21 15:35:07 +02:00
Nathan Skrzypczak
b3ea73e766 session: implement app_ns deletion
Type: feature

Change-Id: If0edbb21a0283d66c648a9e190d238c8cfa56353
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2021-09-21 05:13:26 +00:00
Mohsin Kazmi
41b23bc955 hash: add support for hashing infra
Type: feature

Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: I3652ae275385d9b1eb1b11f418e3a7e5fef2f556
2021-09-20 11:11:02 +00:00
Benoît Ganne
8b99777263 dpdk: enable ENA tx offload
Type: improvement

Change-Id: Ic7c2ac4237ecd192def7c3530ae5f788c62cf9ad
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2021-09-17 20:12:22 +00:00
Nathan Skrzypczak
0e6584014a vppinfra: move format_table from perfmon
This code seems really usefull for reuse in
other plugins, for pretty table formatting

Type: feature

Change-Id: Ib5784a0dfc81b7d5a5d1f5ccdd02072e460a50fb
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2021-09-17 20:10:59 +00:00
Damjan Marion
a274c3a2ed misc: put devtools plugins into separate component/package
Type: make
Change-Id: I2958e9eddadee6434766ecd3cdb3b9cea742ed64
Signed-off-by: Damjan Marion <damarion@cisco.com>
2021-09-17 15:04:28 +00:00
Steven Luong
d26a582759 memif: avoid double pool_put on a clib_file
When memif CP processes the socket connection error, it may go through
the following code paths which may eventually cause double pool_put on a
clib_file

memif_master_conn_fd_error:633 -> memif_disconnect ->
memif_socket_close -> memif_file_del_by_index ->
clib_file_del_by_index -> clib_file_del -> pool_put

After memif_master_conn_fd_error:633, the code continues on

memif_maser_conn_fd_error:651 -> memif_file_del -> clib_file_del ->
pool_put

The fix is to skip calling memif_file_del in
memif_master_conn_fd_error:651 if uf->file_descriptor == ~0 to catch
problem from all possible paths in memif_master_conn_fd_error

Type: fix

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: I0960998db1ff358a8ddd4a5e22188a244eccd270
2021-09-17 14:57:33 +00:00