/testing/guestbin/swan-prep --nokeys
Creating empty NSS database
west #
 ../../guestbin/mount-bind.sh /etc/hosts /etc/hosts
/etc/hosts /tmp/hosts.west.ikev2-ddns-03 /etc/hosts
west #
 if grep right.libreswan.org /etc/hosts ; then echo "TEST FAILED - should not have /etc/hosts entry at start" ; false ; else : ; fi
west #
 ipsec start
Redirecting to: [initsystem]
west #
 ../../guestbin/wait-until-pluto-started
west #
 ipsec whack --impair suppress_retransmits
west #
 ipsec auto --add named
"named": failed to resolve 'right=right.libreswan.org' at load time: not a numeric IPv4 address and name lookup failed (no validation performed)
"named": added IKEv2 connection
west #
 ipsec status | grep "===" # should show %dns for pending resolve
"named": 192.0.1.0/24===192.1.2.45[@west]---192.1.2.23...%dns<right.libreswan.org>[@east]===192.0.2.0/24; unrouted; my_ip=unset; their_ip=unset;
west #
 echo "initdone"
initdone
west #
 sleep 5
west #
 echo "192.1.2.23 right.libreswan.org" >> /etc/hosts
west #
 # trigger DDNS event (saves us from waiting)
west #
 ipsec whack --ddns
updating pending dns lookups
west #
 # there should be no states
west #
 ipsec showstates
west #
 ipsec status | grep "===" # should no longer show %dns as resolving completed
"named": 192.0.1.0/24===192.1.2.45[@west]...192.1.2.23<right.libreswan.org>[@east]===192.0.2.0/24; unrouted; my_ip=unset; their_ip=unset;
west #
 # confirm it all resolved by bringing the conn up manually
west #
 ipsec auto --up named
"named" #1: initiating IKEv2 connection to 192.1.2.23 (right.libreswan.org) using UDP
"named" #1: sent IKE_SA_INIT request to 192.1.2.23:UDP/500
"named" #1: processed IKE_SA_INIT response from 192.1.2.23:UDP/500 {cipher=AES_GCM_16_256 integ=n/a prf=HMAC_SHA2_512 group=DH19}, initiating IKE_AUTH
"named" #1: sent IKE_AUTH request to 192.1.2.23:UDP/500 with shared-key-mac and FQDN '@west'; Child SA #2 {ESP <0xESPESP}
"named" #1: initiator established IKE SA; authenticated peer using authby=secret and FQDN '@east'
"named" #2: initiator established Child SA using #1; IPsec tunnel [192.0.1.0/24===192.0.2.0/24] {ESP/ESN=>0xESPESP <0xESPESP xfrm=AES_GCM_16_256-NONE DPD=passive}
west #
 echo done
done
west #
