]> git.gsnw.org Git - m0n0chwall.git/commitdiff
Omit 3rd DNS server in mpd.conf (PPTP VPN), if specified (-> jdegraeve). Fix handling...
authormkasper <mkasper@e36fee2c-cc09-0410-a7cc-ebac5c6737de>
Tue, 21 Mar 2006 17:59:00 +0000 (17:59 +0000)
committermkasper <mkasper@e36fee2c-cc09-0410-a7cc-ebac5c6737de>
Tue, 21 Mar 2006 17:59:00 +0000 (17:59 +0000)
git-svn-id: https://svn.m0n0.ch/wall/trunk@106 e36fee2c-cc09-0410-a7cc-ebac5c6737de

phpconf/inc/vpn.inc
webgui/firewall_rules_edit.php

index 31038bf66052461d3a38fff530490ea646e7335f..4ceac4108d668c912c05baaa596e18c737ad3291 100644 (file)
@@ -555,7 +555,7 @@ EOD;
                                        $mpdconf .= " " . $syscfg['dnsserver'][0];
                                $mpdconf .= "\n";
                        } else if (is_array($syscfg['dnsserver']) && ($syscfg['dnsserver'][0])) {
-                               $mpdconf .= "   set ipcp dns " . join(" ", $syscfg['dnsserver']) . "\n";
+                               $mpdconf .= "   set ipcp dns " . join(" ", array_slice($syscfg['dnsserver'], 0, 2)) . "\n";
                        }
                        
                        if (isset($pptpdcfg['radius']['enable'])) {
index 78b56184f6a8878108d791b8204cad2569e636f7..4339457af452a14fc66ab3a458ff5a9372ccab7f 100755 (executable)
@@ -57,7 +57,7 @@ if (isset($_GET['dup'])) {
 function is_specialnet($net) {
        global $specialsrcdst;
        
-       if (in_array($net, $specialsrcdst) || strstr($net, "opt"))
+       if (in_array($net, $specialsrcdst) || (strstr($net, "opt") && !is_alias($net)))
                return true;
        else
                return false;