aboutsummaryrefslogtreecommitdiffstats
path: root/testing/tests/tnc
diff options
context:
space:
mode:
authorTobias Brunner <tobias@strongswan.org>2016-06-17 11:18:25 +0200
committerTobias Brunner <tobias@strongswan.org>2016-06-17 18:43:36 +0200
commitc423d0e8a124044650842ddb66d88f40f79585d4 (patch)
tree0cdaa5af6c5f9b399aa1f1f0fc63c99320c10b7e /testing/tests/tnc
parent941ac92b95ecf7bbfb39ff96b9b252fcc2f69d0a (diff)
downloadstrongswan-c423d0e8a124044650842ddb66d88f40f79585d4.tar.bz2
strongswan-c423d0e8a124044650842ddb66d88f40f79585d4.tar.xz
testing: Fix race in tnc/tnccs-20-pdp-pt-tls scenario
aacf84d837e7 ("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.
Diffstat (limited to 'testing/tests/tnc')
-rw-r--r--testing/tests/tnc/tnccs-20-pdp-pt-tls/hosts/alice/etc/strongswan.conf3
-rw-r--r--testing/tests/tnc/tnccs-20-pdp-pt-tls/pretest.dat1
2 files changed, 1 insertions, 3 deletions
diff --git a/testing/tests/tnc/tnccs-20-pdp-pt-tls/hosts/alice/etc/strongswan.conf b/testing/tests/tnc/tnccs-20-pdp-pt-tls/hosts/alice/etc/strongswan.conf
index 8c6766616..b08a85bb4 100644
--- a/testing/tests/tnc/tnccs-20-pdp-pt-tls/hosts/alice/etc/strongswan.conf
+++ b/testing/tests/tnc/tnccs-20-pdp-pt-tls/hosts/alice/etc/strongswan.conf
@@ -3,9 +3,6 @@
charon {
load = random nonce pem pkcs1 x509 openssl revocation constraints curl vici socket-default kernel-netlink tnc-pdp tnc-imv tnc-tnccs tnccs-20 sqlite
- start-scripts {
- creds = /usr/local/sbin/swanctl --load-creds
- }
syslog {
auth {
default = 0
diff --git a/testing/tests/tnc/tnccs-20-pdp-pt-tls/pretest.dat b/testing/tests/tnc/tnccs-20-pdp-pt-tls/pretest.dat
index d64467c01..918dd5383 100644
--- a/testing/tests/tnc/tnccs-20-pdp-pt-tls/pretest.dat
+++ b/testing/tests/tnc/tnccs-20-pdp-pt-tls/pretest.dat
@@ -15,6 +15,7 @@ alice::rm /etc/swanctl/x509/aliceCert.pem
alice::rm /etc/swanctl/rsa/aliceKey.pem
alice::service apache2 start
alice::service charon start
+alice::swanctl --load-creds
winnetou::ip route add 10.1.0.0/16 via 192.168.0.1
dave::ip route add 10.1.0.0/16 via 192.168.0.1
dave::cat /etc/pts/options