summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorKim Hagen <kim.sidney@gmail.com>2016-02-11 12:17:51 -0500
committerKim Hagen <kim.sidney@gmail.com>2016-02-11 12:17:51 -0500
commit2cda998101aa8d83ab92e9d3d1abddf672ac2c2d (patch)
treec3ad0628ee1c2d3c77bae812d7e1f157ca9f9382 /scripts
parent849551db87c42494d7c44fd463aebba003ba978e (diff)
downloadvyatta-cfg-vpn-2cda998101aa8d83ab92e9d3d1abddf672ac2c2d.tar.gz
vyatta-cfg-vpn-2cda998101aa8d83ab92e9d3d1abddf672ac2c2d.zip
Revert "Remove charonstart an interfaces from ipsec.conf file, they are depricated."
This reverts commit fbddff7f2b6b485c93b5d3cf4d60a75f84c3a2b6.
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/vpn-config.pl4
1 files changed, 4 insertions, 0 deletions
diff --git a/scripts/vpn-config.pl b/scripts/vpn-config.pl
index 5c00e08..635c416 100755
--- a/scripts/vpn-config.pl
+++ b/scripts/vpn-config.pl
@@ -217,6 +217,7 @@ if ($vcVPN->exists('ipsec')) {
$genout .= "version 2.0\n";
$genout .= "\n";
$genout .= "config setup\n";
+ $genout .= "\tcharonstart=yes\n";
#
# Interfaces
@@ -232,6 +233,7 @@ if ($vcVPN->exists('ipsec')) {
# not used, though we do need to include the line and the keyword
# "%none" to keep the IPsec setup code from defaulting the entry.
if ($using_klips) {
+ $genout .= "\tinterfaces=\"";
my $counter = 0;
foreach my $interface (@interfaces) {
if (!(-d "/sys/class/net/$interface")) {
@@ -262,6 +264,8 @@ if ($vcVPN->exists('ipsec')) {
++$counter;
}
$genout .= '%defaultroute"';
+ } else {
+ $genout .= 'interfaces="%none"';
}
$genout .= "\n";
}