Commit Graph
593 Commits
Author SHA1 Message Date
Tobias Brunner 1ee7e10940 testing: Fix typo regarding ML-KEM in description 2026-04-15 15:01:40 +02:00
Tobias Brunner 8a6f9ba70e kernel-netlink: Don't fallback to peer address as gateway/nexthop
This doesn't really seem useful (perhaps it was before we started to
configure the outbound interface on our routes). And it can actually
cause the route installation to fail e.g. for routes over point-to-point
interfaces where we'd get "Error: Nexthop has invalid gateway" errors.

Note that we can't return NULL if we find an interface as e.g. the updown
plugin uses this method to determine the outbound interface (it ignores
the nexthop), which it passes to the script.  If we returned NULL, it
would pass "unknown" instead, which would cause the firewall rules to
mismatch.  While it seems that 0.0.0.0/:: is ignored as nexthop by the
kernel on the installed route, I still explicitly ignore such addresses
to avoid any unintended side-effects.

The automatic route installation in the ikev2/shunt-manual-prio scenario
had to be disabled on the clients.  The reason is that the route in table
220 won't have a nexthop set (the peers are directly connected), so when
trying to reach alice or venus via SSH, which matches the port-specific
bypass policies for which we don't install throw routes, the hosts will
do ARP requests for the target IPs instead of routing the packets via
moon.

Closes strongswan/strongswan#2548
2026-02-20 12:44:55 +01:00
Tobias Brunner a7c03a415e testing: Add scenarios to test ICMP forwarding 2026-02-12 16:21:37 +01:00
Tobias Brunner 5b0d506215 testing: Remove unused revocation and constraints plugins for swanctl
swanctl doesn't do any (online) certificate validation, it just parses
and or decrypts them and passes them on to the daemon.
2026-02-06 11:21:34 +01:00
Tobias Brunner 7973080969 testing: Add a reauthentication to ikev2/dhcp-static-client-id
This verifies that we don't release the lease when the old SA is
deleted during the reauthentication.
2026-02-05 17:57:07 +01:00
Tobias Brunner 1454bd7bcf testing: Make per-CPU SAs scenarios more predictable by pinning IRQs to vCPUs
This ensures that packets on sun are processed on a particular CPU and
not randomly on one, which causes expected SAs not to get created or
other weird things.
2025-12-03 11:42:54 +01:00
Tobias Brunner f88d824114 Fixed some typos, courtesy of codespell 2025-07-08 10:54:49 +02:00
Tobias Brunner 9a6aa2530e testing: Make sure ML-KEM scenarios use our ml plugin
We now support OpenSSL's implementation in the openssl plugin.  This
makes sure our plugin is used on at least one of the hosts if we ever
switch to an OpenSSL version that supports ML-KEM.

In the ikev2/rw-mlkem scenario the logic is reversed.  There the ml plugin
is preferred on moon to test the responder side (and carol for the
initiator) and dave will switch to OpenSSL if it ever provides ML-KEM.
2025-06-20 10:37:24 +02:00
Tobias Brunner dc4fef146a testing: Add ikev2/net2net-iptfs scenario 2025-05-28 16:37:47 +02:00
Tobias Brunner b7d3349000 testing: Add ikev2/per-cpu-sas-encap-transport scenario
Tests transport mode and UDP encapsulation with random source ports.
Interestingly, the responder always uses the same SA to respond (maybe
due to the cache on the policy).
2025-05-28 16:35:27 +02:00
Tobias Brunner 3b2f8cf282 testing: Add ikev2/per-cpu-sas-encap scenario
Basically the same as the one without UDP encapsulation, but here the
outbound SAs use random source ports.
2025-05-28 16:35:27 +02:00
Tobias Brunner bf34484d24 testing: Add per-CPU SA test scenario 2025-05-28 16:35:27 +02:00
Tobias Brunner 8cb5918b0c testing: Add ikev2/net2net-route-narrow scenario 2025-05-28 16:01:00 +02:00
Tobias Brunner 4249d721ec testing: Add rw-eap-id-switch scenario 2025-04-14 12:18:24 +02:00
Andreas Steffen 24a9c32a43 testing: Include ML-KEM crypto tests rw-cert scenario 2024-12-06 14:39:20 +01:00
Tobias Brunner 17bc5166d4 Fixed some typos, courtesy of codespell 2024-11-25 12:06:54 +01:00
Andreas Steffen 2c18e87b25 testing: Added ML-KEM test cases 2024-11-23 16:53:02 +01:00
Andreas Steffen 4df94b56c0 testing: Distributed openssl-ikev2 scenarios 2024-11-22 14:14:52 +01:00
Andreas Steffen f766a7ed49 testing: Migrated ikev2-algs scenarios to new default plugins 2024-11-22 14:14:52 +01:00
Andreas Steffen 2099a52618 testing: Migrated ikev2 scenarios to new default plugins 2024-11-22 14:14:52 +01:00
Andreas Steffen 1265d78cac ntru: Remove legacy NTRU key exchange method 2024-11-22 14:05:36 +01:00
Andreas Steffen 8e3a373e18 newhope: Remove legacy Newhope key exchange method 2024-11-22 14:05:36 +01:00
Andreas Steffen 4833f29b15 bliss: Remove legacy BLISS signatures 2024-11-22 14:05:36 +01:00
Tobias Brunner f3c7e5227c testing: Add ikev2/rw-cert-multi-ke scenario 2024-08-07 16:20:19 +02:00
Tobias Brunner 56b6eeb385 testing: Add ikev2/start-action-start scenario
This tests the behavior for configs with start_action=start during
reloads of the config (updates/removal).
2024-07-26 16:56:32 +02:00
Tobias Brunner c4bce2b79b testing: Enable mgf1 plugin for scenarios where FreeRADIUS uses PSS signatures
Looks like a cipher suite without DHE was selected previously.

Could be a side-effect of dc1085734f ("testing: Remove unnecessary
FreeRADIUS dh_file option as recommended in the log").
2024-06-26 14:56:22 +02:00
Tobias Brunner a9ced3ccb4 testing: Fix IP pool scenarios after changing base address
Fixes: 2b11764b70 ("mem-pool: Adjust the base address if it's the network ID")
2024-06-26 14:56:22 +02:00
Tobias Brunner 1cbcf198ab testing: Make RADIUS server enforce client identity in certificate's CN 2024-06-17 14:47:11 +02:00
Tobias Brunner dc1085734f testing: Remove unnecessary FreeRADIUS dh_file option as recommended in the log 2024-06-17 14:47:11 +02:00
Andreas Steffen 6f8275abab testing: Added RFC4806 tests 2024-03-13 15:11:00 +01:00
Tobias Brunner c10a13589e testing: Use pki --ocsp as OCSP responder
The only exception is the ikev2/ocsp-no-signer-cert scenario as the
pki command won't sign an OCSP response with a certificate that isn't
the CA certificate or marked as an OCSP signer.
2023-11-13 12:50:47 +01:00
Andreas Steffen edd3c797b0 testing: Negotiate TLS 1.3 for part of the EAP-TLS scenarios 2023-03-02 09:02:38 +01:00
Tobias Brunner bc1a5111bb testing: Add a failing client to the ikev2/rw-eap-tls-only scenario 2023-02-22 17:10:03 +01:00
Tobias Brunner cf6f56f619 Fixed some typos, courtesy of codespell 2022-12-22 19:03:37 +01:00
Tobias Brunner 5ce1c91b58 ikev2: Trigger ike_updown() event after all IKE-specific tasks ran
This makes sure the event is only triggered after the IKE_SA is fully
established and e.g. virtual IPs, additional peer addresses or
a modified reauth time (on the initiator) are assigned to it.  This was
e.g. a problem for the selinux plugin if virtual IPs are used.

We use a separate task to trigger the event that's queued before the
child-create task so the event is triggered before the child_updown()
event.  Same goes for the state change to IKE_ESTABLISHED.

A new condition is used to indicate the successful completion of all
authentication rounds, so we don't have to set the IKE_ESTABLISHED state
in the ike-auth task (it was used as condition in other tasks).

Since set_state() also sets the rekey and reauth times, this required
some minor changes in regards to how AUTH_LIFETIME notifies are handled.
2022-09-23 16:28:35 +02:00
Andreas Steffen bf3f678551 testing: Fixed two issues 2022-09-06 21:14:07 +02:00
Andreas Steffen e4cb9a59d2 testing: Fixed typo of mfg1 to mgf1 plugin 2022-08-26 12:31:33 +02:00
Tobias Brunner 3a52fc83f8 testing: Load kdf plugin in all scenarios that require it
Once we use plugin-provided prf+() these won't work otherwise.
2022-04-14 19:02:48 +02:00
Tobias Brunner 6910347d1a testing: Add DSCP scenario that uses simple labels
Instead of creating two IKE_SAs with different identities, this scenario
uses simple labels to select the correct child config.
2022-04-14 18:42:01 +02:00
Andreas Steffen 85d626e9ae testing: Modified ikev2/net2net-rfc3779 scenario 2022-01-10 21:14:11 +01:00
Andreas Steffen f0935a63ed testing: Optimized plugin use in pkcs8 scenarios 2021-10-23 11:44:15 +02:00
Andreas Steffen 9c7288d6f1 testing: Minimum required plugins for net2net-pkcs12 scenarios 2021-10-22 11:39:20 +02:00
Tobias Brunner 1ec01f10a2 testing: Replace arp with ip neigh
The net-tools package, which provides arp and other older utilities like
ifconfig, is not installed anymore on Debian bullseye.
2021-10-01 15:05:44 +02:00
Tobias Brunner ccac9c3047 testing: Allow DNS via TCP in net2net-dnscert scenario
New versions of Bind limit the maximum UDP message size to 1232 bytes,
which is the same that newer versions of libunbound propose as maximum via
EDNS in requests, so increasing the limit on the server wouldn't help.

Instead we allow DNS via TCP so the client can switch after receiving the
truncated UDP response.
2021-10-01 15:05:44 +02:00
Tobias Brunner 5b9c46b988 testing: Remove support for Debian jessie and FreeRADIUS 2 2021-10-01 15:05:44 +02:00
Tobias Brunner 23e46ea5ab ikev2: Only request reauth during IKE_AUTH if active reauth is not possible
If we can initiate the reauthentication ourselves, there is no reason to
explicitly request the peer to do so (at basically the same time).
2021-08-24 14:31:55 +02:00
Tobias Brunner f6aafb3005 Fixed some typos, courtesy of codespell
Main change is the conversion from the British cancelling/-ed to the
American canceling/-ed.
2021-06-25 11:32:29 +02:00
Andreas Steffen 4baca5ca80 testing: Fixed ikev2/farp scenario 2021-06-22 12:32:35 +02:00
Andreas Steffen eba2622587 testing: Migrate ikev2-stroke-bye scenarios to vici 2021-06-22 10:23:06 +02:00
Tobias Brunner 6d8890767c testing: Migrate ikev2/host2host-transport-nat scenario to vici
This also restores the test as it was before the referenced commit so it
again, as written in the description, demonstrates that venus is unable
to ping sun without IPsec tunnel.

Fixes: f27fb58ae0 ("testing: Update description and test evaluation of host2host-transport-nat")
2021-06-21 12:03:36 +02:00