summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xscripts/vpn-config.pl10
-rw-r--r--templates/vpn/ipsec/include-ipsec-conf/node.def2
2 files changed, 12 insertions, 0 deletions
diff --git a/scripts/vpn-config.pl b/scripts/vpn-config.pl
index b974a5a..7dd18f1 100755
--- a/scripts/vpn-config.pl
+++ b/scripts/vpn-config.pl
@@ -1160,6 +1160,16 @@ if ($vcVPN->exists('ipsec')) {
}
}
}
+
+ #
+ # Include a custom configuration file
+ #
+ my $custom_include = $vcVPN->returnValue("ipsec include-ipsec-conf");
+ if (defined($custom_include)) {
+ if ( ! -e $custom_include ) {
+ vpn_die(["vpn","ipsec","include-ipsec-conf"],"$vpn_cfg_err The specified file for inclusion inside ipsec.conf does not exist.");
+ }
+ }
if (-e '/etc/dmvpn.conf') {
$genout .= "\ninclude /etc/dmvpn.conf\n";
}
diff --git a/templates/vpn/ipsec/include-ipsec-conf/node.def b/templates/vpn/ipsec/include-ipsec-conf/node.def
new file mode 100644
index 0000000..fc82a45
--- /dev/null
+++ b/templates/vpn/ipsec/include-ipsec-conf/node.def
@@ -0,0 +1,2 @@
+type: txt
+help: Sets to include an additional configuration directive file for strongSwan. Use an absolute path to specify the included file.