<div style="line-height:1.7;color:#000000;font-size:14px;font-family:Arial"><div>hello, </div><div><br></div><div>    I have a single Road Warrior successfully connecting to a Libreswan gateway and communicating to the subnet behind the gateway securely. That roadwarrior is behind a firewall allowing all outbound port traffic and using NAT.  So my roadwarrior has an IP address of 10.0.0.18. When another roadwarrior happens to be behind someone else's firewall and happens to get 10.0.0.18 also. Then we will get the following error: "route to peer's client conflicts with "xauth-psk"[2617] 122.96.85.17 122.96.85.17; releasing old connection to free the route". Detail logs are pasted below.</div><div><br></div><div>Looking forward to your reply. Thanks a lot.</div><div><br></div><div><br></div><div>#cat /etc/ipsec.conf</div><div><div>version 2.0</div><div><br></div><div>config setup</div><div>  virtual_private=%v4:10.0.0.0/8,%v4:192.168.0.0/16,%v4:172.16.0.0/12,%v4:!172.16.0.0/16,%v4:!172.18.0.0/16</div><div>  protostack=netkey</div><div>  nhelpers=0</div><div>  interfaces=%defaultroute</div><div>  uniqueids=no</div><div><br></div><div>conn shared</div><div>  left=%defaultroute</div><div>  leftid=188.166.132.41</div><div>  right=%any</div><div>  encapsulation=yes</div><div>  authby=secret</div><div>  pfs=no</div><div>  rekey=no</div><div>  keyingtries=5</div><div>  dpddelay=30</div><div>  dpdtimeout=120</div><div>  dpdaction=clear</div><div>  ike=3des-sha1,3des-sha1;modp1024,aes-sha1,aes-sha1;modp1024,aes-sha2,aes-sha2;modp1024</div><div>  phase2alg=3des-sha1,aes-sha1,aes-sha2</div><div>  sha2-truncbug=yes</div><div><br></div><div>conn l2tp-psk</div><div>  auto=add</div><div>  leftprotoport=17/1701</div><div>  rightprotoport=17/%any</div><div>  type=transport</div><div>  phase2=esp</div><div>  also=shared</div><div><br></div><div>conn xauth-psk</div><div>  auto=add</div><div>  leftsubnet=0.0.0.0/0</div><div>  rightaddresspool=172.18.0.10-172.18.255.250</div><div>  modecfgdns1=8.8.8.8</div><div>  modecfgdns2=8.8.4.4</div><div>  leftxauthserver=yes</div><div>  rightxauthclient=yes</div><div>  leftmodecfgserver=yes</div><div>  rightmodecfgclient=yes</div><div>  modecfgpull=yes</div><div>  xauthby=file</div><div>  ike-frag=yes</div><div>  ikev2=never</div><div>  cisco-unity=yes</div><div>  also=shared</div></div><div><br></div><div><div># ipsec verify</div><div>Verifying installed system and configuration files</div><div><br></div><div>Version check and ipsec on-path                         [OK]</div><div>Libreswan 3.19 (netkey) on 4.4.70+</div><div>Checking for IPsec support in kernel                    [OK]</div><div> NETKEY: Testing XFRM related proc values</div><div>         ICMP default/send_redirects                    [OK]</div><div>         ICMP default/accept_redirects                  [OK]</div><div>         XFRM larval drop                               [OK]</div><div>Pluto ipsec.conf syntax                                 [OK]</div><div>Two or more interfaces found, checking IP forwarding    [OK]</div><div>Checking rp_filter                                      [OK]</div><div>Checking that pluto is running                          [OK]</div><div> Pluto listening for IKE on udp 500                     [OK]</div><div> Pluto listening for IKE/NAT-T on udp 4500              [OK]</div><div> Pluto ipsec.secret syntax                              [OK]</div><div>Checking 'ip' command                                   [OK]</div><div>Checking 'iptables' command                             [OK]</div><div>Checking 'prelink' command does not interfere with FIPS [OK]</div><div>Checking for obsolete ipsec.conf options                [OK]</div></div><div><br></div><div><div># uname  -a</div><div>Linux ubuntu-1gb-01 4.4.0-83 #1 SMP Mon Jul 17 15:58:46 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux</div></div><div><br></div><div>Detail logs:</div><div><br></div><div><div>pluto[20462]: "xauth-psk"[4871] 117.62.189.148 #7866: responding to Main Mode from unknown peer 117.62.189.148</div><div>pluto[20462]: "xauth-psk"[4871] 117.62.189.148 #7866: transition from state STATE_MAIN_R0 to state STATE_MAIN_R1</div><div>pluto[20462]: "xauth-psk"[4871] 117.62.189.148 #7866: STATE_MAIN_R1: sent MR1, expecting MI2</div><div>pluto[20462]: "xauth-psk"[4871] 117.62.189.148 #7866: transition from state STATE_MAIN_R1 to state STATE_MAIN_R2</div><div>pluto[20462]: "xauth-psk"[4871] 117.62.189.148 #7866: STATE_MAIN_R2: sent MR2, expecting MI3</div><div>pluto[20462]: "xauth-psk"[4871] 117.62.189.148 #7866: ignoring informational payload IPSEC_INITIAL_CONTACT, msgid=00000000, length=28</div><div>pluto[20462]: "xauth-psk"[4871] 117.62.189.148 #7866: Main mode peer ID is ID_IPV4_ADDR: '10.0.0.18'</div><div>pluto[20462]: "xauth-psk"[4871] 117.62.189.148 #7866: switched from "xauth-psk"[4871] 117.62.189.148 to "xauth-psk"</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: deleting connection "xauth-psk"[4871] 117.62.189.148 instance with peer 117.62.189.148 {isakmp=#0/ipsec=#0}</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: transition from state STATE_MAIN_R2 to state STATE_MAIN_R3</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: new NAT mapping for #7866, was 117.62.189.148:500, now 117.62.189.148:4500</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: STATE_MAIN_R3: sent MR3, ISAKMP SA established {auth=PRESHARED_KEY cipher=aes_256 integ=sha2_256 group=MODP2048}</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: XAUTH: Sending Username/Password request (XAUTH_R0)</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: discarding duplicate packet; already STATE_XAUTH_R0</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: XAUTH: xauth_inR1(STF_OK)</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: transition from state STATE_XAUTH_R1 to state STATE_MAIN_R3</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: STATE_MAIN_R3: sent MR3, ISAKMP SA established</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: Unsupported modecfg long attribute INTERNAL_ADDRESS_EXPIRY received.</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: Unsupported modecfg long attribute APPLICATION_VERSION received.</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: Unsupported modecfg long attribute MODECFG_BANNER received.</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: Unsupported modecfg long attribute MODECFG_DOMAIN received.</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: Unsupported modecfg long attribute CISCO_SPLIT_DNS received.</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: Unsupported modecfg long attribute CISCO_SPLIT_INC received.</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: Unsupported modecfg long attribute CISCO_SPLIT_EXCLUDE received.</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: Unsupported modecfg long attribute CISCO_DO_PFS received.</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: Unsupported modecfg long attribute CISCO_SAVE_PW received.</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: Unsupported modecfg long attribute CISCO_FW_TYPE received.</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: Unsupported modecfg long attribute CISCO_BACKUP_SERVER received.</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: Unsupported modecfg long attribute CISCO_UNKNOWN_SEEN_ON_IPHONE received.</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: modecfg_inR0(STF_OK)</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: transition from state STATE_MODE_CFG_R0 to state STATE_MODE_CFG_R1</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: STATE_MODE_CFG_R1: ModeCfg Set sent, expecting Ack</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7866: the peer proposed: 0.0.0.0/0:0/0 -> 172.18.0.21/32:0/0</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7871: responding to Quick Mode proposal {msgid:5ae99982}</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7871:     us: 0.0.0.0/0===128.199.157.10[MS+XS+S=C]</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7871:   them: 117.62.189.148[10.0.0.18,+MC+XC+S=C]===172.18.0.21/32</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7871: <span style="color: rgb(255, 0, 0);"><b>route to peer's client conflicts with "xauth-psk"[2617] 122.96.85.17 122.96.85.17; releasing old connection to free the route</b></span></div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7871: deleting connection "xauth-psk"[2617] 122.96.85.17 instance with peer 122.96.85.17 {isakmp=#7859/ipsec=#7858}</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7871: transition from state STATE_QUICK_R0 to state STATE_QUICK_R1</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7871: STATE_QUICK_R1: sent QR1, inbound IPsec SA installed, expecting QI2 tunnel mode {ESP/NAT=>0x0c0ed20e <0x40311fdc xfrm=AES_256-HMAC_SHA1 NATOA=none NATD=117.62.189.148:4500 DPD=active username=pcM5VrKyZ5nFoMh0em9A8RjZHtAw9GMkFy8QzlDdMzUE5hwZsT99wXtygCyRvHF/VwAJMv/b6ygydCfsMMCXIDVJOMsa7y5PA/US/3pj+aU=}</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7871: Warning: XAUTH username changed from '' to ''</div><div>pluto[20462]: message repeated 2 times: [ "xauth-psk"[4873] 117.62.189.148 #7871: Warning: XAUTH username changed from '' to '']</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7871: transition from state STATE_QUICK_R1 to state STATE_QUICK_R2</div><div>pluto[20462]: "xauth-psk"[4873] 117.62.189.148 #7871: STATE_QUICK_R2: IPsec SA established tunnel mode {ESP/NAT=>0x0c0ed20e <0x40311fdc xfrm=AES_256-HMAC_SHA1 NATOA=none NATD=117.62.189.148:4500 DPD=active username=pcM5VrKyZ5nFoMh0em9A8RjZHtAw9GMkFy8QzlDdMzUE5hwZsT99wXtygCyRvHF/VwAJMv/b6ygydCfsMMCXIDVJOMsa7y5PA/US/3pj+aU=}</div></div><div><br></div><div><br></div><div><br></div></div><br><br><span title="neteasefooter"><p> </p></span>