-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 30/12/11 21:21, Gert Doering wrote:
> Hi,
> 
> On Fri, Dec 30, 2011 at 08:12:56PM +0100, Gert Doering wrote:
>> On Wed, Nov 23, 2011 at 04:56:22PM +1300, Michal Ludvig wrote:
>>> I'm using the latest openvpn from GIT on OpenSUSE 11.4 and am 
>>> experiencing a problem with IPv6 payload setup. It works but
>>> openvpn seems to be somewhat confused when setting up the v6
>>> route.
> [..]
>> Bug.  For workarounds, see above :-) and a patch will follow as soon
>> as I have cornered the bug (or have understood why this is not
>> happening for IPv4).
> 
> "lazy coder error".  OpenVPN in p2mp client mode saves certain(!)
> options before pulling options from the server (pre_pull_save() etc.
> in options.c) and this only happened for IPv4 - because, when adding
> IPv6 support, I just overlooked this code path.
> 
> So on reconnection, the IPv4 "route_option_list" was reset, and the 
> corresponding IPv6 "route_ipv6_option_list" wasn't - and thus, all
> the IPv6 routes were added to whatever was pushed by the server
> previously, leading to duplicate routes.
> 
> A patch is attached.  I have tested this here for various cases, and 
> with the patch, the problem is gone (as expected) and I haven't seen 
> any adverse cases.
> 
> Michal, if you could test that this fixes the problem for you, it
> would be great.
> 
> David, this patch is pretty much straightforward duplication of the 
> corresponding IPv4 code path.  It needs helpers in route.c, thus the 
> patch is somewhat bigger than expected...  but it should be "fairly 
> easy" to review.
> 

ACK.  Applied to master branch on -testing and -stable trees.

commit 9140223643f7d9bdfd2214304a7bd6ab4b662f97
Author: Gert Doering <g...@mobile.greenie.muc.de>
List-Post: openvpn-devel@lists.sourceforge.net
Date:   Fri Dec 30 21:08:49 2011 +0100

    Fix build-up of duplicate IPv6 routes on reconnect.

    options.c: extend pre_pull_save() and pre_pull_restore() to
           save/restore options->routes_ipv6 as well
    options.h: add routes_ipv6 to "struct options_pre_pull"
    route.h, route.c: add clone_route_ipv6_option_list() and
           copy_route_ipv6_option_list() helper functions

    Signed-off-by: Gert Doering <g...@greenie.muc.de>
    Acked-by: David Sommerseth <dav...@redhat.com>
    Signed-off-by: David Sommerseth <dav...@redhat.com>



kind regards,

David Sommerseth
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk8EPwAACgkQDC186MBRfrr2ZQCdH78BvqhxhOmJEI3Ur+3/q7XN
mwwAn25WhXEoQZa1PIkbW5H3sVTN1NDM
=jLpt
-----END PGP SIGNATURE-----

Reply via email to