Commit Graph

1684 Commits

Author SHA1 Message Date
Tobias Brunner 62636da4f3 testing: Enable outbound FWD policies in swanctl/manual-prio scenario 2016-09-28 17:56:43 +02:00
Andreas Steffen a9562a3f58 testing: Added swanctl/net2net-multicast scenario 2016-09-27 18:36:28 +02:00
Andreas Steffen d7e0ce2878 testing: Added ikev2/net2net-multicast scenario 2016-09-27 18:36:28 +02:00
Andreas Steffen 6b3e408ba5 Version bump to 5.5.1dr5 2016-09-22 17:36:37 +02:00
Andreas Steffen d505658038 testing: Added swanctl/net2net-sha3-rsa-cert and swanctl/rw-eap-tls-sha3-rsa scenarios 2016-09-22 17:34:31 +02:00
Andreas Steffen 40f2589abf gmp: Support of SHA-3 RSA signatures 2016-09-22 17:34:31 +02:00
Andreas Steffen e31ed9ab98 Version bump to 5.5.1dr4 2016-09-21 14:14:42 +02:00
Andreas Steffen 188b190a70 mgf1: Refactored MGF1 as an XOF 2016-09-21 06:40:52 +02:00
Tobias Brunner b69cbacdfb testing: Use curl instead of soup plugin in libipsec/rw-suite-b scenario
The soup plugin is already used in the openssl-ikev2/rw-suite-b*
scenarios.
2016-09-20 15:36:15 +02:00
Tobias Brunner 6307a18fe1 testing: Fix totals if post test checks fail 2016-09-20 15:36:14 +02:00
Tobias Brunner d8b2980aa5 testing: Log leaks and fail tests if any are detected 2016-09-20 15:36:14 +02:00
Tobias Brunner ac67aeb100 testing: Add output of iptables-save
This might be helpful to get the complete picture of the installed
rules.  `-c` is currently not used as the counters that are added in
front of every rule make the output quite hard to read and the counters
are already provided in the accompanying `iptables -v -L` output.

Fixes #2111.
2016-09-12 16:15:45 +02:00
Tobias Brunner fa36699bfa testing: List `nat` and `mangle` tables in addition to the `filter` table
This is useful in scenarios that e.g. use NAT and/or marks.

References #2111.
2016-09-12 16:15:14 +02:00
Tobias Brunner 92ccc0b412 testing: Ignore comments (lines starting with #) in pre-/eval-/posttest.dat 2016-09-09 12:19:14 +02:00
Tobias Brunner 379d94eb70 testing: Try to properly abort a test run after CTRL-C
The run is aborted after the current scenario.  Depending on which
command was interrupted it might be necessary to press CTRL-C multiple
times (e.g. if a later command depends on the interrupted one).

This should fix HTML files and get us some proper console output after
the run.
2016-08-30 16:16:42 +02:00
Tobias Brunner bdd7c42fc0 testing: Report number of tests per subdirectory in main index 2016-08-30 15:03:40 +02:00
Tobias Brunner dda06b0439 testing: Mount and serve testresults from the host
This avoids having to copy testresults, makes results of cancelled runs
browsable (runs may actually be followed live) and preserves old results
when rebuilding guest images (e.g. when using the build-strongswan script).
The number of consecutive test runs without any intermittent rebuild of the
guest images is also not limited by the image size anymore.
2016-08-29 18:11:42 +02:00
Tobias Brunner 7a8985b575 testing: Create a symlink to the testresults under a known path when starting the environment 2016-08-29 18:11:42 +02:00
Tobias Brunner cf6042453f testing: Serve images in testresults via mod_rewrite and not a symlink 2016-08-29 18:11:42 +02:00
Andreas Steffen d2577aa3c5 Version bump to 5.5.1dr2 2016-08-26 22:55:41 +02:00
Andreas Steffen ce20979ce2 testing: Virtual IPs went missing 2016-08-16 17:18:17 +02:00
Andreas Steffen 5afaf0dba2 Version bump to 5.5.1dr1 2016-08-10 18:11:53 +02:00
Andreas Steffen c1a1f9f548 testing: Added swanctl/rw-newhope-bliss scenario 2016-08-10 15:14:26 +02:00
Andreas Steffen 1e0dc2c329 testing: Add chapoly, ntru and newhope plugins to crypto and integrity tests 2016-08-10 14:34:27 +02:00
Andreas Steffen 277ef8c2fa testing: Added ikev2/rw-newhope-bliss scenario 2016-08-10 14:22:00 +02:00
Andreas Steffen 74de8c3727 Version bump to 5.5.0 2016-07-13 13:26:16 +02:00
Tobias Brunner 5e5dee36b6 testing: Remove obsolete openssl-fips recipe
This was only required when we initially started and OpenSSL was built
from sources, which was changed with b97dd59ba8 ("install FIPS-aware
OpenSSL Debian packages").
2016-07-04 12:18:51 +02:00
Tobias Brunner 7b879874d7 Revert "testing: Only load selected plugins in swanctl"
This reverts commit dee01d019b.

Thanks to 505c318701 ("leak-detective: Try to properly free
allocations after deinitialization") this is not required anymore.
2016-07-01 17:35:52 +02:00
Andreas Steffen ee2644dd3f testing: Version bump to 4.6.3 kernel and strongSwan 5.5.0 2016-06-30 16:20:10 +02:00
Tobias Brunner c3e5109c37 testing: Add ikev1/net2net-esn scenario 2016-06-29 11:16:48 +02:00
Tobias Brunner c01df20ebf testing: Ignore tests/local directory
This could be used for experimental test scenarios that should not get
tracked in the repository.
2016-06-29 10:36:10 +02:00
Tobias Brunner 5a09734c2c testing: Start charon before Apache in tnc/tnccs-20-pdp-pt-tls
The change in c423d0e8a1 ("testing: Fix race in tnc/tnccs-20-pdp-pt-tls
scenario") is not really ideal as now the vici plugin might not yet be
ready when `swanctl --load-creds` is called.  Perhaps starting charon
before Apache causes enough delay.

Once we switch to charon-systemd this isn't a problem anymore as starting the
unit will block until everything is up and ready.  Also, the individual
swanctl calls will be redundant as the default service unit calls --load-all.
But start scripts do run before charon-systemd signals that the daemon is
ready, so using these would work too then.
2016-06-21 17:24:43 +02:00
Tobias Brunner dee01d019b testing: Only load selected plugins in swanctl
The main issue is that the ldap and curl plugins, or rather the libraries
they use, initialize GnuTLS (curl, strangely, even when it is, by its own
account, linked against OpenSSL).  Some of these allocations are only freed
once the libraries are unloaded.  This means that the leak detective causes
invalid frees when swanctl is terminated and libraries are unloaded after the
leak detective is already deinitialized.
2016-06-20 18:23:45 +02:00
Tobias Brunner c423d0e8a1 testing: Fix race in tnc/tnccs-20-pdp-pt-tls scenario
aacf84d837 ("testing: Add expect-connection calls for all tests and
hosts") removed the expect-connection call for the non-existing aaa
connection.  However, because the credentials were loaded asynchronously
via start-script the clients might have been connecting when the secrets
were not yet loaded.  As `swanctl --load-creds` is a synchronous call
this change avoids that issue without having to add a sleep or failing
expect-connection call.
2016-06-17 18:43:36 +02:00
Tobias Brunner 44e83f76f3 testing: Use TLS 1.2 in RADIUS test cases
This took a while as in the OpenSSL package shipped with Debian and on which
our FIPS-enabled package is based, the function SSL_export_keying_material(),
which is used by FreeRADIUS to derive the MSK, did not use the correct digest
to calculate the result when TLS 1.2 was used.  This caused IKE to fail with
"verification of AUTH payload with EAP MSK failed".  The fix was only
backported to jessie recently.
2016-06-17 15:53:12 +02:00
Tobias Brunner 545e529190 testing: Update FreeRADIUS to 2.2.8
While this is not the latest 2.x release it is the latest in /old.

Upgrading to 3.0 might be possible, not sure if the TNC-FHH patches could
be easily updated, though.  Upgrading to 3.1 will definitely not be possible
directly as that version removes the EAP-TNC module.  So we'd first have to
get rid of the TNC-FHH stuff.
2016-06-17 15:53:12 +02:00
Tobias Brunner 67b9e151fa testing: Fix firewall rule on alice in tnc/tnccs-20-pdp-pt-tls scenario 2016-06-17 10:22:03 +02:00
Tobias Brunner 1f98c38283 testing: Build hostapd from sources
There is a bug (fix at [1]) in hostapd 2.1-2.3 that let it crash when used
with the wired driver.  The package in jessie (and sid) is affected, so we
build it from sources (same, older, version as wpa_supplicant).

[1] http://w1.fi/cgit/hostap/commit/?id=e9b783d58c23a7bb50b2f25bce7157f1f3
2016-06-16 14:36:15 +02:00
Tobias Brunner 63d9370249 testing: Update download URL for wpa_supplicant 2016-06-16 14:36:15 +02:00
Tobias Brunner 63acd803f0 testing: Wait for packets to be processed by tcpdump
Sometimes tcpdump fails to process all packets during the short running
time of a scenario:

0 packets captured
18 packets received by filter
0 packets dropped by kernel

So 18 packets were captured by libpcap but tcpdump did not yet process
and print them.

This tries to use --immediate-mode if supported by tcpdump (the one
currently in jessie or wheezy does not, but the one in jessie-backports
does), which disables the buffering in libpcap.

However, even with immediate mode there are cases where it takes a while
longer for all packets to get processed.  And without it we also need a
workaround (even though the version in wheezy actually works fine).
That's why there now is a loop checking for differences in captured vs.
received packets.  There are actually cases where these numbers are not
equal but we still captured all packets we're interested in, so we abort
after 1s of retrying.  But sometimes it could still happen that packets
we expected got lost somewhere ("packets dropped by kernel" is not
always 0 either).
2016-06-16 14:36:15 +02:00
Tobias Brunner eb25b1a73d testing: Fix expect-connection for tkm tests
We don't use swanctl there but there is no load statement either.
2016-06-16 14:35:26 +02:00
Tobias Brunner aacf84d837 testing: Add expect-connection calls for all tests and hosts
There are some exceptions (e.g. those that use auto=start or p2pnat).
2016-06-16 14:35:18 +02:00
Tobias Brunner 8f56bbc82b testing: Update test scenarios for Debian jessie
The main difference is that ping now reports icmp_seq instead of
icmp_req, so we match for icmp_.eq, which works with both releases.

tcpdump now also reports port 4500 as ipsec-nat-t.
2016-06-16 14:04:11 +02:00
Tobias Brunner b71104a3df testing: Fix posttest.dat for ikev2/rw-dnssec scenario 2016-06-16 14:01:47 +02:00
Tobias Brunner 71424a2f85 testing: Make sure tcpdump is actually terminated before analyzing/collecting logs 2016-06-16 14:01:47 +02:00
Tobias Brunner 654343d942 testing: Correctly dis-/enable services with systemd 2016-06-16 14:01:47 +02:00
Tobias Brunner f565f954a7 testing: Install packages like the FIPS-enabled OpenSSL from a custom apt repo 2016-06-16 14:01:47 +02:00
Tobias Brunner 257e5db0d0 testing: Update base image to Debian jessie
Several packages got renamed/updated, libgcrypt was apparently installed
by default previously.

Since most libraries changed we have to completely rebuild all the tools
installed in the root image.  We currently don't provide a clean target in
the recipes, and even if we did we'd have to track which base image we
last built for.  It's easier to just use a different build directory for
each base image, at the cost of some additional disk space (if not manually
cleaned).  However, that's also the case when updating kernel or
software versions.
2016-06-15 17:58:24 +02:00
Tobias Brunner 0889628957 testing: Update 4.x kernel configs to be compatible with Debian 8/systemd 2016-06-15 16:24:44 +02:00
Tobias Brunner 5c71cbfa94 testing: Add root to fstab
This seems to be required for systemd to remount it.
2016-06-15 16:24:44 +02:00
Tobias Brunner 1c616eccae testing: Update Apache config for newer Debian releases
It is still compatible with the current release as the config in
sites-available will be ignored, while conf-enabled does not exist and
is not included in the main config.
2016-06-15 16:24:44 +02:00
Tobias Brunner 2b0a6811ab testing: Explicitly enable RC4 in SSH server config
Newer OpenSSH versions disable this by default because it's unsafe.
Since this is not relevant for our use case we enable it due to its
speed.
2016-06-15 16:24:44 +02:00
Tobias Brunner 6466546f81 testing: Add script to chroot into an image
If changes are made to the base or root image the images depending on
these have to be rebuilt.
2016-06-15 16:24:43 +02:00
Tobias Brunner cac9051eed testing: Add a patch to tnc-fhh that avoids building the tncsim package
This sub-package does not build on Debian jessie.
2016-06-15 16:24:43 +02:00
Tobias Brunner c857621e70 testing: Don't attempt to stop services when building base image
Unlike `apt-get install` in a chroot debootstrap does not seem to start
the services but stopping them might cause problems if they were running
outside the chroot.
2016-06-15 16:24:43 +02:00
Tobias Brunner 796c36ade1 testing: Fix scenarios that check /etc/resolv.conf 2016-06-13 16:18:38 +02:00
Andreas Steffen 78adb5a7b1 testing: Changed gcrypt-ikev1 scenarios to swanctl 2016-05-15 19:02:57 +02:00
Andreas Steffen 141ac4df8f testing: wait until connections are loaded 2016-05-15 19:02:57 +02:00
Andreas Steffen b9522f9d64 swanctl: Do not display rekey times for shunts 2016-05-05 14:53:22 +02:00
Andreas Steffen ff4e01dab5 testing: Use reauthentication and set CHILD_SA rekey time, bytes and packets limits 2016-05-04 18:13:52 +02:00
Andreas Steffen 87381a55a9 testing: uses xauth_id in swanctl/xauth-rsa scenario 2016-05-04 18:13:52 +02:00
Andreas Steffen 278497f2ba testing: Use absolute path of imv_policy_manager 2016-04-26 17:15:37 +02:00
Andreas Steffen b85422b90c testing: -D and -u options in sfdisk are not supported any more 2016-04-26 17:15:37 +02:00
Andreas Steffen 029d3a0ce6 testing: updated testing.conf 2016-04-24 13:36:31 +02:00
Andreas Steffen 0ff486f507 testing: Added swanctl/rw-multi-ciphers-ikev1 scenario 2016-04-12 18:50:58 +02:00
Andreas Steffen d3edc8aa0f testing: Added swanctl/manual_prio scenario 2016-04-09 16:51:02 +02:00
Tobias Brunner 638b4638e3 testing: Add swanctl/net2net-gw scenario 2016-04-09 16:51:00 +02:00
Tobias Brunner ea3a4d3f72 testing: List conntrack table on sun in ikev2/host2host-transport-connmark scenario 2016-04-06 14:01:18 +02:00
Tobias Brunner aa65b8c147 testing: Version bump to 5.4.0
References #1382.
2016-04-06 11:17:40 +02:00
Tobias Brunner 76397efa21 testing: Disable leak detective when generating CRLs
GnuTLS, which can get loaded by the curl plugin, does not properly cleanup
some allocated memory when deinitializing.  This causes invalid frees if
leak detective is active.  Other invalid frees are related to time
conversions (tzset).

References #1382.
2016-04-06 11:16:59 +02:00
Tobias Brunner a9f9598ed0 testing: Updated updown scripts in libipsec scenarios to latest version 2016-03-23 14:13:07 +01:00
Andreas Steffen 90ef7e8af6 Updated swanctl/rw-psk-ikev1 scenario 2016-03-10 13:59:37 +01:00
Tobias Brunner dc57c1b817 testing: Add ikev2/reauth-mbb-revoked scenario 2016-03-10 11:07:15 +01:00
Tobias Brunner d163aa5eaf testing: Generate a CRL that has moon's actual certificate revoked 2016-03-10 11:07:15 +01:00
Andreas Steffen c2523355a4 testing: Added swanctl/mult-auth-rsa-eap-sim-id scenario 2016-03-06 19:09:03 +01:00
Andreas Steffen 70ff382e41 testing: Added swanctl/xauth-rsa scenario 2016-03-06 12:28:55 +01:00
Andreas Steffen 07b0eac4b1 testing: attr-sql is a charon plugin 2016-03-05 15:53:22 +01:00
Andreas Steffen 26d2011b14 testing: Added swanctl/rw-psk-ikev1 scenario 2016-03-05 13:50:41 +01:00
Andreas Steffen 1989c7a381 testing: Include IKE port information in evaltests 2016-03-05 13:44:06 +01:00
Tobias Brunner f80e910cce testing: Add ikev2/redirect-active scenario 2016-03-04 16:03:00 +01:00
Andreas Steffen ba919f393d testing: Added swanctl/protoport-range scenario 2016-03-04 09:52:34 +01:00
Tobias Brunner 28649f6d91 libhydra: Remove empty unused library 2016-03-03 17:36:11 +01:00
Andreas Steffen efefa0c6a1 testing: Added swanctl/shunt-policies-nat-rw 2016-02-28 22:25:50 +01:00
Andreas Steffen 13891e2a4f testing: Some minor fixes in test scenarios 2016-02-28 22:25:21 +01:00
Andreas Steffen 68c9f0bb80 testing: Added swanctl/protoport-dual scenario 2016-02-28 14:33:48 +01:00
Andreas Steffen ddf1fc7692 testing: converted af-alg scenarios to swanctl 2016-02-26 13:31:36 +01:00
Tobias Brunner 4625113b1a testing: Use absolute path to the _updown script in SQL scenarios
/usr/local/sbin is not included in PATH set by the charon init script and
since the ipsec script is obsolete when using swanctl it makes sense to
change this anyway.
2016-02-17 12:00:20 +01:00
Andreas Steffen 963b080810 testing: Increased ping interval in ikev2/trap-any scenario 2016-02-16 18:21:19 +01:00
Andreas Steffen 726a45b2f2 Corrected the description of the swanctl/dhcp-dynamic scenario 2016-02-16 18:17:17 +01:00
Andreas Steffen 4d83c5b4a6 Fix of the mutual TNC measurement use case
If the IKEv2 initiator acting as a TNC server receives invalid TNC measurements
from the IKEv2 responder acting as a TNC clienti, the exchange of PB-TNC batches
is continued until the IKEv2 responder acting as a TNC server has also finished
its TNC measurements.

In the past if these measurements in the other direction were correct
the IKEv2 responder acting as EAP server declared the IKEv2 EAP authentication
successful and the IPsec connection was established even though the TNC
measurement verification on the EAP peer side failed.

The fix adds an "allow" group membership on each endpoint if the corresponding
TNC measurements of the peer are successful. By requiring a "allow" group
membership in the IKEv2 connection definition the IPsec connection succeeds
only if the TNC measurements on both sides are valid.
2016-02-16 18:00:27 +01:00
Andreas Steffen ac134b470a testing: Added swanctl/dhcp-dynamic scenario 2016-02-03 12:10:59 +01:00
Thomas Egerer beb4a07ea8 ikev1: Log successful authentication with signature scheme
Output is now identical to that of the IKEv2 pubkey authenticator.

Signed-off-by: Thomas Egerer <thomas.egerer@secunet.com>
2016-02-01 15:58:53 +01:00
Tobias Brunner 4cfcbe97a4 testing: Don't attempt to start the daemon twice in ha/active-passive scenario 2016-02-01 10:51:12 +01:00
Andreas Steffen 67a38ac6f1 testing: Added swanctl/config-payload scenario 2016-01-14 06:31:28 +01:00
Andreas Steffen e7b5171e43 testing: Use include statement in swanctl/rw-pubkey-keyid scenario 2016-01-14 01:44:17 +01:00
Andreas Steffen 2aa2b17d41 testing: swanctl/rw-pubkey-anon uses anonymous public keys in remote access scenario 2016-01-09 07:23:30 +01:00
Andreas Steffen b83cef2412 testing: added swanctl scenarios net2net-pubkey, rw-pubkey-keyid and rw-dnssec 2016-01-09 07:23:30 +01:00
Andreas Steffen bffbf2f5fd testing: Fixed description of swanctl/frags-iv4 scenario 2016-01-09 00:17:31 +01:00
Andreas Steffen 9db530493f testing: Change sql scenarios to swanctl 2016-01-03 06:28:48 +01:00
Tobias Brunner 1a79525559 testing: Fix some IKEv1 scenarios after listing DH groups for CHILD_SAs 2015-12-21 12:14:12 +01:00
Andreas Steffen 490ba67682 testing: Fixed description in swanctl/rw-ntru-bliss scenario 2015-12-18 15:24:59 +01:00
Andreas Steffen 9463350943 testing: swanctl is enabled by default 2015-12-18 15:22:29 +01:00
Andreas Steffen 76cbf1df34 testing: Added swanctl/rw-ntru-bliss scenario 2015-12-17 17:49:48 +01:00
Andreas Steffen 5e2b740a00 128 bit default security strength requires 3072 bit prime DH group 2015-12-14 10:39:40 +01:00
Andreas Steffen 36b6d400d2 testing: swanctl/rw-cert scenario tests password-protected RSA key 2015-12-12 17:12:44 +01:00
Andreas Steffen 4f7f2538c4 Upgraded IKE and ESP proposals in swanctl scenarios to consistent 128 bit security 2015-12-12 15:54:48 +01:00
Andreas Steffen fad851e2d3 Use VICI 2.0 protocol version for certificate queries 2015-12-11 18:26:54 +01:00
Andreas Steffen 6789d79d46 testing: Added swanctl --list-algs output 2015-12-11 18:26:54 +01:00
Andreas Steffen 6aa7703122 testing: Converted tnc scenarios to swanctl 2015-12-11 18:26:54 +01:00
Tobias Brunner 74270c8c86 vici: Don't report memory usage via leak-detective
This slowed down the `swanctl --stats` calls in the test scenarios
significantly, with not much added value.
2015-12-11 18:26:53 +01:00
Tobias Brunner ae37090e65 testing: Use expect-connection in swanctl scenarios
Only in net2net-start do we have to use `sleep` to ensure the SA is
up when the tests are running.
2015-12-11 18:26:53 +01:00
Tobias Brunner b77e25c381 testing: The expect-connection helper may use swanctl to check for connections
Depending on the plugin configuration in the test scenario either
`ipsec statusall` or `swanctl --list-conns` is used to check for a named
connection.
2015-12-11 18:26:53 +01:00
Andreas Steffen cbc43f1b43 testing: Some more timing fixes 2015-12-01 14:51:23 +01:00
Andreas Steffen dddb32329c testing: Updated expired mars.strongswan.org certificate 2015-11-26 09:55:28 +01:00
Andreas Steffen 1c1f713431 testing: Error messages of curl plugin have changed 2015-11-13 14:02:45 +01:00
Andreas Steffen c4b9b7ef2c testing: Fixed another timing issue 2015-11-13 14:02:06 +01:00
Andreas Steffen 019c7c2310 testing: Check for leases in swanctl/ip-pool scenario 2015-11-11 08:43:43 +01:00
Andreas Steffen 946bc3a3f5 testing: Fixed some more timing issues 2015-11-10 16:54:38 +01:00
Tobias Brunner 10051b01e9 testing: Reduce runtime of all tests that use SQLite databases by storing them in ramfs 2015-11-09 15:18:39 +01:00
Tobias Brunner 3102da20a7 testing: tnc/tnccs-20-hcd-eap scenario does not use SWID IMV/strongTNC 2015-11-09 15:18:38 +01:00
Tobias Brunner e873cb5a28 testing: Add test config to create and remove a directory for DBs stored in ramfs 2015-11-09 15:18:38 +01:00
Tobias Brunner 10fa70ee5c testing: Improve runtime of TNC tests by storing the SQLite DB in ramfs
This saves about 50%-70% of the time needed for scenarios that use a DB.
2015-11-09 15:18:38 +01:00
Tobias Brunner f24ec20ebb testing: Fix test constraints in ikev2/rw-ntru-bliss scenario
Changed with a88d958933 ("Explicitly mention SHA2 algorithm in BLISS
OIDs and signature schemes").
2015-11-09 15:18:38 +01:00
Andreas Steffen 529357f09a testing: Use sha3 plugin in ikev2/rw-cert scenario 2015-11-09 15:18:38 +01:00
Tobias Brunner bcad0f761f testing: Report the actual strongSwan and kernel versions 2015-11-09 15:18:37 +01:00
Tobias Brunner 5a919312b3 testing: Record strongSwan version when building from tarball 2015-11-09 15:18:37 +01:00
Tobias Brunner aee35392d1 testing: Record strongSwan version when building from source tree 2015-11-09 15:18:37 +01:00
Tobias Brunner d4908c06c1 testing: Report time required for all scenarios on test overview page 2015-11-09 15:18:37 +01:00
Tobias Brunner f7234e5e9f testing: Remove old SWID tags when building from repository
This fixes the TNC-PDP scenarios.
2015-11-09 15:18:36 +01:00
Tobias Brunner e22a663129 testing: Don't log anything to the console if auth.log or daemon.log do not exist 2015-11-09 15:18:36 +01:00
Tobias Brunner 12f08e07e1 testing: Simplify fetching of swanctl --list-* output 2015-11-09 15:18:36 +01:00
Tobias Brunner bde9fb6fa1 testing: Don't run redundant crypto tests in sql/rw-cert scenario
They run in all other rw-cert scenarios but in the SQL version there is
no change in the loaded crypto plugins.
2015-11-09 15:18:36 +01:00
Tobias Brunner 1091b3a636 testing: Fix CRL URIs in ipv6/net2net-ip4-in-ip6-ikev* scenarios 2015-11-09 15:18:36 +01:00
Tobias Brunner bb66b4d56b testing: Speed up OCSP scenarios
Don't make clients wait for the TCP connections to timeout by dropping
packets.  By rejecting them the OCSP requests fail immediately.
2015-11-09 15:18:35 +01:00
Tobias Brunner 0ee4a333a8 testing: Speed up ifdown calls in ikev2/mobike scenarios
ifdown calls bind's rndc, which tries to access TCP port 953 on lo.
If these packets are dropped by the firewall we have to wait for the TCP
connections to time out, which takes quite a while.
2015-11-09 15:18:35 +01:00
Tobias Brunner cbaafa03c7 testing: Avoid delays with ping by using -W and -i options
With -W we reduce timeouts when we don't expect a response.  With -i the
interval between pings is reduced (mostly in case of auto=route where
the first ping yields no reply).
2015-11-09 15:18:35 +01:00
Tobias Brunner f519acd42f testing: Remove nearly all sleep calls from pretest and posttest scripts
By consistently using the `expect-connection` helper we can avoid pretty
much all previously needed calls to sleep.
2015-11-09 15:18:35 +01:00
Tobias Brunner f36b6d49af testing: Adapt tests to retransmission settings and reduce DPD delay/timeout 2015-11-09 15:18:34 +01:00
Tobias Brunner 8713e32435 testing: Only send two retransmits after 1 second each to fail negative tests earlier 2015-11-09 15:18:34 +01:00
Tobias Brunner 9a0871ab94 testing: Add a base strongswan.conf file used by all hosts in all scenarios
We will use this to set some defaults (e.g. timeouts to make testing
negative tests quicker).  We don't want these settings to show up in the
configs of the actual scenarios though.
2015-11-09 15:18:34 +01:00
Tobias Brunner 17816515d2 testing: Add libipsec/net2net-null scenario 2015-11-09 11:09:48 +01:00
Andreas Steffen a98360a64c testing: BLISS CA uses SHA-3 in its CRL 2015-11-03 21:35:09 +01:00
Tobias Brunner 92ef3c2f21 testing: Update tkm to version 0.1.3
Adds XFRM state/policy flush when terminating which caused tests to fail
due to the check added with 9086f060d3 ("testing: Let test scenarios
fail if IPsec SAs or policies are not removed").
2015-10-30 11:19:44 +01:00
Tobias Brunner c6aa606a65 testing: Actually send an uncompressed packet in the ipv6/rw-compress-ikev2 scenario
The default of 56 bytes already exceeds the threshold of 90 bytes (8 bytes
ICMP + 40 bytes IPv6 = 104 bytes).  By reducing the size we make sure the
packet is not compressed (40 + 8 + 40 = 88).

This also fixes a strange failure of this scenario due to the recently
added post-test `ip xfrm state` check.  The kernel stores a reference to
the used SAs on the inbound skbuffs and since these are garbage collected
it could take a while until all references to an SA disappear and the SA
is finally destroyed.  But while SAs might not get destroyed immediately
when we delete them, they are actually marked as dead and therefore won't
show up in `ip xfrm state`.  However, that's not the case for the tunnel
SAs the kernel attaches to IPComp SAs, which we don't explicitly delete,
and which aren't modified by the kernel until the IPComp SA is destroyed.
So what happened when the last ping unintentionally got compressed is that
the skbuff had a reference to the IPComp SA and therefore the tunnel SA.
This skbuff often was destroyed after the `ip xfrm state` check ran and
because the tunnel SA would still get reported the test case failed.
2015-10-06 15:48:55 +02:00
Andreas Steffen 2b5c543051 testing: added ikev2/alg-chacha20poly1305 scenario 2015-09-01 17:30:15 +02:00
Andreas Steffen 57eb3b2b25 testing: update to Linux 4.2 kernel 2015-09-01 17:29:30 +02:00
Tobias Brunner e9ea7e6fb7 testing: Updated environment variable documentation in updown scripts 2015-08-31 11:00:05 +02:00
Andreas Steffen cdb61c3e88 Added some spaces in swanctl.conf 2015-08-25 15:10:13 +02:00
Tobias Brunner 9086f060d3 testing: Let test scenarios fail if IPsec SAs or policies are not removed
The IKE daemon should delete all installed SAs and policies when
everything works properly, so we fail the test if that's not the case.
2015-08-21 18:27:06 +02:00
Tobias Brunner c91682d1b8 testing: Flush state and policies before every scenario
Similar to conntrack we make sure we are working on a clean slate.
2015-08-21 18:27:06 +02:00
Tobias Brunner 8923621280 testing: Fix typo in p2pnat/behind-same-nat scenario 2015-08-21 17:48:37 +02:00
Tobias Brunner efb4b9440a testing: Add missing sim_files file to ikev2/rw-eap-sim-radius scenario 2015-08-21 11:37:23 +02:00
Tobias Brunner 161d75f403 testing: alice is RADIUS server in the ikev2/rw-eap-sim-radius scenario 2015-08-21 11:17:25 +02:00
Tobias Brunner 18943c1f1b testing: Print triplets.dat files of clients in EAP-SIM scenarios
References #1078.
2015-08-21 11:16:56 +02:00
Tobias Brunner bb1d9e454d testing: Add ikev2/trap-any scenario 2015-08-19 11:34:25 +02:00
Andreas Steffen 5f60c55919 Extend HCD attribute data for tnc/tnccs-20-hcd-eap scenario 2015-08-18 21:25:39 +02:00
Andreas Steffen b19ef52d51 Added reason string support to HCD IMV 2015-08-18 21:25:39 +02:00
Andreas Steffen 627e4b9659 Fixed patches format delimited by CR/LF 2015-08-18 21:25:39 +02:00
Andreas Steffen ac28daac38 testing: Added tnc/tnccs-20-hcd-eap scenario 2015-08-18 21:25:39 +02:00
Andreas Steffen ebed384887 testing: enable HCD IMC and IMV 2015-08-18 21:25:38 +02:00
Andreas Steffen 626b2e85f0 testing: Update AAA certificate on Freeradius as well 2015-08-05 10:01:21 +02:00
Andreas Steffen 9b1eaf083f testing: Updated expired AAA server certificate 2015-08-04 21:50:01 +02:00
Tobias Brunner 008a9ad12c testing: Don't run do-tests when hosts are not running
running_any is satisfied if at least one host is running.  We could
easily add a running_all() helper to check if all hosts are running if
it turns out that's not strong enough.
2015-08-03 13:34:05 +02:00
Tobias Brunner 50dd7de226 testing: Suppress errors when checking for running hosts
If libvirt is not running virsh can't connect to it and will complain that
the socket does not exist.
2015-08-03 12:54:09 +02:00
Andreas Steffen 493ad293b7 testing: Adapted ha/both-active scenario to new jhash values 2015-07-31 14:43:40 +02:00
Tobias Brunner 1f406f3e6e testing: Fix initial kernel build
The directory does not exist yet if the kernel was never built.

Fixes: a4a13d0be2 ("testing: Extract and patch each kernel version only once")
2015-07-31 12:34:44 +02:00
Andreas Steffen fbcac07043 testing: Regenerated BLISS certificates due to oracle changes 2015-07-27 22:09:08 +02:00
Andreas Steffen aaeb524cea testing: Updated loop ca certificates 2015-07-22 17:11:00 +02:00
Andreas Steffen 450c6e8dd9 testing: Added swanctl --list-authorities output to do-tests 2015-07-22 13:27:08 +02:00
Andreas Steffen 73cbd5c7f8 testing: Updated all swanctl scenarios and added some new ones 2015-07-22 13:27:08 +02:00
Andreas Steffen db69295d2e tests: Introduced IPV6 flag in tests.conf 2015-07-21 23:17:14 +02:00
Andreas Steffen 6b265c5e5c tests: Introduced SWANCTL flag in test.conf 2015-07-21 23:17:14 +02:00
Andreas Steffen 3d9bfb607c tests: fixed evaltest of swanctl/rw-cert scenario 2015-07-21 23:17:13 +02:00
Andreas Steffen f335e2f848 tests: fixed description of swanctl ip-pool scenarios 2015-07-21 23:17:13 +02:00
Tobias Brunner 170e8d141c testing: Do not attempt to start the test environment if hosts are still running 2015-07-15 16:53:37 +02:00
Martin Willi 918dfce551 testing: Enable AESNI/PCLMULQD in moon/sun guests, if supported 2015-07-12 13:54:08 +02:00
Martin Willi 2a75c6e487 testing: Do not overwrite kernel configuration if it already exists
This allows us to do changes to the kernel configuration using menuconfig
and friends, and update the kernel with make-testing.
2015-07-12 13:54:08 +02:00
Martin Willi a4a13d0be2 testing: Extract and patch each kernel version only once
This allows us to do modifications to the kernel tree and rebuild that kernel
using make-testing. We can even have a git kernel tree in a directory to
do kernel development.
2015-07-12 13:54:08 +02:00
Martin Willi 6f913def3c testing: Build with --enable-chapoly 2015-07-12 13:54:08 +02:00
Andreas Steffen b8399a2edc testing: use a decent PSK 2015-05-30 16:56:41 +02:00
Andreas Steffen 1047d44b57 testing: Added ha/active-passive scenario 2015-05-30 16:48:17 +02:00
Tobias Brunner 13497e6cc1 testing: Include iperf and htop in base image 2015-05-22 13:30:10 +02:00
Tobias Brunner 682aab205e testing: Don't check parent dir (and subdirs) when downloading OpenSSL packages 2015-05-21 09:32:37 +02:00
Tobias Brunner c077642cbd testing: Fix kernel download URL for kernel versions != 4.x 2015-05-19 17:00:06 +02:00
Tobias Brunner 966efbc10d testing: Fix URL to TNC@FHH project in scenario descriptions 2015-05-05 11:48:56 +02:00
Reto Buerki 41e9a261ac testing: Update TKM assert strings 2015-05-05 10:55:14 +02:00
Reto Buerki 3ff0edd804 testing: Update alog to version 0.3.1 2015-05-05 10:55:14 +02:00
Reto Buerki 2fc53e76f8 testing: Update tkm to version 0.1.2 2015-05-05 10:55:14 +02:00
Reto Buerki 3c13ff0a97 testing: Update tkm-rpc to version 0.2 2015-05-05 10:55:14 +02:00
Andreas Steffen 362e87e3e0 testing: Updated carol's certificate from research CA and dave's certificate from sales CA 2015-04-26 16:52:06 +02:00
Andreas Steffen d04e47a9eb testing: Wait for DH crypto tests to complete 2015-04-26 11:51:49 +02:00
Andreas Steffen 79b5a33c11 imv_policy_manager: Added capability to execute an allow or block shell command string 2015-04-26 10:55:24 +02:00
Andreas Steffen ce354443bf testing: Migration of KVM framework to Linux 4.x kernel 2015-04-25 18:05:00 +02:00
Andreas Steffen 883c11caa0 Added tnc/tnccs-20-fail-init and tnc/tnccs-20-fail-resp scenarios 2015-03-27 20:56:44 +01:00
Andreas Steffen 193e057509 Added configurations for 3.18 and 3.19 KMV guest kernels 2015-03-27 20:56:44 +01:00
Andreas Steffen 85aa509e84 Added tnc/tnccs-20-pt-tls scenario 2015-03-27 20:56:43 +01:00
Andreas Steffen be04f90815 testing: added tnc/tnccs-20-mutual scenario 2015-03-23 23:01:13 +01:00
Tobias Brunner 3d964213f5 testing: Remove obsolete leftnexthop option from configs 2015-03-12 15:51:25 +01:00
Martin Willi 2b0f34a2ef testing: Don't check for exact IKEv1 fragment size
Similar to 7a9c0d51, the exact packet size depends on many factors we don't
want to consider in this test case.
2015-03-10 10:21:16 +01:00
Martin Willi 58c3e09918 testing: Fix active/passive role description in ha/both-active test case 2015-03-10 10:02:21 +01:00