/testing/guestbin/swan-prep
west #
 # confirm that the network is alive
west #
 ../../guestbin/wait-until-alive -I 192.0.1.254 192.0.2.254
destination -I 192.0.1.254 192.0.2.254 is alive
west #
 ipsec start
Redirecting to: [initsystem]
west #
 ../../guestbin/wait-until-pluto-started
west #
 ipsec auto --add west-east
002 "west-east": added IKEv1 connection
west #
 echo "initdone"
initdone
west #
 ipsec auto --up west-east
002 "west-east" #1: initiating IKEv1 Main Mode connection
1v1 "west-east" #1: sent Main Mode request
1v1 "west-east" #1: sent Main Mode I2
1v1 "west-east" #1: sent Main Mode I3
002 "west-east" #1: Peer ID is ID_FQDN: '@east'
003 "west-east" #1: authenticated using RSA with SHA1 and preloaded certificate '@east'
004 "west-east" #1: IKE SA established {auth=RSA_SIG cipher=AES_CBC_256 integ=HMAC_SHA2_256 group=MODP2048}
002 "west-east" #2: initiating Quick Mode IKEv1+RSASIG+ENCRYPT+TUNNEL+PFS+UP+IKE_FRAG_ALLOW+ESN_NO
1v1 "west-east" #2: sent Quick Mode request
004 "west-east" #2: IPsec SA established tunnel mode {ESP=>0xESPESP <0xESPESP xfrm=AES_CBC_128-HMAC_SHA1_96 NATOA=none NATD=none DPD=passive}
west #
 # suppress martian logging before we create havoc
west #
 echo 0 > /proc/sys/net/ipv4/conf/default/log_martians
west #
 echo 0 > /proc/sys/net/ipv4/conf/all/log_martians
west #
 # add east's ip on west to shoot in foot
west #
 ip addr add 192.1.2.23/24 dev eth1
west #
 ipsec auto --ready
002 listening for IKE messages
002 adding UDP interface eth1 192.1.2.23:500
002 adding UDP interface eth1 192.1.2.23:4500
003 two interfaces match "west-east" (eth1 192.1.2.23, eth1 192.1.2.45)
002 "west-east": terminating SAs using this connection
002 "west-east" #2: deleting state (STATE_QUICK_I2) and sending notification
005 "west-east" #2: ESP traffic information: in=0B out=0B
002 "west-east" #1: deleting state (STATE_MAIN_I4) and sending notification
002 forgetting secrets
002 loading secrets from "/etc/ipsec.secrets"
002 no secrets filename matched "/etc/ipsec.d/*.secrets"
west #
 sleep 30
west #
 echo done
done
west #
 ipsec whack --shutdown
west #
 
