/testing/guestbin/swan-prep
road #
 ipsec start
Redirecting to: [initsystem]
road #
 ../../guestbin/wait-until-pluto-started
road #
 ipsec auto --add road-eastnet-nat
002 "road-eastnet-nat": added IKEv1 connection
road #
 ipsec auto --status | grep road-eastnet-nat
000 "road-eastnet-nat": 192.0.2.219/32===192.1.3.209[@road]---192.1.3.254...192.1.2.23[@east]===192.0.2.0/24; unrouted; eroute owner: #0
000 "road-eastnet-nat":     oriented; my_ip=192.0.2.219; their_ip=unset; my_updown=ipsec _updown;
000 "road-eastnet-nat":   xauth us:none, xauth them:none,  my_username=[any]; their_username=[any]
000 "road-eastnet-nat":   our auth:rsasig, their auth:rsasig, our autheap:none, their autheap:none;
000 "road-eastnet-nat":   modecfg info: us:none, them:none, modecfg policy:push, dns:unset, domains:unset, cat:unset;
000 "road-eastnet-nat":   sec_label:unset;
000 "road-eastnet-nat":   ike_life: 28800s; ipsec_life: 28800s; replay_window: 128; rekey_margin: 540s; rekey_fuzz: 100%; keyingtries: 0;
000 "road-eastnet-nat":   retransmit-interval: 9999ms; retransmit-timeout: 99s; iketcp:no; iketcp-port:4500;
000 "road-eastnet-nat":   initial-contact:no; cisco-unity:no; fake-strongswan:no; send-vendorid:no; send-no-esp-tfc:no;
000 "road-eastnet-nat":   policy: IKEv1+RSASIG+ENCRYPT+TUNNEL+PFS+IKE_FRAG_ALLOW+ESN_NO+ESN_YES;
000 "road-eastnet-nat":   conn_prio: 32,24; interface: eth0; metric: 0; mtu: unset; sa_prio:auto; sa_tfc:none;
000 "road-eastnet-nat":   nflog-group: unset; mark: unset; vti-iface:unset; vti-routing:no; vti-shared:no; nic-offload:auto;
000 "road-eastnet-nat":   our idtype: ID_FQDN; our id=@road; their idtype: ID_FQDN; their id=@east
000 "road-eastnet-nat":   dpd: action:hold; delay:0; timeout:0; nat-t: encaps:auto; nat_keepalive:yes; ikev1_natt:both
000 "road-eastnet-nat":   newest ISAKMP SA: #0; newest IPsec SA: #0; conn serial: $1;
road #
 ipsec whack --impair suppress-retransmits
road #
 echo "initdone"
initdone
road #
 ipsec auto --up road-eastnet-nat
002 "road-eastnet-nat" #1: initiating IKEv1 Main Mode connection
1v1 "road-eastnet-nat" #1: sent Main Mode request
1v1 "road-eastnet-nat" #1: sent Main Mode I2
1v1 "road-eastnet-nat" #1: sent Main Mode I3
002 "road-eastnet-nat" #1: Peer ID is ID_FQDN: '@east'
003 "road-eastnet-nat" #1: authenticated using RSA with SHA1 and preloaded certificate '@east'
004 "road-eastnet-nat" #1: IKE SA established {auth=RSA_SIG cipher=AES_CBC_256 integ=HMAC_SHA2_256 group=MODP2048}
002 "road-eastnet-nat" #2: initiating Quick Mode IKEv1+RSASIG+ENCRYPT+TUNNEL+PFS+UP+IKE_FRAG_ALLOW+ESN_NO+ESN_YES
1v1 "road-eastnet-nat" #2: sent Quick Mode request
004 "road-eastnet-nat" #2: IPsec SA established tunnel mode {ESPinUDP=>0xESPESP <0xESPESP xfrm=AES_CBC_128-HMAC_SHA1_96 NATD=192.1.2.23:4500 DPD=passive}
road #
 # 192.0.2.219 as source ip should be picked up automatically
road #
 ../../guestbin/ping-once.sh --up 192.0.2.254
up
road #
 ipsec whack --trafficstatus
006 #2: "road-eastnet-nat", type=ESP, add_time=1234567890, inBytes=84, outBytes=84, id='@east'
road #
 echo done
done
road #
 ../../guestbin/ipsec-look.sh
road NOW
XFRM state:
src 192.1.2.23 dst 192.1.3.209
	proto esp spi 0xSPISPI reqid REQID mode tunnel
	replay-window 0 flag af-unspec
	auth-trunc hmac(sha1) 0xHASHKEY 96
	enc cbc(aes) 0xENCKEY
	encap type espinudp sport 4500 dport 4500 addr 0.0.0.0
	anti-replay esn context:
	 seq-hi 0x0, seq 0xXX, oseq-hi 0x0, oseq 0xXX
	 replay_window 128, bitmap-length 4
	 00000000 00000000 00000000 XXXXXXXX 
src 192.1.3.209 dst 192.1.2.23
	proto esp spi 0xSPISPI reqid REQID mode tunnel
	replay-window 0 flag af-unspec
	auth-trunc hmac(sha1) 0xHASHKEY 96
	enc cbc(aes) 0xENCKEY
	encap type espinudp sport 4500 dport 4500 addr 0.0.0.0
	anti-replay esn context:
	 seq-hi 0x0, seq 0xXX, oseq-hi 0x0, oseq 0xXX
	 replay_window 128, bitmap-length 4
	 00000000 00000000 00000000 XXXXXXXX 
XFRM policy:
src 192.0.2.0/24 dst 192.0.2.219/32
	dir fwd priority PRIORITY ptype main
	tmpl src 192.1.2.23 dst 192.1.3.209
		proto esp reqid REQID mode tunnel
src 192.0.2.0/24 dst 192.0.2.219/32
	dir in priority PRIORITY ptype main
	tmpl src 192.1.2.23 dst 192.1.3.209
		proto esp reqid REQID mode tunnel
src 192.0.2.219/32 dst 192.0.2.0/24
	dir out priority PRIORITY ptype main
	tmpl src 192.1.3.209 dst 192.1.2.23
		proto esp reqid REQID mode tunnel
XFRM done
IPSEC mangle TABLES
NEW_IPSEC_CONN mangle TABLES
ROUTING TABLES
default via 192.1.3.254 dev eth0
192.0.2.0/24 via 192.1.3.254 dev eth0 src 192.0.2.219
192.1.3.0/24 dev eth0 proto kernel scope link src 192.1.3.209
NSS_CERTIFICATES
Certificate Nickname                                         Trust Attributes
                                                             SSL,S/MIME,JAR/XPI
road #
 
