summaryrefslogtreecommitdiffstats
path: root/src
AgeCommit message (Collapse)AuthorFilesLines
2019-05-06ppp: simplify code using existing functionsZhiyong Yang1-10/+6
Change-Id: Ib5289b4d08ca7a8d7f786cc606e6c760735b2a35 Signed-off-by: Zhiyong Yang <zhiyong.yang@intel.com>
2019-05-06Add missing init fn dependency to ipsec_initDave Barach1-0/+5
ipsec_init fails if vnet_feature_init hasn't occurred. Can happen if a particular set of plugins are loaded. Change-Id: I67b289d640c28d04e248b9a09ebcc8f205834fd2 Signed-off-by: Dave Barach <dave@barachs.net>
2019-05-06Fix VPP-1487 DHCP client does not support option 6-domain serverjackiechen19855-14/+61
Change-Id: I36ad1ef2a53af3d3f3a6348bc189b17e9e4e21bd Signed-off-by: jackiechen1985 <xiaobo.chen@tieto.com>
2019-05-06NAT64: Fix port byte order in nat64_free_out_addr_and_portFaicker Mo1-1/+1
Change-Id: Idc050e469a5b697ca5587ddd4e87ac2d48d15658 Signed-off-by: Faicker Mo <faicker.mo@ucloud.cn>
2019-05-06NAT66:assgin a error value for clib_bihash_kv_48_8_t kvlijianpeng1-2/+3
Change-Id: Iac0c8218abc8d144d93a955e948a48a732b63107 Signed-off-by: lijianpeng <li.jianpeng@zte.com.cn>
2019-05-03session/svm: apis for fifo shrinkingFlorin Coras6-1/+182
Change-Id: Ie519683bb90aae6fb95f2a09e251cded1890ed41 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-05-03svm: basic support for fifo shrinkingFlorin Coras3-78/+663
As opposed to growing, this is not a bulk operation, instead dependent on how the producer/consumer advance head and tail, the fifo will shrink in one or multiple steps. Only once the fifo's nitems and size are reduced to their appropriate values, equal or larger to what was requested, can the fifo chunks be collected by the owner. Chunk collection must be done with the segment heap pushed. Change-Id: Iae407ccf48d85320aa3c1e0304df56c5972c88c1 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-05-03Add callbacks for extended trace functionality, one as content is added with ↵Gary Boon2-1/+33
vlib_add_trace, and one to post-process the captured content immediately after trace filtering. Change-Id: Ieb521686d8c0e7ce1a0ef325f7abdde613e1eb9c Signed-off-by: Gary Boon <gboon@cisco.com>
2019-05-03mp_safe SW_INTERFACE_DUMP, SW_INTERFACE_DETAILS, SW_INTERFACE_TAG_ADD_DEL,Steven Luong4-0/+11
BRIDGE_DOMAIN_DUMP, CONTROL_PING, CONTROL_PING_REPLY, and show interface CLI Change-Id: I2927573b66bb5dd134b37ffb72af0e6676750917 Signed-off-by: Steven Luong <sluong@cisco.com> (cherry picked from commit 15c31921a628c5500cbed2ebc588d7ddbaa970a3)
2019-05-03svm: store normalized head/tail for fifoFlorin Coras3-53/+48
If head/tail are stored as "absolute" values that are normalized to [0, fifo_size] interval, when fifo is shrunk/grown the consumer and producer have to independently update to the new fifo size and fix head and tail, respectively. If the head and tail are stored as normalized values, under the right conditions, they don't need to be fixed when fifo size changes. This reverts one of the changes in gerrit 18223. Change-Id: I55a908828afe90925cf7c20186a940b25e5805f9 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-05-03Fix FIB initialization in UDP inputNathan Skrzypczak1-0/+1
Change-Id: I7c88ada2af039aa0861fe7c71361a293b999d0c7 Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
2019-05-03Add packet headers in UDPC fifosAloys Augustin2-38/+23
This change adds packet headers for each packet in a UDPC connection. This changes the semantic of UDPC from an unreliable, unordered stream of bytes to an unreliable, unordered sequence of packets. Change-Id: I831e43903870a5720d26daa6e971299d03b208d7 Signed-off-by: Aloys Augustin <aloaugus@cisco.com>
2019-05-03plugins: clean up plugin descriptionsDave Wallace37-36/+37
- Make plugin descriptions more consistent so the output of "show plugin" can be used in the wiki. Change-Id: I4c6feb11e7dcc5a4cf0848eed37f1d3b035c7dda Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
2019-05-02vlib: align stack on OS page sizeBenoît Ganne1-1/+1
Change-Id: I6d7589c967c5801a6a21a213723e2a895269e105 Signed-off-by: Benoît Ganne <bganne@cisco.com>
2019-05-02vpp_papi_provider.py: update defautmapping.Paul Vinciguerra1-1/+1
Add missing create_bvi/delete_bvi to defaultmapping. Correct typo in interface.api documentation. Change-Id: I8aa187f3b33c21fb2fcd55311ef79777c81d94d4 Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
2019-05-01Add node, frame to vlib main loop perf analysis callback argumentsDave Barach3-7/+16
Change-Id: Iaa5cd89791b0dfdb56a75009c564581d10696d83 Signed-off-by: Dave Barach <dave@barachs.net>
2019-05-01virtio: Fix virtio buffer allocationMohsin Kazmi1-1/+1
Change-Id: I0ffb468aef56f5fd223218a83425771595863666 Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2019-05-01virtio: remove configurable queue size supportMohsin Kazmi7-47/+27
Native virtio device through legacy driver can't support configurable queue size. Change-Id: I76c446a071bef8a469873010325d830586aa84bd Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2019-05-01svm: remove dead code triggering overflowBenoît Ganne1-26/+0
split_point is incremented twice per iteration whereas we only check for *split_point != '\0' at the beginning of the iteration. This code seems dead so remove it altogether. Change-Id: Iabaf26cd5c0c8f747e267bcff044540a2376d3f6 Signed-off-by: Benoît Ganne <bganne@cisco.com>
2019-05-01Enable NEON instructions in memcpy_leLijian.Zhang2-1/+9
Neon version of memcpy_le gives better performance compared with memmove on aarch64 Change-Id: I44b487bb0795a6e70dd1e55bdde4a077773ec859 Signed-off-by: Lijian Zhang <Lijian.Zhang@arm.com> Reviewed-by: Sirshak Das <sirdas@arm.com>
2019-05-01esp_encrypt: remove unnecessary codeZhiyong Yang1-1/+1
Change-Id: I2d7e873fca6ab266af75814fac5d4cb5cda93cef Signed-off-by: Zhiyong Yang <zhiyong.yang@intel.com>
2019-05-01ipsec: fix ipsec format overflowBenoît Ganne1-4/+3
hi->name is not NULL-terminated. Use specialized format function which does the right thing. Change-Id: Iadda51461af0c1ad4f38a6d24b76e816020f35c8 Signed-off-by: Benoît Ganne <bganne@cisco.com>
2019-04-30svm: more fifo refactor/cleanupFlorin Coras12-715/+959
Change-Id: Ie76c69641c8598164d0d00fd498018037258fd86 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-04-30elf: fix memcmp() overflowBenoît Ganne1-1/+1
name can be (and will be) smaller than section_name_start. Both name and section_name_start are NULL-terminated so we can use strcmp. Change-Id: Iec414810109f9267de20c25c0fe601df35daf89e Signed-off-by: Benoît Ganne <bganne@cisco.com>
2019-04-30stats: fix non null terminated stringBenoît Ganne1-0/+5
Change-Id: I08e490d9e955072eff20d0141598157d995bcb56 Signed-off-by: Benoît Ganne <bganne@cisco.com>
2019-04-30vppinfra: fix buffer overflow in unformat_tokenBenoît Ganne1-2/+8
Change-Id: Ia60e4092c45c192002de064c362a9265bc9baeec Signed-off-by: Benoît Ganne <bganne@cisco.com>
2019-04-30crypto: enforce per-alg crypto key lengthBenoît Ganne4-18/+57
Crypto algorithms have different requirements on key length. As we do not support key stretching (eg. PBKDF2), user must provide the exact key length used by the algorithm. Failing that means low-level crypto functions might read garbage (eg. aes128_key_expand() will read 16-bytes, regardless of the key provided by the user). Change-Id: I347a1ea7a59720a1ed07ceaad8b00a31f78458c9 Signed-off-by: Benoît Ganne <bganne@cisco.com>
2019-04-30stats: Add version defines in stat_client.hOle Troan1-0/+3
Change-Id: I9894a0c613b0486112623920d49371ceec9e6111 Signed-off-by: Ole Troan <ot@cisco.com>
2019-04-30reassembly: avoid race-conditionsKlement Sekera1-12/+26
Change-Id: Ibf5c283217a985e43a562f1969573eeb26ee6017 Signed-off-by: Klement Sekera <ksekera@cisco.com>
2019-04-29API: Add support for limits to language.Ole Troan6-20/+65
string name [limit = 64]; Meta-data to do argument validation. Change-Id: I1f3e0f09b2d5285224399413d25206f77bd3f4b1 Signed-off-by: Ole Troan <ot@cisco.com>
2019-04-27svm: fix fifo tail/head/ooo logic for u32 wrapFlorin Coras3-16/+283
These were introduced with the switch to unbound tail/head size, so they only affect master. Added unit tests to avoid future surprises. Change-Id: I83b6c9efbe31d8092ba59b8e2ed46f4da97f35db Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-04-26IF: return VTR attributes for all ifs in dump APIAlexander Chernavin1-20/+20
With this commit, VTR attributes are shown not only for subinterfaces but for all interfaces. Change-Id: I498185d905c0bf48431cddb916165f8e9c841b1f Signed-off-by: Alexander Chernavin <achernavin@netgate.com>
2019-04-26crypto, ipsec: change GCM IV handlingDamjan Marion5-58/+39
- nonce construction out of salt and iv is ipsec specific so it should be handled in ipsec code - fixes GCM unit tests - GCM IV is constructed out of simple counter, per RFC4106 section 3.1 Change-Id: Ib7712cc9612830daa737f5171d8384f1d361bb61 Signed-off-by: Damjan Marion <damarion@cisco.com>
2019-04-26nat: fix ED mode unknown proto session managementMatthew Smith3-8/+24
In endpoint dependent mode, when a session at the head of a user LRU is reused, if the IP protocol for that session was unknown (any other than tcp, udp, or icmp), the attempt to delete the session mapping from the in2out bihash was not using the same key that was used when the mapping was added. This would cause the deletion of the mapping to fail. If packets arrive later which match the original session, the search for the session key would succeed when it should have failed and the session, which is now associated with a different pair of endpoints, may end up being updated when it should not be. Update the key generation when reallocating an existing session to do the right thing if the session is for an unknown protocol. Also update format_nat_session() for unknown protocols so that 'vppctl show nat44 session detail' will display the protocol correctly. In endpoint dependent mode, the IP protocol is stored in the port field on a session if the protocol is unknown. The value is stored in host byte order, but the format function was swapping the bytes before writing the protocol. Change-Id: I9e8daadd4569cb2610532dab4e4f41d1567cf3d1 Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2019-04-26nat: prevent creation when-resolved static mappings on errorsAlexander Chernavin1-1/+1
When you create two identical NAT44 static mappings using interface name as external address and only local or ext port is different, VALUE_EXIST will be raised but when-resolved static mapping will remain. vpp# nat44 add static mapping tcp local 10.128.0.129 443 external GigabitEthernet0/8/0 8443 vpp# nat44 add static mapping tcp local 10.128.0.129 80 external GigabitEthernet0/8/0 8443 nat44 add static mapping: Mapping already exist. vpp# show nat44 static mappings NAT44 static mappings: tcp local 10.128.0.129:443 external 2.2.2.2:8443 vrf 0 tcp local 10.128.0.129:443 external GigabitEthernet0/8/0:8443 vrf -1 tcp local 10.128.0.129:80 external GigabitEthernet0/8/0:8443 vrf -1 With this commit, when-resolved static mapping is not created if the translation only differs in local or ext port. Change-Id: Ifc960b9dc1371caa2a8d3206a80a0ffd10d293e4 Signed-off-by: Alexander Chernavin <achernavin@netgate.com>
2019-04-26svm: fifo segment support for chunk allocationFlorin Coras8-26/+338
Change-Id: Ie96706b4d8bcb32d2d5f065bc765f95f4e9369e7 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-04-25crypto_ia32: minor change logicallyZhiyong Yang1-2/+1
"break;" will never be run after "return;" Change-Id: I4fdfd10406fdf61897078746d28fa1ee32fb0081 Signed-off-by: Zhiyong Yang <zhiyong.yang@intel.com>
2019-04-25crypto: AES GCM IV length is always 12Damjan Marion4-5/+2
... at least for use cases we are interested in Change-Id: I1156ff354635e8f990ce2664ebc8dcd3786ddca5 Signed-off-by: Damjan Marion <damarion@cisco.com>
2019-04-25Clean up redirectsDave Barach1-21/+50
Both firefox and chrome seem happy to browse a hugo-generated site Change-Id: Id216ad9c781643df42ac4fbce598eb2afa600f4d Signed-off-by: Dave Barach <dave@barachs.net>
2019-04-25Change dpdk thread data flags type to u16 from u8 to get more useful dataSimon Zhang2-6/+7
Change-Id: Idc3763c38f5aa638d4f290f4d4730577601d78b8 Signed-off-by: Simon Zhang <yuwei1.zhang@intel.com>
2019-04-25tap: Fix the indirect buffer allocationMohsin Kazmi1-1/+1
Change-Id: I73f76c25754f6fb14a49ae47b6404f3cbabbeeb5 Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
2019-04-25session: cleanup segment manager and fifo segmentFlorin Coras23-1005/+1001
Change-Id: I984f347fb465c0c405cef668d8690457e81788e2 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-04-25unittest: AES GCM test cases cleanupDamjan Marion1-270/+126
This reverts commit 7f2d57b69ea031cc6110b3a1f4c1ef1c35b67181. Change-Id: I23c3b4d2dab6e13cc8fbbf0ac9d0cfd8af3241c1 Signed-off-by: Damjan Marion <damarion@cisco.com>
2019-04-25crypto_ipsecmb: CBC IV size is always equal to block sizeDamjan Marion1-27/+13
Change-Id: If8b2c8942db17a853883360885def47ce50e7ddd Signed-off-by: Damjan Marion <damarion@cisco.com>
2019-04-25crypto_ipsecmb: use pre-expanded keysDamjan Marion2-219/+208
Change-Id: Ie1d34b7e71554516595e0cd228e2cd54a3b8d629 Signed-off-by: Damjan Marion <damarion@cisco.com>
2019-04-25session: use teps in accept/connect notificationsFlorin Coras11-81/+72
Change-Id: I58e713661a38cecbfdebd4609292d9d12e880cd2 Signed-off-by: Florin Coras <fcoras@cisco.com>
2019-04-25IPSEC; dpdk backend for tunnel interface encryptionNeale Ranns10-61/+169
Change-Id: Ide2a9df18db371c8428855d7f12f246006d7c04c Signed-off-by: Neale Ranns <nranns@cisco.com>
2019-04-25ipsec: drop runts in esp-decryptDamjan Marion1-0/+8
Change-Id: Id7fcaf8590f9f2dcccdebea0ad31c7ecd1cbc8af Signed-off-by: Damjan Marion <damarion@cisco.com>
2019-04-25crypto: improve key handlingDamjan Marion19-66/+351
Change-Id: If96f661d507305da4b96cac7b1a8f14ba90676ad Signed-off-by: Damjan Marion <damarion@cisco.com>
2019-04-25Remove dummy_interface_tx nodes from l2tp l2xcrw and nshJohn Lo3-27/+0
Change-Id: I51e0d4a9ec62514a85bbe4c5f56a48d60ab6f4e4 Signed-off-by: John Lo <loj@cisco.com>