MIME-Version: 1.0 In-Reply-To: <20090930221942.GA28717@...1266...> References: <7bb795fd0909251436v2369d6d5q674e63e0621fcd56@...278...> <200909301941.01923.mailinglists@...1145...> <7bb795fd0909301120veaf5f48gb65b081cd2cb09a3@...278...> <200909302047.07444.mailinglists@...1145...> <7bb795fd0909301421i5fd974b5xbe8d352b7b7f3c9a@...278...> <20090930221942.GA28717@...1266...> From: JuanJo Ciarlante Date: Thu, 1 Oct 2009 00:26:15 +0200 Message-ID: <7bb795fd0909301526s535c0e9aidfad95b0228adb4e@...278...> Subject: Re: [Openvpn-devel] [PATCH] openvpn over ipv6 support -v0.4.6 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: quoted-printable To: =?ISO-8859-1?Q?Marcel_Pennewi=DF?= Cc: openvpn-devel@lists.sourceforge.net Marcel, On Thu, Oct 1, 2009 at 12:19 AM, JuanJo Ciarlante wrote: > > On Wed, Sep 30, 2009 at 11:21:41PM +0200, JuanJo Ciarlante wrote: > > On Wed, Sep 30, 2009 at 8:47 PM, Marcel Pennewi=DF > > wrote: > > > > > On Wednesday 30 September 2009 20:20:40 JuanJo Ciarlante wrote: > > > > Could you please copy me the the exact cmdline and context (inetd?) > > > > you are using in both cases?, also if there's any extra patch appli= ed, > > > etc. > > > > > > /usr/sbin/openvpn --config /etc/openvpn/tcp.conf --writepid > > > /var/run/openvpn.tcp.pid --daemon --setenv > > > SVCNAME openvpn.tcp --cd /etc/openvpn > > > > > > /etc/openvpn/tcp.conf: > > > port 897 > > > proto tcp6-server > > > dev tap1 > > > server-bridge 192.168.42.253 255.255.255.0 192.168.42.1 192.168.42.200 > > > > > > tls-server > > > dh /etc/openvpn/files/dh2048.pem > > > ca /etc/openvpn/files/ca.pem > > > cert /etc/openvpn/files/cert.pem > > > key /etc/openvpn/files/key.pem > > > comp-lzo > > > client-to-client > > > client-config-dir /etc/openvpn/clients > > > persist-tun > > > persist-key > > > keepalive 10 120 > > > script-security 2 > > > user nobody > > > group nogroup > > > verb 3 > > > > > > patch applied from gentoo ebuild: > > > --- socket.c~ =A0 2008-11-02 01:39:00.406009999 +0100 > > > +++ socket.c =A0 =A02008-11-02 01:39:00.406009999 +0100 > > > @@ -22,6 +22,7 @@ > > > =A0* =A059 Temple Place, Suite 330, Boston, MA =A002111-1307 =A0USA > > > =A0*/ > > > > > > +#define _GNU_SOURCE > > > =A0#include "syshead.h" > > > > > > =A0#include "socket.h" > > > > > > thx, > > > > > > > Cool ... it's crashing for me also (yaY!) , it's something in the > > multi-client path > > that I hadn't handled, will work on it tomorrow. > > Please apply this patch: also available as full patch at =A0=A0http://cloud.github.com/downloads/jjo/openvpn-ipv6/openvpn-2.1_rc19-2= .1_rc19c-ipv6-0.4.7.patch.gz > > >From 3afb64b8255fa28e488e793259b2f3de94840b01 Mon Sep 17 00:00:00 2001 > From: JuanJo Ciarlante > Date: Thu, 1 Oct 2009 00:15:12 +0200 > Subject: [PATCH] * fix multi-tcp crash (corrected assertion) > > --- > =A0mtcp.c =A0 | =A0 =A06 +++++- > =A0socket.c | =A0 =A06 +++++- > =A02 files changed, 10 insertions(+), 2 deletions(-) > > diff --git a/mtcp.c b/mtcp.c > index f578429..7e2b07d 100644 > --- a/mtcp.c > +++ b/mtcp.c > @@ -153,7 +153,11 @@ multi_tcp_instance_specific_init (struct multi_conte= xt *m, struct multi_instance > =A0 ASSERT (mi->context.c2.link_socket); > =A0 ASSERT (mi->context.c2.link_socket->info.lsa); > =A0 ASSERT (mi->context.c2.link_socket->mode =3D=3D LS_MODE_TCP_ACCEPT_FR= OM); > - =A0ASSERT (mi->context.c2.link_socket->info.lsa->actual.dest.addr.sa.sa= _family =3D=3D AF_INET); > + =A0ASSERT (mi->context.c2.link_socket->info.lsa->actual.dest.addr.sa.sa= _family =3D=3D AF_INET > +#ifdef USE_PF_INET6 > + =A0 =A0 =A0 =A0 || mi->context.c2.link_socket->info.lsa->actual.dest.ad= dr.sa.sa_family =3D=3D AF_INET6 > +#endif > + =A0 =A0 =A0 =A0 ); > =A0 if (!mroute_extract_openvpn_sockaddr (&mi->real, &mi->context.c2.link= _socket->info.lsa->actual.dest, true)) > =A0 =A0 { > =A0 =A0 =A0 msg (D_MULTI_ERRORS, "MULTI TCP: TCP client address is undefi= ned"); > diff --git a/socket.c b/socket.c > index 00d841e..97e6234 100644 > --- a/socket.c > +++ b/socket.c > @@ -1616,7 +1616,11 @@ link_socket_init_phase1 (struct link_socket *sock, > =A0 if (mode =3D=3D LS_MODE_TCP_ACCEPT_FROM) > =A0 =A0 { > =A0 =A0 =A0 ASSERT (accept_from); > - =A0 =A0 =A0ASSERT (sock->info.proto =3D=3D PROTO_TCPv4_SERVER); > + =A0 =A0 =A0ASSERT (sock->info.proto =3D=3D PROTO_TCPv4_SERVER > +#ifdef USE_PF_INET6 > + =A0 =A0 =A0 =A0 =A0 =A0 || sock->info.proto =3D=3D PROTO_TCPv6_SERVER > +#endif > + =A0 =A0 =A0 =A0 =A0 =A0); > =A0 =A0 =A0 ASSERT (!sock->inetd); > =A0 =A0 =A0 sock->sd =3D accept_from->sd; > =A0 =A0 } > -- > 1.5.4.3 > > I tested your config upto full connection, and seems to work. > > Cheers, -- --JuanJo ; echo jAjo@...1263... | sed 's/[SPAM]//g'