1874 Commits

Author SHA1 Message Date
magalik
23caa885af SNAT: user's dump and session dump of a certain snat user.
Change-Id: If75a35dbdcb43c1ce0128b8649f2ca3970d3fff5
Signed-off-by: Martin <magalik@cisco.com>
2017-03-02 18:20:38 +00:00
Neale Ranns
baf2e90a91 Remove the unused VRF ID parameter from the IP neighbour Add/Del API
Change-Id: Icf0d72f6af1f98c86f78e586c354515ac69804aa
Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-03-02 18:12:55 +00:00
Klement Sekera
7388448712 BFD: command line interface
Implement command line interface to the BFD binary APIs. Add
corresponding unit tests.

Change-Id: Ia0542d0bc4c8d78e6f7b777a08fd94ebfe4d524f
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-03-02 11:56:47 +00:00
Neale Ranns
39f9d8bd22 [Proxy] ARP tests
Change-Id: I40d6d763b55a26cdee0afef85d1acdd19dd10dd6
Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-02-27 12:10:50 +00:00
Klement Sekera
239790fd91 BFD: echo function
Change-Id: Ib1e301d62b687d4e42434239e7cd412065c28da0
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-02-26 14:20:24 +00:00
Jan Gelety
b5b2ef5947 Enable tests with VRF reset
- needed to filter out ICMPv6 Neighbor Discovery - Neighbor
  Advertisement packets

- needed to reset routes of reset VRFs learned from ICMPv6
  Neighbor Discovery - Neighbor Advertisement packets after
  run_verify_test()

Change-Id: I8238d8f73428d511ab68ab7765d99ce7dc3a6633
Signed-off-by: Jan Gelety <jgelety@cisco.com>
2017-02-25 09:45:01 +00:00
Filip Tehlar
22dc9df3a8 Remove prints from LISP test
Change-Id: I2776e0a0661794b1c0076519b08807080a1282fb
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2017-02-23 09:12:16 +00:00
Neale Ranns
2dd6852d81 Consolidate DHCP v4 and V6 implementation. No functional change intended
The DHCP proxy and VSS information maintained by VPP is the same for v4 and v6, so we can manage this state using the same code.
Packet handling is cleary different, so this is kept separate.

Change-Id: I10f10cc1f7f19debcd4c4b099c6de64e56bb0c69
Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-02-16 04:01:06 -08:00
Neale Ranns
20a175a184 dhcp: multiple additions
DHCP additions:
1) DHCPv4 will only relay a message back to the client, if the Option82 information is present. So make this the default.
2) It is no longer possible to select via the API to "insert circuit ID" - since this is now default
3) Remove the version 2 API since it's now the same as version 1.
4) Adding the VSS option is now conditional only on the presence of VSS config (not the 'insert' option in the set API)
5) DHCP proxy dump via API

Change-Id: Ia7271ba8c1d4dbf34a02c401d268ccfbb1b74f17
Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-02-21 22:25:48 +00:00
Filip Tehlar
770e89e6b9 Add basic 4o4 LISP unit test
Change-Id: I2d812153d7afe7980346382b525af89b3c47e796
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2017-02-21 22:21:19 +00:00
Jan Gelety
057bb8c3a4 test: ip6 vrf instances multi-context test (CSIT-497)
- add/delete IPv6 VRF instances and verify results by parsing output
  of ip6_fib_dump API command and by traffic

- small changes in assert_nothing_captured and get_capture to get logged
  unexpected packets

Change-Id: I32207447be2df942e335aa9890ff52fb88e46597
Signed-off-by: Jan Gelety <jgelety@cisco.com>
2017-02-21 22:20:58 +00:00
Neale Ranns
5a8123bda0 Python test IP and MPLS objects conform to infra.
Add IP[46] MFIB dump.

Change-Id: I4a2821f65e67a5416b291e4912c84f64989883b8
Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-02-20 09:54:49 +00:00
Dave Wallace
90c55724b5 make test: save + dump VPP api trace log; VPP-640
Change-Id: I20aacc927f2b04f42b0a7220c4283560b4d2a359
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
2017-02-19 13:51:11 +00:00
Klement Sekera
c48829bb0a BFD: put session admin-up/admin-down
Change-Id: I7d8889dce8495607106593ad83320c9af0f2fa07
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-02-17 16:32:51 +00:00
Juraj Sloboda
665e482f24 Fix handling of ping to SNAT out interface
Change-Id: I322bfb3469b3d0d5b0cac39a6c2dba1c6f83ce3d
Signed-off-by: Juraj Sloboda <jsloboda@cisco.com>
2017-02-17 16:31:21 +00:00
Juraj Sloboda
b33f413af4 Add handling of ICMP error packets in SNAT (VPP-629)
Change-Id: I8d2022b7cb3ef3da736c085bccbb5b9c057a8d76
Signed-off-by: Juraj Sloboda <jsloboda@cisco.com>
2017-02-16 10:48:53 +00:00
Matus Fabian
e22e546f6c SNAT: add static mappings with unresolved external interface address to snat_static_mapping_dump
Change-Id: Ib560b397700fe058ad1e2970989d98e3debf54aa
Signed-off-by: Matus Fabian <matfabia@cisco.com>
2017-02-15 13:24:37 +00:00
Klement Sekera
aeeac3bf44 BFD: loop back echo packets
Change-Id: I772b63ac25ebfccaff9ab9d8d0b1445e85f21df7
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-02-15 12:10:23 +00:00
Klement Sekera
d3ba515d99 BFD: respect remote demand mode
Change-Id: I5063d31f5305c848043afb32fcacff6e61aed79f
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-02-14 03:38:44 +01:00
Klement Sekera
acb9b8e8c3 make test: improve stability
Disable automatic garbage collection and run it manually before
running each test case to minimize stalls. Improve vpp subprocess
cleanup. Reduce helper thread count to one and properly clean that
thread once it's not needed.

Change-Id: I3ea78ed9628552b5ef3ff29cc7bcf2d3fc42f2c3
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-02-14 03:38:37 +01:00
Klement Sekera
b91017a30b make test: work around scapy truncated packets
Under stress, it's possible to hit a race condition, when the packet
header is fully written to pcap, but not all packet data - yet.
Scapy is stupid enough to:
1. not detect and report this error, truncating the packet instead
2. continue munching more data from wrong offset
The work around is to scan the file ahead, parse the packet header,
figure out how much data we need, wait for the file to be big
enough, then restore the file position back to where it was
and finally let scapy parse the packet.

Change-Id: I9fc71d3ebdc62ecab6c90b90f177d0eaeb09b8bb
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-02-09 06:10:47 +01:00
Klement Sekera
7fce133ca0 make test: BFD tests speedup
Change-Id: I0b3064a311f28ebf7cd9db0a59cb04c7c25c9d58
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-02-08 07:47:21 +01:00
Klement Sekera
a57a970952 BFD: modify session parameters
Change-Id: I666e5c0cc71a3693640960c93cdd1907f84fbe23
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-02-08 07:47:00 +01:00
Klement Sekera
104543fa6a make test: improve test filtering
Implement fine-grained test filtering by supporting more complicated
filters beside the original file name suffix filter.

Change-Id: If5a166d08cffe8c58cc6cf174e6df861c34dbaa6
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-02-06 23:33:52 +00:00
Klement Sekera
6320514170 make test: fix dependencies
checkstyle - doesn't need scapy/pexpect, remove it
doc - scapy wasn't patched properly, fix it

Change-Id: I65202cb14edeb239d21ce10f17d9b4fccce43d62
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-02-06 12:37:16 +00:00
Neale Ranns
aaa396ac6b Test checksyle for IP mcast tests
Change-Id: I20b61b7e63f74b4656d84717633e06646514c5eb
Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-02-05 09:54:33 -08:00
Neale Ranns
5737d88fd9 pep8 compliance for test_ip6.py
Change-Id: If29a1eba3e7056903978de782c062589bec0137e
Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-02-03 15:21:32 +00:00
Neale Ranns
9bea8fb0b0 Next node frame over-flow after replication
Change-Id: I25077dd0739787de4f7512e5a70a62e8c34c28e4
Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-02-03 14:32:36 +00:00
Matus Fabian
09d96f4a61 SNAT: Port allocation per protocol
Ports are allocated per protocol (UDP, TCP, ICMP)
1:1 NAT with port is configured for specific protocol

Change-Id: I37ae5eed3715b223d0620d4fdaed7a482bb7a834
Signed-off-by: Matus Fabian <matfabia@cisco.com>
2017-02-03 01:09:45 -08:00
Klement Sekera
b17dd9607e BFD: SHA1 authentication
Add authentication support to BFD feature. Out of three existing
authentication types, implement SHA1 (sole RFC requirement). Simple
password is insecure and MD5 is discouraged by the RFC, so ignore
those.
Add/change APIs to allow configuring BFD authentication keys
and their usage with BFD sessions.

Change-Id: Ifb0fb5b19c2e72196d84c1cde919bd4c074ea415
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-02-02 12:04:30 +00:00
Matus Fabian
e1ae29a3f7 SNAT: Add outbound addresses to FIB (VPP-613)
Add the external NAT address to the FIB as receive entries.
This ensures that VPP will reply to ARP for these addresses and we don't need
to enable proxy ARP on the outside interface.

Change-Id: I1db153373c43fec4808845449a17085509ca588c
Signed-off-by: Matus Fabian <matfabia@cisco.com>
2017-01-31 18:47:47 +00:00
Neale Ranns
32e1c010b0 IP Multicast FIB (mfib)
- IPv[46] mfib tables with support for (*,G/m), (*,G) and (S,G) exact and longest prefix match
 - Replication represented via a new replicate DPO.
 - RPF configuration and data-plane checking
 - data-plane signals sent to listening control planes.

The functions of multicast forwarding entries differ from their unicast conterparts, so we introduce a new mfib_table_t and mfib_entry_t objects. However, we re-use the fib_path_list to resolve and build the entry's output list. the fib_path_list provides the service to construct a replicate DPO for multicast.

'make tests' is added to with two new suites; TEST=mfib, this is invocation of the CLI command 'test mfib' which deals with many path add/remove, flag set/unset scenarios, TEST=ip-mcast, data-plane forwarding tests.

Updated applications to use the new MIFB functions;
  - IPv6 NS/RA.
  - DHCPv6
 unit tests for these are undated accordingly.

Change-Id: I49ec37b01f1b170335a5697541c8fd30e6d3a961
Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-01-27 19:53:46 +00:00
Dave Wallace
6f692d6e5a Fix make test scapy python patch issue, VPP-615
Change-Id: I1e6798905f0049c793224a2c880f3b2cfadcf1e7
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
2017-01-27 16:36:55 +00:00
Tibor
ed6814b57f make-test: Add numbering to chapters' titles
Change-Id: I1e2aedba85caf903dd7a721841afe240a9791cac
Signed-off-by: Tibor <tifrank@cisco.com>
2017-01-27 13:21:57 +00:00
Klement Sekera
e7c034bf63 make test: improve documentation generation
Refactor the text to work around sphinx bug to show a proper
table of contents.

Change-Id: I546656ef77a95637ad7c6bf239f26262a4f306dc
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-01-27 01:04:13 +00:00
Tibor
7ff11136b1 Add sphinx read the doc theme.
Change-Id: Iade7c42081378bf211b81ad29b2898518442d2ff
Signed-off-by: Tibor <tifrank@cisco.com>
2017-01-27 01:03:05 +00:00
Jan Gelety
3900fe53fc ipv4 vrf test doc cleaning
Change-Id: I0d3b47ce3c029d2ea01f9ff88a541affcbfd70db
Signed-off-by: Jan Gelety <jgelety@cisco.com>
2017-01-27 01:02:47 +00:00
Neale Ranns
fca0c242e4 DHCPv[46] proxy tests
Change-Id: I6aaf9c602cd515ed9d4416d286f9191d048c1a87
Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-01-26 05:14:35 -08:00
Klement Sekera
e0545ef85a make test: elegantly handle expected API failures
Allow writing simple code to expect API failure when needed:

with self.vapi.expect_negative_api_retval():
    do_api_call()  # expected to return negative retval in response

Change-Id: Id58d91d9ce38d20ad6ff7a43a6897e79ffbd23bf
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-01-25 15:57:14 +00:00
Eyal Bari
4bce290f3e test adding and removing shared mcast dst tunnels
Adds and delete 2000 multicast vxlan tunnels sharing group address
to test mcast tunnel ref count code as part of the stability stage (before starting traffic tests)

Change-Id: Ic50cedf80471e14431feb493104eff5ea7d5d429
Signed-off-by: Eyal Bari <ebari@cisco.com>
2017-01-25 15:17:18 +00:00
Matus Fabian
36532bda92 SNAT: static mappings for dhcp addressed interfaces (VPP-590)
updated API
added test

Change-Id: I3f6017ecf09b924cb320c1b5f323cd33f7a37447
Signed-off-by: Matus Fabian <matfabia@cisco.com>
2017-01-25 13:27:25 +00:00
Matus Fabian
675a69cdf6 SNAT: Multiple inside interfaces (VPP-447)
NAT only packets aimed at outside interface and in case of hairpinning

Change-Id: Ida371380fce664b9434ca5ddd2369c980ff26beb
Signed-off-by: Matus Fabian <matfabia@cisco.com>
2017-01-23 03:04:53 -08:00
Klement Sekera
7a161da36e make test: fix text output when non-interactive
Output everything to stdout instead of mixing stdout and stderr.

Change-Id: I3146760e068fda7f1ffaaf36683d5153dcda4561
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-01-17 22:02:16 +00:00
Klement Sekera
46a87adf10 BFD: IPv6 support
Change-Id: Iaa9538c7cca500c04cf2704e5bf87480543cfcdf
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-01-17 22:02:02 +00:00
Klement Sekera
72715ee4e2 make test: add checkstyle target
Change-Id: I59d3c3bc77474c96e1d6fa51811c1b13fb9a6c5b
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-01-17 18:35:21 +00:00
Matus Fabian
eea28d78a3 SNAT: IPFIX logging (VPP-445)
Change-Id: I8450217dd43a1cd9f510e40dfb22274ffc33a4c6
Signed-off-by: Matus Fabian <matfabia@cisco.com>
2017-01-14 09:44:18 +00:00
Klement Sekera
52e84f3cad make test: improve test results printing
Accomodate longer test descriptions by increasing the headings
size.

Change-Id: I51c90b8d91feaa83b78972d0802d3054f8510f36
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-01-13 07:28:52 +01:00
Matus Fabian
8bf68e858a SNAT: add API and test for NAT pool address from interface
Change-Id: I2a868f736fae8d37b438c604a9284653ea415541
Signed-off-by: Matus Fabian <matfabia@cisco.com>
2017-01-13 08:54:07 +00:00
Klement Sekera
97f6edc1f5 make test: fix capture handling special-case
Change-Id: I4fc5dce832f9a6162181967c5290e6d0daa4f9f0
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-01-12 20:32:51 +00:00
Klement Sekera
8213045f12 make test: fix typo
Change-Id: I70b4123129aab5770a45ccde4cef4452d06386b8
Signed-off-by: Klement Sekera <ksekera@cisco.com>
2017-01-12 13:07:00 +00:00