Quantcast
Viewing all articles
Browse latest Browse all 60861

Re: Unable to use IPsec over IPv6 [Bug]

I discovered the cause.

 

/opt/vyatta/sbin/vpn-config.pl:534-539

This code causes,

if (!defined($leftsubnet_proto)) {
    $leftsubnet_proto = 0;
}
if (!defined($remotesubnet_proto)) {
    $remotesubnet_proto = 0;
}

 

/opt/vyatta/sbin/vpn-config.pl:559-564

vpn_die(["vpn", "ipsec", "site-to-site", "peer", $peer, "tunnel", $tunnel], "$vpn_cfg_err IPv4 over IPv6 IPsec is not supported")
    if (
    $conn_is_v6&& (defined $leftsubnet_proto
        and $leftsubnet_proto != 6)
    );

This contitional judgment is always true.("0" is judged "defined"), then output the message "VPN configuration error: IPv4 over IPv6 IPsec is not supported"

 

This code should be fixed like this

 

vpn_die(["vpn", "ipsec", "site-to-site", "peer", $peer, "tunnel", $tunnel], "$vpn_cfg_err IPv4 over IPv6 IPsec is not supported")
    if (
    $conn_is_v6&& ($leftsubnet_proto != 0
        and $leftsubnet_proto != 6)
    );

 


Viewing all articles
Browse latest Browse all 60861

Trending Articles