Re: [Swan-dev] leftikeport= does not set tcp port

2020-09-24 Thread Andrew Cagney
I pushed: commit d106052012c6a7b7a5d65e25e9c9fe0c32e34c1d (HEAD -> main, origin/main, origin/HEAD) Author: Andrew Cagney Date: Wed Sep 23 19:36:49 2020 -0400 connections: call update_ends_from_this_host_addr() from connection_check_ddns1() Replace "a small bit of code from default_end

[Swan-dev] nsrun --ns overwriting host's /etc/ipsec.* files :(

2020-09-24 Thread Paul Wouters
I ended up a few times with test configs on my laptop's /etc/ipsec.* files. I did some testing and found out that kvmrunner.py does not do this, but nsrun --ns does. I made the host files immutable after restoring them and I see this in the test when using nsrun: /testing/guestbin/swan-prep Tr

Re: [Swan-dev] testing: swan-prep break on conflicting config files

2020-09-24 Thread Antony Antony
On Mon, Sep 21, 2020 at 05:07:27PM -0400, Andrew Cagney wrote: > > > On Mon, 21 Sep 2020 at 15:32, Antony Antony wrote: > > Andrew, > > after a closer look I see l2tp and ppp configuration file could be in the > form 'hostname + "." + config_file' in the test directory. > > ik

Re: [Swan-dev] nsrun --ns overwriting host's /etc/ipsec.* files :(

2020-09-24 Thread Andrew Cagney
Some of the old code used lsw_cp_file() some did not. Do you have a mysterious /etc/strongswan directory? On Thu, 24 Sep 2020 at 12:19, Paul Wouters wrote: > > I ended up a few times with test configs on my laptop's /etc/ipsec.* files. > > I did some testing and found out that kvmrunner.py does

Re: [Swan-dev] nsrun --ns overwriting host's /etc/ipsec.* files :(

2020-09-24 Thread Paul Wouters
strongswan is installed on my host but it happens too on ikev2-05-basic-psk Sent from my iPhone > On Sep 24, 2020, at 13:08, Andrew Cagney wrote: > >  > Some of the old code used lsw_cp_file() some did not. Do you have a > mysterious /etc/strongswan directory? > >> On Thu, 24 Sep 2020 at 12

Re: [Swan-dev] nsrun --ns overwriting host's /etc/ipsec.* files :(

2020-09-24 Thread Andrew Cagney
On Thu, 24 Sep 2020 at 13:22, Paul Wouters wrote: > strongswan is installed on my host but it happens too on ikev2-05-basic-psk > > Right. However, regardless of the below, swan-prep was completely deleting /etc/strongswan. I see 2160e1389f893094831169418f4d02fd7bbf8bb8 has since fixed it. >

[Swan-dev] ikev1-hostpair-01 and c->prio

2020-09-24 Thread Andrew Cagney
This: https://testing.libreswan.org/v3.30-1791-gd106052012-main/ikev1-hostpair-01/OUTPUT/east.console.diff Comes from: connections: don't update an end when .host_addr is 0.0.0.0 https://github.com/libreswan/libreswan/commit/a739eaff972135b268a139c54b37e0f366a6ad02 In case the cause isn't obviou

Re: [Swan-dev] ikev1-hostpair-01 and c->prio

2020-09-24 Thread Paul Wouters
On Thu, 24 Sep 2020, Andrew Cagney wrote: -> the config file has right[host]=%any -> update_ends_from_this_host_addr() (nee default_end()) sees this and does nothing (right.end.client.maskbits==0) (before it would think %any was valid and set .end.client to %any/32 -> right.end.client.maskbits

Re: [Swan-dev] ikev1-hostpair-01 and c->prio

2020-09-24 Thread Andrew Cagney
On Thu, 24 Sep 2020 at 20:56, Paul Wouters wrote: > On Thu, 24 Sep 2020, Andrew Cagney wrote: > > > -> the config file has right[host]=%any > > -> update_ends_from_this_host_addr() (nee default_end()) sees this and > does nothing (right.end.client.maskbits==0) > > (before it would think %any was

Re: [Swan-dev] ikev1-hostpair-01 and c->prio

2020-09-24 Thread Paul Wouters
On Thu, 24 Sep 2020, Andrew Cagney wrote: Once ddns resolves a name it updates .host_addr (from AF_UNSPEC to a valid address). This, in turn, can update .client to .host_addr/32. And updating .client changes .maskbits from 0 to 32, say. Since c->prio is based on .maskbits, should it too be upda