/testing/guestbin/swan-prep
west #
 setenforce 1
west #
 echo '@psk-west @psk-east: PSK "ThisIsHereToMisMatchABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890"' >> /etc/ipsec.secrets
west #
 echo ': PSK "ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890"' >> /etc/ipsec.secrets
west #
 ipsec start
Redirecting to: [initsystem]
west #
 ../../guestbin/wait-until-pluto-started
west #
 ipsec auto --add ikev1-failtest
"ikev1-failtest": added IKEv1 connection
west #
 ipsec auto --add ikev1-aggr-failtest
"ikev1-aggr-failtest": added IKEv1 connection
west #
 ipsec whack --impair revival
west #
 echo "initdone"
initdone
west #
 # IKEv1 fail tests
west #
 ipsec auto --up ikev1-failtest # sanitze-retransmits
"ikev1-failtest" #1: initiating IKEv1 Main Mode connection
"ikev1-failtest" #1: sent Main Mode request
"ikev1-failtest" #1: ignoring informational payload NO_PROPOSAL_CHOSEN, msgid=00000000, length=12
"ikev1-failtest" #1: received and ignored notification payload: NO_PROPOSAL_CHOSEN
"ikev1-failtest" #1: STATE_MAIN_I1: retransmission; will wait 0.5 seconds for response
"ikev1-failtest" #1: ignoring informational payload NO_PROPOSAL_CHOSEN, msgid=00000000, length=12
"ikev1-failtest" #1: received and ignored notification payload: NO_PROPOSAL_CHOSEN
"ikev1-failtest" #1: STATE_MAIN_I1: retransmission; will wait 1 seconds for response
"ikev1-failtest" #1: ignoring informational payload NO_PROPOSAL_CHOSEN, msgid=00000000, length=12
"ikev1-failtest" #1: received and ignored notification payload: NO_PROPOSAL_CHOSEN
"ikev1-failtest" #1: STATE_MAIN_I1: 2 second timeout exceeded after 2 retransmits.  No response (or no acceptable response) to our first IKEv1 message
"ikev1-failtest" #1: connection is supposed to remain up; revival attempt 1 scheduled in 0 seconds
"ikev1-failtest" #1: IMPAIR: revival: skip scheduling revival event
"ikev1-failtest" #1: deleting ISAKMP SA (MAIN_I1) and NOT sending notification
west #
 ipsec auto --delete ikev1-failtest
west #
 ipsec auto --up ikev1-aggr-failtest  # sanitize-retransmits
"ikev1-aggr-failtest" #2: initiating IKEv1 Aggressive Mode connection
"ikev1-aggr-failtest" #2: sent Aggressive Mode request
"ikev1-aggr-failtest" #2: Peer ID is ID_FQDN: '@east-v1'
"ikev1-aggr-failtest" #2: authentication failed: using RSA with SHA1 for '@east-v1' tried preloaded: *000000000
"ikev1-aggr-failtest" #2: sending notification INVALID_KEY_INFORMATION to 192.1.2.23:500
"ikev1-aggr-failtest" #2: connection is supposed to remain up; revival attempt 1 scheduled in 0 seconds
"ikev1-aggr-failtest" #2: IMPAIR: revival: skip scheduling revival event
"ikev1-aggr-failtest" #2: deleting ISAKMP SA (AGGR_I1) and NOT sending notification
west #
 ipsec auto --delete ikev1-aggr-failtest
west #
 echo done
done
west #
 ipsec stop
Redirecting to: [initsystem]
west #
 grep -E -i "IKE|ipsec-" /var/log/audit/audit.log
type=CRYPTO_IKE_SA msg=audit(XXX): pid=PID uid=0 auid=AUID ses=SES subj=system_u:system_r:unconfined_service_t:s0 msg='op=start direction=initiator conn-name="ikev1-failtest" connstate=1 ike-version=1 auth=RSA_SIG cipher=none ksize=0 integ=none prf=none pfs=none raddr=192.1.2.23 exe="PATH/libexec/ipsec/pluto" hostname=? addr=192.1.2.45 terminal=? res=failed'^]UID="root" AUID="unset"
type=CRYPTO_IKE_SA msg=audit(XXX): pid=PID uid=0 auid=AUID ses=SES subj=system_u:system_r:unconfined_service_t:s0 msg='op=start direction=initiator conn-name="ikev1-failtest" connstate=1 ike-version=1 auth=RSA_SIG cipher=none ksize=0 integ=none prf=none pfs=none raddr=192.1.2.23 exe="PATH/libexec/ipsec/pluto" hostname=? addr=192.1.2.45 terminal=? res=failed'^]UID="root" AUID="unset"
type=CRYPTO_IKE_SA msg=audit(XXX): pid=PID uid=0 auid=AUID ses=SES subj=system_u:system_r:unconfined_service_t:s0 msg='op=start direction=initiator conn-name="ikev1-aggr-failtest" connstate=2 ike-version=1 auth=RSA_SIG cipher=aes ksize=256 integ=sha1 prf=sha1 pfs=MODP1536 raddr=192.1.2.23 exe="PATH/libexec/ipsec/pluto" hostname=? addr=192.1.2.45 terminal=? res=failed'^]UID="root" AUID="unset"
type=CRYPTO_IKE_SA msg=audit(XXX): pid=PID uid=0 auid=AUID ses=SES subj=system_u:system_r:unconfined_service_t:s0 msg='op=start direction=initiator conn-name="ikev1-aggr-failtest" connstate=2 ike-version=1 auth=RSA_SIG cipher=aes ksize=256 integ=sha1 prf=sha1 pfs=MODP1536 raddr=192.1.2.23 exe="PATH/libexec/ipsec/pluto" hostname=? addr=192.1.2.45 terminal=? res=failed'^]UID="root" AUID="unset"
west #
 
