Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-02-18 Thread Gert Doering
Hi, On Tue, Feb 18, 2014 at 07:16:17AM +0100, Tore Anderson wrote: > > Could you run my test program to see whether that gets it right? > > It doesn't: Meh! > This is 64-bit Linux, yes: I'll re-test. I *did* test it on mine... Linux gentoo 3.3.8-gentoo #1 SMP Fri Jun 29 14:10:01 CEST 2012 x8

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-02-18 Thread Tore Anderson
Hi Gert, > Could you run my test program to see whether that gets it right? It doesn't: server$ mhome AF_INET6/IPV6_RECVPKTINFO enabled setsockopt(IPV6_V6ONLY=0) Socket bound to local address [AF_INET6][undef]:50001 -- CMSG_NXTHDR=(nil), level=41, type=50 IPV6_PKTINFO read: fromlen=28, r_len=5

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-02-17 Thread Arne Schwabe
>> This happens both with today's git master and with 2.3.2. BTW Arne's >> patch to socket.c that fixes the assert crash we originally discussed >> still isn't included in git master, has it been forgotten about? > ISTR that Arne wrote something about "this is a quick fix, will send a > proper pat

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-02-17 Thread Gert Doering
Hi, On Mon, Feb 17, 2014 at 08:28:59PM +0100, Tore Anderson wrote: > Now that has been fixed upstream (Linux 3.14), I tried again. Here I am > connecting from 84.209.94.36 to 87.238.35.254, which is a secondary > address on the server (87.238.35.145 is the primary). The OpenVPN > server logs: > >

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-02-17 Thread Tore Anderson
* Gert Doering > On Sat, Jan 11, 2014 at 12:59:02AM +0100, Tore Anderson wrote: >> FWIW: Now I also got to test git master with what I wanted to in the >> first place, namely to see whether or not all the nice dualstack changes >> had also made "multihome" work for IPv4-mapped clients coming in to

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-19 Thread Gert Doering
Hi, On Sun, Jan 19, 2014 at 03:04:17PM +0100, Gert Doering wrote: > In case you want to test yourself, the code is appended. It's not pretty, > but gets the job done :-) Here's the latest iteration of the code. The changes compared to openvpn's socket.c are actually bigger than I expected, as w

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-19 Thread Gert Doering
Hi, On Sun, Jan 19, 2014 at 03:04:17PM +0100, Gert Doering wrote: > In case you want to test yourself, the code is appended. ... it was not. As always when people say "I have attached..." :-/ gert -- USENET is *not* the non-clickable part of WWW!

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-19 Thread Gert Doering
Hi, On Sat, Jan 11, 2014 at 12:59:02AM +0100, Tore Anderson wrote: > FWIW: Now I also got to test git master with what I wanted to in the > first place, namely to see whether or not all the nice dualstack changes > had also made "multihome" work for IPv4-mapped clients coming in to the > server on

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-11 Thread Arne Schwabe
Am 11.01.14 14:07, schrieb Gert Doering: > Hi, > > On Sat, Jan 11, 2014 at 02:00:59PM +0100, Arne Schwabe wrote: >>> Jan 11 01:07:47 greed ovpn-server[10222]: :::84.209.244.191 TLS: >>> Initial packet from [AF_INET6]:::84.209.244.191:38878 (via >>> 2a02:c0:1001:100::253%eth0), sid=98e4314

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-11 Thread Gert Doering
Hi, On Sat, Jan 11, 2014 at 02:00:59PM +0100, Arne Schwabe wrote: > > Jan 11 01:07:47 greed ovpn-server[10222]: :::84.209.244.191 TLS: > > Initial packet from [AF_INET6]:::84.209.244.191:38878 (via > > 2a02:c0:1001:100::253%eth0), sid=98e4314f 9ea08578 > > > > I find the "via 2a02:c0:100

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-11 Thread Arne Schwabe
Am 11.01.14 01:12, schrieb Tore Anderson: > * Arne Schwabe > >> Listening on multiple sockets not yet implemented. But a server having >> proto udp6 should get IPv6 mapped IPv4 clients working. What is >> happening/not working for you? > "multihome" doesn't work, the OpenVPN server responds from it

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-11 Thread Gert Doering
Hi, On Sat, Jan 11, 2014 at 11:01:58AM +0100, Tore Anderson wrote: > > I *thought* that both proto udp and proto udp6 would create an IPv6 socket > > bound to :: with IPV6_V6ONLY set to 0 (= accepting IPv4 and IPv6 packets > > to any address). Only "proto udp4" should listen to 0.0.0.0. > > This

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-11 Thread Tore Anderson
* Gert Doering > I *thought* that both proto udp and proto udp6 would create an IPv6 socket > bound to :: with IPV6_V6ONLY set to 0 (= accepting IPv4 and IPv6 packets > to any address). Only "proto udp4" should listen to 0.0.0.0. This is not how git master behaves for me. "proto udp" and "proto

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-11 Thread Gert Doering
Hi, On Sat, Jan 11, 2014 at 12:59:02AM +0100, Tore Anderson wrote: > FWIW: Now I also got to test git master with what I wanted to in the > first place, namely to see whether or not all the nice dualstack changes > had also made "multihome" work for IPv4-mapped clients coming in to the > server on

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-11 Thread Tore Anderson
* Arne Schwabe > Listening on multiple sockets not yet implemented. But a server having > proto udp6 should get IPv6 mapped IPv4 clients working. What is > happening/not working for you? "multihome" doesn't work, the OpenVPN server responds from its primary IPv4 address (the one the OS selects as

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-11 Thread Arne Schwabe
Am 11.01.14 00:59, schrieb Tore Anderson: > * Arne Schwabe > >> Can you try the following one line patch? I will do a better cleanup >> patch later but this should fix the problem > Yep, this works. Thanks! > > FWIW: Now I also got to test git master with what I wanted to in the > first place, name

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-10 Thread Tore Anderson
* Arne Schwabe > Can you try the following one line patch? I will do a better cleanup > patch later but this should fix the problem Yep, this works. Thanks! FWIW: Now I also got to test git master with what I wanted to in the first place, namely to see whether or not all the nice dualstack chang

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-10 Thread Arne Schwabe
Am 10.01.14 15:03, schrieb Tore Anderson: > * Arne Schwabe > >> That is very weird. I would expect it to fail for both cases in the same >> way. The codepath should trigger the same ASSERT(0) in both cases (or >> work in both). Can you forward a copy of your server configuration to >> me? Then I wi

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-10 Thread Gert Doering
Hi, On Fri, Jan 10, 2014 at 03:30:10PM +0100, Arne Schwabe wrote: > But > > [AF_INET6]:::87.238.42.150:47707 > > and > > [AF_INET6]2a02:c0:100:0:9e8e:99ff:fed1:5243:56277 > > should be same the same size and handled both the same way from OpenVPN since > they are both IPv6. Good point.

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-10 Thread Arne Schwabe
Am 10.01.14 15:07, schrieb Gert Doering: > Hi, > > On Fri, Jan 10, 2014 at 02:51:48PM +0100, Arne Schwabe wrote: >> That is very weird. I would expect it to fail for both cases in the same >> way. The codepath should trigger the same ASSERT(0) in both cases (or >> work in both). > ... unless somet

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-10 Thread Gert Doering
Hi, On Fri, Jan 10, 2014 at 02:51:48PM +0100, Arne Schwabe wrote: > That is very weird. I would expect it to fail for both cases in the same > way. The codepath should trigger the same ASSERT(0) in both cases (or > work in both). ... unless something is overwriting to->ai_family, for example by

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-10 Thread Tore Anderson
* Arne Schwabe > That is very weird. I would expect it to fail for both cases in the same > way. The codepath should trigger the same ASSERT(0) in both cases (or > work in both). Can you forward a copy of your server configuration to > me? Then I will try to reproduce that problem. Sure thing, he

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-10 Thread Tore Anderson
* Gert Doering > Just to be sure I understand: it works for "proto udp6" if you do *not* > use --multihome on the server? Correct. Apologies for being unclear. Tore

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-10 Thread Arne Schwabe
Am 10.01.14 14:32, schrieb Tore Anderson: > If I connect to an openvpn server using "proto udp6" and "multihome", it > instantly crashes with an assertion failure: > > Jan 10 14:25:58 greed ovpn-server[9905]: 2a02:c0:100:0:9e8e:99ff:fed1:5243 > TLS: Initial packet from [AF_INET6]2a02:c0:100:0:9e8e

Re: [Openvpn-devel] git master proto udp6+multihome is broken

2014-01-10 Thread Gert Doering
Hi, On Fri, Jan 10, 2014 at 02:32:23PM +0100, Tore Anderson wrote: > If I connect to an openvpn server using "proto udp6" and "multihome", it > instantly crashes with an assertion failure: Just to be sure I understand: it works for "proto udp6" if you do *not* use --multihome on the server? > Th

[Openvpn-devel] git master proto udp6+multihome is broken

2014-01-10 Thread Tore Anderson
If I connect to an openvpn server using "proto udp6" and "multihome", it instantly crashes with an assertion failure: Jan 10 14:25:58 greed ovpn-server[9905]: 2a02:c0:100:0:9e8e:99ff:fed1:5243 TLS: Initial packet from [AF_INET6]2a02:c0:100:0:9e8e:99ff:fed1:5243:56277 (via 2a02:c0:1001:100::145%e