1 |
71172088
|
jim-p
|
<?php
|
2 |
|
|
/*
|
3 |
|
|
vpn_ipsec_settings.php
|
4 |
|
|
|
5 |
d961e7e3
|
Renato Botelho
|
Copyright (C) 2015 Electric Sheep Fencing, LLC
|
6 |
71172088
|
jim-p
|
All rights reserved.
|
7 |
|
|
|
8 |
|
|
Redistribution and use in source and binary forms, with or without
|
9 |
|
|
modification, are permitted provided that the following conditions are met:
|
10 |
|
|
|
11 |
|
|
1. Redistributions of source code must retain the above copyright notice,
|
12 |
|
|
this list of conditions and the following disclaimer.
|
13 |
|
|
|
14 |
|
|
2. Redistributions in binary form must reproduce the above copyright
|
15 |
|
|
notice, this list of conditions and the following disclaimer in the
|
16 |
|
|
documentation and/or other materials provided with the distribution.
|
17 |
|
|
|
18 |
|
|
THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
|
19 |
|
|
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
|
20 |
|
|
AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
|
21 |
|
|
AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
|
22 |
|
|
OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
|
23 |
|
|
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
24 |
|
|
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
|
25 |
|
|
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
26 |
|
|
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
27 |
|
|
POSSIBILITY OF SUCH DAMAGE.
|
28 |
|
|
*/
|
29 |
|
|
|
30 |
|
|
##|+PRIV
|
31 |
|
|
##|*IDENT=page-vpn-ipsec-settings
|
32 |
|
|
##|*NAME=VPN: IPsec: Settings page
|
33 |
|
|
##|*DESCR=Allow access to the 'VPN: IPsec: Settings' page.
|
34 |
|
|
##|*MATCH=vpn_ipsec_settings.php*
|
35 |
|
|
##|-PRIV
|
36 |
|
|
|
37 |
|
|
require("functions.inc");
|
38 |
|
|
require("guiconfig.inc");
|
39 |
|
|
require_once("filter.inc");
|
40 |
|
|
require_once("shaper.inc");
|
41 |
|
|
require_once("ipsec.inc");
|
42 |
|
|
require_once("vpn.inc");
|
43 |
|
|
|
44 |
|
|
foreach ($ipsec_loglevels as $lkey => $ldescr) {
|
45 |
|
|
if (!empty($config['ipsec']["ipsec_{$lkey}"]))
|
46 |
|
|
$pconfig["ipsec_{$lkey}"] = $config['ipsec']["ipsec_{$lkey}"];
|
47 |
|
|
}
|
48 |
845f9f78
|
Ermal LUÇI
|
$pconfig['unityplugin'] = isset($config['ipsec']['unityplugin']);
|
49 |
7361628b
|
Chris Buechler
|
$pconfig['strictcrlpolicy'] = isset($config['ipsec']['strictcrlpolicy']);
|
50 |
1d839e6d
|
Ermal LUÇI
|
$pconfig['makebeforebreak'] = isset($config['ipsec']['makebeforebreak']);
|
51 |
c5292060
|
Chris Buechler
|
$pconfig['noshuntlaninterfaces'] = isset($config['ipsec']['noshuntlaninterfaces']);
|
52 |
d2884b9a
|
Chris Buechler
|
$pconfig['compression'] = isset($config['ipsec']['compression']);
|
53 |
eb6495c3
|
Chris Buechler
|
$pconfig['enableinterfacesuse'] = isset($config['ipsec']['enableinterfacesuse']);
|
54 |
737b18f2
|
Ermal
|
$pconfig['acceptunencryptedmainmode'] = isset($config['ipsec']['acceptunencryptedmainmode']);
|
55 |
71172088
|
jim-p
|
$pconfig['maxmss_enable'] = isset($config['system']['maxmss_enable']);
|
56 |
|
|
$pconfig['maxmss'] = $config['system']['maxmss'];
|
57 |
887f2517
|
Ermal LUÇI
|
$pconfig['uniqueids'] = $config['ipsec']['uniqueids'];
|
58 |
71172088
|
jim-p
|
|
59 |
6ae8b844
|
Ermal
|
if ($_POST) {
|
60 |
71172088
|
jim-p
|
|
61 |
|
|
unset($input_errors);
|
62 |
|
|
$pconfig = $_POST;
|
63 |
a96dc32e
|
Chris Buechler
|
|
64 |
f418fde4
|
Chris Buechler
|
if (!in_array($pconfig['ipsec_dmn'], array('1', '2', '3', '4', '5', '6'), true)) {
|
65 |
a96dc32e
|
Chris Buechler
|
$input_errors[] = "A valid value must be specified for Daemon debug.";
|
66 |
|
|
}
|
67 |
f418fde4
|
Chris Buechler
|
if (!in_array($pconfig['ipsec_mgr'], array('1', '2', '3', '4', '5', '6'), true)) {
|
68 |
a96dc32e
|
Chris Buechler
|
$input_errors[] = "A valid value must be specified for SA Manager debug.";
|
69 |
|
|
}
|
70 |
f418fde4
|
Chris Buechler
|
if (!in_array($pconfig['ipsec_ike'], array('1', '2', '3', '4', '5', '6'), true)) {
|
71 |
a96dc32e
|
Chris Buechler
|
$input_errors[] = "A valid value must be specified for IKE SA debug.";
|
72 |
|
|
}
|
73 |
f418fde4
|
Chris Buechler
|
if (!in_array($pconfig['ipsec_chd'], array('1', '2', '3', '4', '5', '6'), true)) {
|
74 |
a96dc32e
|
Chris Buechler
|
$input_errors[] = "A valid value must be specified for IKE Child SA debug.";
|
75 |
|
|
}
|
76 |
f418fde4
|
Chris Buechler
|
if (!in_array($pconfig['ipsec_job'], array('1', '2', '3', '4', '5', '6'), true)) {
|
77 |
a96dc32e
|
Chris Buechler
|
$input_errors[] = "A valid value must be specified for Job Processing debug.";
|
78 |
|
|
}
|
79 |
f418fde4
|
Chris Buechler
|
if (!in_array($pconfig['ipsec_cfg'], array('1', '2', '3', '4', '5', '6'), true)) {
|
80 |
a96dc32e
|
Chris Buechler
|
$input_errors[] = "A valid value must be specified for Configuration backend debug.";
|
81 |
|
|
}
|
82 |
f418fde4
|
Chris Buechler
|
if (!in_array($pconfig['ipsec_knl'], array('1', '2', '3', '4', '5', '6'), true)) {
|
83 |
a96dc32e
|
Chris Buechler
|
$input_errors[] = "A valid value must be specified for Kernel Interface debug.";
|
84 |
|
|
}
|
85 |
f418fde4
|
Chris Buechler
|
if (!in_array($pconfig['ipsec_net'], array('1', '2', '3', '4', '5', '6'), true)) {
|
86 |
a96dc32e
|
Chris Buechler
|
$input_errors[] = "A valid value must be specified for Networking debug.";
|
87 |
|
|
}
|
88 |
f418fde4
|
Chris Buechler
|
if (!in_array($pconfig['ipsec_asn'], array('1', '2', '3', '4', '5', '6'), true)) {
|
89 |
a96dc32e
|
Chris Buechler
|
$input_errors[] = "A valid value must be specified for ASN Encoding debug.";
|
90 |
|
|
}
|
91 |
f418fde4
|
Chris Buechler
|
if (!in_array($pconfig['ipsec_enc'], array('1', '2', '3', '4', '5', '6'), true)) {
|
92 |
a96dc32e
|
Chris Buechler
|
$input_errors[] = "A valid value must be specified for Message encoding debug.";
|
93 |
|
|
}
|
94 |
f418fde4
|
Chris Buechler
|
if (!in_array($pconfig['ipsec_imc'], array('1', '2', '3', '4', '5', '6'), true)) {
|
95 |
a96dc32e
|
Chris Buechler
|
$input_errors[] = "A valid value must be specified for Integrity checker debug.";
|
96 |
|
|
}
|
97 |
f418fde4
|
Chris Buechler
|
if (!in_array($pconfig['ipsec_imv'], array('1', '2', '3', '4', '5', '6'), true)) {
|
98 |
a96dc32e
|
Chris Buechler
|
$input_errors[] = "A valid value must be specified for Integrity Verifier debug.";
|
99 |
|
|
}
|
100 |
f418fde4
|
Chris Buechler
|
if (!in_array($pconfig['ipsec_pts'], array('1', '2', '3', '4', '5', '6'), true)) {
|
101 |
a96dc32e
|
Chris Buechler
|
$input_errors[] = "A valid value must be specified for Platform Trust Service debug.";
|
102 |
|
|
}
|
103 |
f418fde4
|
Chris Buechler
|
if (!in_array($pconfig['ipsec_tls'], array('1', '2', '3', '4', '5', '6'), true)) {
|
104 |
a96dc32e
|
Chris Buechler
|
$input_errors[] = "A valid value must be specified for TLS Handler debug.";
|
105 |
|
|
}
|
106 |
f418fde4
|
Chris Buechler
|
if (!in_array($pconfig['ipsec_esp'], array('1', '2', '3', '4', '5', '6'), true)) {
|
107 |
a96dc32e
|
Chris Buechler
|
$input_errors[] = "A valid value must be specified for IPsec Traffic debug.";
|
108 |
|
|
}
|
109 |
f418fde4
|
Chris Buechler
|
if (!in_array($pconfig['ipsec_lib'], array('1', '2', '3', '4', '5', '6'), true)) {
|
110 |
a96dc32e
|
Chris Buechler
|
$input_errors[] = "A valid value must be specified for StrongSwan Lib debug.";
|
111 |
|
|
}
|
112 |
|
|
if (isset($pconfig['maxmss'])) {
|
113 |
|
|
if (!is_numericint($pconfig['maxmss']) && $pconfig['maxmss'] <> '') {
|
114 |
|
|
$input_errors[] = "An integer must be specified for Maximum MSS.";
|
115 |
|
|
}
|
116 |
|
|
if ($pconfig['maxmss'] <> '' && $pconfig['maxmss'] < 576 || $pconfig['maxmss'] > 65535)
|
117 |
|
|
$input_errors[] = "An integer between 576 and 65535 must be specified for Maximum MSS";
|
118 |
|
|
}
|
119 |
|
|
|
120 |
71172088
|
jim-p
|
if (!$input_errors) {
|
121 |
|
|
|
122 |
b3bcc729
|
Phil Davis
|
foreach ($ipsec_loglevels as $lkey => $ldescr) {
|
123 |
|
|
if (empty($_POST["ipsec_{$lkey}"])) {
|
124 |
|
|
if (isset($config['ipsec']["ipsec_{$lkey}"])) {
|
125 |
|
|
unset($config['ipsec']["ipsec_{$lkey}"]);
|
126 |
|
|
}
|
127 |
|
|
} else {
|
128 |
|
|
$config['ipsec']["ipsec_{$lkey}"] = $_POST["ipsec_{$lkey}"];
|
129 |
71172088
|
jim-p
|
}
|
130 |
|
|
}
|
131 |
|
|
|
132 |
41da54ce
|
Ermal LUÇI
|
$needsrestart = false;
|
133 |
|
|
|
134 |
|
|
if($_POST['compression'] == "yes") {
|
135 |
|
|
if (!isset($config['ipsec']['compression']))
|
136 |
|
|
$needsrestart = true;
|
137 |
d2884b9a
|
Chris Buechler
|
$config['ipsec']['compression'] = true;
|
138 |
41da54ce
|
Ermal LUÇI
|
} elseif (isset($config['ipsec']['compression'])) {
|
139 |
|
|
$needsrestart = true;
|
140 |
d2884b9a
|
Chris Buechler
|
unset($config['ipsec']['compression']);
|
141 |
41da54ce
|
Ermal LUÇI
|
}
|
142 |
eb6495c3
|
Chris Buechler
|
|
143 |
|
|
if($_POST['enableinterfacesuse'] == "yes") {
|
144 |
|
|
if (!isset($config['ipsec']['enableinterfacesuse']))
|
145 |
|
|
$needsrestart = true;
|
146 |
|
|
$config['ipsec']['enableinterfacesuse'] = true;
|
147 |
|
|
} elseif (isset($config['ipsec']['enableinterfacesuse'])) {
|
148 |
|
|
$needsrestart = true;
|
149 |
|
|
unset($config['ipsec']['enableinterfacesuse']);
|
150 |
|
|
}
|
151 |
71172088
|
jim-p
|
|
152 |
41da54ce
|
Ermal LUÇI
|
if($_POST['unityplugin'] == "yes") {
|
153 |
|
|
if (!isset($config['ipsec']['unityplugin']))
|
154 |
|
|
$needsrestart = true;
|
155 |
845f9f78
|
Ermal LUÇI
|
$config['ipsec']['unityplugin'] = true;
|
156 |
41da54ce
|
Ermal LUÇI
|
} elseif (isset($config['ipsec']['unityplugin'])) {
|
157 |
|
|
$needsrestart = true;
|
158 |
845f9f78
|
Ermal LUÇI
|
unset($config['ipsec']['unityplugin']);
|
159 |
41da54ce
|
Ermal LUÇI
|
}
|
160 |
7361628b
|
Chris Buechler
|
|
161 |
|
|
if ($_POST['strictcrlpolicy'] == "yes") {
|
162 |
|
|
$config['ipsec']['strictcrlpolicy'] = true;
|
163 |
241c48ef
|
Phil Davis
|
} elseif (isset($config['ipsec']['strictcrlpolicy'])) {
|
164 |
7361628b
|
Chris Buechler
|
unset($config['ipsec']['strictcrlpolicy']);
|
165 |
|
|
}
|
166 |
845f9f78
|
Ermal LUÇI
|
|
167 |
1d839e6d
|
Ermal LUÇI
|
if($_POST['makebeforebreak'] == "yes") {
|
168 |
|
|
$config['ipsec']['makebeforebreak'] = true;
|
169 |
|
|
} elseif (isset($config['ipsec']['makebeforebreak'])) {
|
170 |
|
|
unset($config['ipsec']['makebeforebreak']);
|
171 |
|
|
}
|
172 |
|
|
|
173 |
cc31dc7a
|
Chris Buechler
|
/* The weird logic here is to avoid negative policies when checked #4655 */
|
174 |
b3bcc729
|
Phil Davis
|
if ($_POST['noshuntlaninterfaces'] == "yes") {
|
175 |
|
|
if (isset($config['ipsec']['noshuntlaninterfaces'])) {
|
176 |
|
|
unset($config['ipsec']['noshuntlaninterfaces']);
|
177 |
|
|
}
|
178 |
1c7fd09e
|
Ermal LUÇI
|
} else {
|
179 |
|
|
$config['ipsec']['noshuntlaninterfaces'] = true;
|
180 |
53475389
|
Ermal LUÇI
|
}
|
181 |
|
|
|
182 |
41da54ce
|
Ermal LUÇI
|
if($_POST['acceptunencryptedmainmode'] == "yes") {
|
183 |
|
|
if (!isset($config['ipsec']['acceptunencryptedmainmode']))
|
184 |
|
|
$needsrestart = true;
|
185 |
737b18f2
|
Ermal
|
$config['ipsec']['acceptunencryptedmainmode'] = true;
|
186 |
41da54ce
|
Ermal LUÇI
|
} elseif (isset($config['ipsec']['acceptunencryptedmainmode'])) {
|
187 |
|
|
$needsrestart = true;
|
188 |
737b18f2
|
Ermal
|
unset($config['ipsec']['acceptunencryptedmainmode']);
|
189 |
41da54ce
|
Ermal LUÇI
|
}
|
190 |
737b18f2
|
Ermal
|
|
191 |
908edbd3
|
Ermal LUÇI
|
if(!empty($_POST['uniqueids'])) {
|
192 |
|
|
$config['ipsec']['uniqueids'] = $_POST['uniqueids'];
|
193 |
b3bcc729
|
Phil Davis
|
} else if (isset($config['ipsec']['uniqueids'])) {
|
194 |
908edbd3
|
Ermal LUÇI
|
unset($config['ipsec']['uniqueids']);
|
195 |
|
|
}
|
196 |
|
|
|
197 |
71172088
|
jim-p
|
if($_POST['maxmss_enable'] == "yes") {
|
198 |
|
|
$config['system']['maxmss_enable'] = true;
|
199 |
|
|
$config['system']['maxmss'] = $_POST['maxmss'];
|
200 |
|
|
} else {
|
201 |
b3bcc729
|
Phil Davis
|
if (isset($config['system']['maxmss_enable'])) {
|
202 |
|
|
unset($config['system']['maxmss_enable']);
|
203 |
|
|
}
|
204 |
|
|
if (isset($config['system']['maxmss'])) {
|
205 |
|
|
unset($config['system']['maxmss']);
|
206 |
|
|
}
|
207 |
71172088
|
jim-p
|
}
|
208 |
|
|
|
209 |
|
|
write_config();
|
210 |
|
|
|
211 |
|
|
$retval = 0;
|
212 |
|
|
$retval = filter_configure();
|
213 |
|
|
if(stristr($retval, "error") <> true)
|
214 |
|
|
$savemsg = get_std_save_message(gettext($retval));
|
215 |
|
|
else
|
216 |
|
|
$savemsg = gettext($retval);
|
217 |
|
|
|
218 |
41da54ce
|
Ermal LUÇI
|
vpn_ipsec_configure($needsrestart);
|
219 |
71172088
|
jim-p
|
vpn_ipsec_configure_loglevels();
|
220 |
d6084ab0
|
Ermal LUÇI
|
|
221 |
|
|
header("Location: vpn_ipsec_settings.php");
|
222 |
|
|
return;
|
223 |
da6faa2b
|
Ermal LUÇI
|
}
|
224 |
|
|
|
225 |
|
|
// The logic value sent by $POST is opposite to the way it is stored in the config.
|
226 |
|
|
// Reset the $pconfig value so it reflects the opposite of what was $POSTed.
|
227 |
|
|
if ($_POST['noshuntlaninterfaces'] == "yes") {
|
228 |
|
|
$pconfig['noshuntlaninterfaces'] = false;
|
229 |
|
|
} else {
|
230 |
|
|
$pconfig['noshuntlaninterfaces'] = true;
|
231 |
|
|
}
|
232 |
71172088
|
jim-p
|
}
|
233 |
|
|
|
234 |
|
|
$pgtitle = array(gettext("VPN"),gettext("IPsec"),gettext("Settings"));
|
235 |
|
|
$shortcut_section = "ipsec";
|
236 |
|
|
|
237 |
|
|
include("head.inc");
|
238 |
|
|
?>
|
239 |
|
|
|
240 |
|
|
<body link="#0000CC" vlink="#0000CC" alink="#0000CC">
|
241 |
|
|
<?php include("fbegin.inc"); ?>
|
242 |
|
|
|
243 |
|
|
<script type="text/javascript">
|
244 |
391453a1
|
Colin Fleming
|
//<![CDATA[
|
245 |
71172088
|
jim-p
|
|
246 |
|
|
function maxmss_checked(obj) {
|
247 |
|
|
if (obj.checked)
|
248 |
|
|
jQuery('#maxmss').attr('disabled',false);
|
249 |
|
|
else
|
250 |
|
|
jQuery('#maxmss').attr('disabled','true');
|
251 |
|
|
}
|
252 |
|
|
|
253 |
391453a1
|
Colin Fleming
|
//]]>
|
254 |
71172088
|
jim-p
|
</script>
|
255 |
|
|
|
256 |
|
|
<form action="vpn_ipsec_settings.php" method="post" name="iform" id="iform">
|
257 |
|
|
|
258 |
|
|
<?php
|
259 |
|
|
if ($savemsg)
|
260 |
|
|
print_info_box($savemsg);
|
261 |
|
|
if ($input_errors)
|
262 |
|
|
print_input_errors($input_errors);
|
263 |
|
|
?>
|
264 |
|
|
|
265 |
391453a1
|
Colin Fleming
|
<table width="100%" border="0" cellpadding="0" cellspacing="0" summary="vpn ipsec settings">
|
266 |
71172088
|
jim-p
|
<tr>
|
267 |
|
|
<td class="tabnavtbl">
|
268 |
|
|
<?php
|
269 |
|
|
$tab_array = array();
|
270 |
|
|
$tab_array[0] = array(gettext("Tunnels"), false, "vpn_ipsec.php");
|
271 |
|
|
$tab_array[1] = array(gettext("Mobile clients"), false, "vpn_ipsec_mobile.php");
|
272 |
|
|
$tab_array[2] = array(gettext("Pre-Shared Key"), false, "vpn_ipsec_keys.php");
|
273 |
|
|
$tab_array[3] = array(gettext("Advanced Settings"), true, "vpn_ipsec_settings.php");
|
274 |
|
|
display_top_tabs($tab_array);
|
275 |
|
|
?>
|
276 |
|
|
</td>
|
277 |
|
|
</tr>
|
278 |
|
|
<tr>
|
279 |
|
|
<td id="mainarea">
|
280 |
|
|
<div class="tabcont">
|
281 |
391453a1
|
Colin Fleming
|
<table width="100%" border="0" cellpadding="6" cellspacing="0" summary="main area">
|
282 |
71172088
|
jim-p
|
<tr>
|
283 |
3c4fc30b
|
Chris Buechler
|
<td colspan="2" valign="top" class="listtopic"><?=gettext("IPsec Advanced Settings"); ?></td>
|
284 |
71172088
|
jim-p
|
</tr>
|
285 |
|
|
<tr>
|
286 |
|
|
<td width="22%" valign="top" class="vncell"><?=gettext("IPsec Debug"); ?></td>
|
287 |
|
|
<td width="78%" class="vtable">
|
288 |
3c4fc30b
|
Chris Buechler
|
<strong><?=gettext("Start IPsec in debug mode based on sections selected"); ?></strong>
|
289 |
71172088
|
jim-p
|
<br />
|
290 |
391453a1
|
Colin Fleming
|
<table summary="ipsec debug">
|
291 |
71172088
|
jim-p
|
<?php foreach ($ipsec_loglevels as $lkey => $ldescr): ?>
|
292 |
|
|
<tr>
|
293 |
|
|
<td width="22%" valign="top" class="vncell"><?=$ldescr;?></td>
|
294 |
|
|
<td width="78%" valign="top" class="vncell">
|
295 |
|
|
<?php echo "<select name=\"ipsec_{$lkey}\" id=\"ipsec_{$lkey}\">\n";
|
296 |
|
|
foreach (array("Silent", "Audit", "Control", "Diag", "Raw", "Highest") as $lidx => $lvalue) {
|
297 |
5d6dde8a
|
Chris Buechler
|
$logval = $lidx + 1;
|
298 |
|
|
if (isset($pconfig["ipsec_{$lkey}"])) {
|
299 |
d25eda8d
|
Chris Buechler
|
if ($pconfig["ipsec_{$lkey}"] == $logval) {
|
300 |
|
|
$logselected = $logval;
|
301 |
|
|
}
|
302 |
5d6dde8a
|
Chris Buechler
|
} else {
|
303 |
b4140b14
|
Chris Buechler
|
$logselected = "3";
|
304 |
5d6dde8a
|
Chris Buechler
|
}
|
305 |
|
|
echo "<option value=\"{$logval}\" ";
|
306 |
|
|
if ($logselected == $logval)
|
307 |
71172088
|
jim-p
|
echo "selected=\"selected\"";
|
308 |
|
|
echo ">{$lvalue}</option>\n";
|
309 |
|
|
}
|
310 |
|
|
?>
|
311 |
|
|
</select>
|
312 |
|
|
</td>
|
313 |
|
|
</tr>
|
314 |
|
|
<?php endforeach; ?>
|
315 |
391453a1
|
Colin Fleming
|
<tr style="display:none;"><td></td></tr>
|
316 |
71172088
|
jim-p
|
</table>
|
317 |
3c4fc30b
|
Chris Buechler
|
<br /><?=gettext("Launches IPsec in debug mode so that more verbose logs " .
|
318 |
71172088
|
jim-p
|
"will be generated to aid in troubleshooting."); ?>
|
319 |
|
|
</td>
|
320 |
|
|
</tr>
|
321 |
908edbd3
|
Ermal LUÇI
|
<tr>
|
322 |
|
|
<td width="22%" valign="top" class="vncell"><?=gettext("Unique IDs"); ?></td>
|
323 |
|
|
<td width="78%" class="vtable">
|
324 |
3d67c650
|
Chris Buechler
|
<strong><?=gettext("Configure Unique IDs as: "); ?></strong>
|
325 |
908edbd3
|
Ermal LUÇI
|
<?php echo "<select name=\"uniqueids\" id=\"uniqueids\">\n";
|
326 |
|
|
foreach ($ipsec_idhandling as $value => $lvalue) {
|
327 |
|
|
echo "<option value=\"{$value}\" ";
|
328 |
|
|
if ($pconfig['uniqueids'] == $value)
|
329 |
|
|
echo "selected=\"selected\"";
|
330 |
|
|
echo ">{$lvalue}</option>\n";
|
331 |
|
|
}
|
332 |
|
|
?>
|
333 |
|
|
</select>
|
334 |
|
|
<br />
|
335 |
|
|
<?=gettext("whether a particular participant ID should be kept unique, with any new IKE_SA using an ID " .
|
336 |
|
|
"deemed to replace all old ones using that ID. Participant IDs normally are unique, so a new " .
|
337 |
|
|
"IKE_SA using the same ID is almost invariably intended to replace an old one. " .
|
338 |
|
|
"The difference between <b>no</b> and <b>never</b> is that the old IKE_SAs will be replaced when receiving an " .
|
339 |
|
|
"INITIAL_CONTACT notify if the option is no but will ignore these notifies if <b>never</b> is configured. " .
|
340 |
|
|
"The daemon also accepts the value <b>keep</b> to reject " .
|
341 |
3d67c650
|
Chris Buechler
|
"new IKE_SA setups and keep the duplicate established earlier. Defaults to Yes."); ?>
|
342 |
908edbd3
|
Ermal LUÇI
|
</td>
|
343 |
|
|
</tr>
|
344 |
71172088
|
jim-p
|
<tr>
|
345 |
45efe1b6
|
Ermal LUÇI
|
<td width="22%" valign="top" class="vncell"><?=gettext("IP Compression"); ?></td>
|
346 |
71172088
|
jim-p
|
<td width="78%" class="vtable">
|
347 |
d2884b9a
|
Chris Buechler
|
<input name="compression" type="checkbox" id="compression" value="yes" <?php if ($pconfig['compression']) echo "checked=\"checked\""; ?> />
|
348 |
45efe1b6
|
Ermal LUÇI
|
<strong><?=gettext("Enable IPCompression"); ?></strong>
|
349 |
71172088
|
jim-p
|
<br />
|
350 |
2a8a09a9
|
Chris Buechler
|
<?=gettext("IPComp compression of content is proposed on the connection."); ?>
|
351 |
71172088
|
jim-p
|
</td>
|
352 |
|
|
</tr>
|
353 |
eb6495c3
|
Chris Buechler
|
<tr>
|
354 |
|
|
<td width="22%" valign="top" class="vncell"><?=gettext("Strict interface binding"); ?></td>
|
355 |
|
|
<td width="78%" class="vtable">
|
356 |
|
|
<input name="enableinterfacesuse" type="checkbox" id="enableinterfacesuse" value="yes" <?php if ($pconfig['enableinterfacesuse']) echo "checked=\"checked\""; ?> />
|
357 |
|
|
<strong><?=gettext("Enable strict interface binding"); ?></strong>
|
358 |
|
|
<br />
|
359 |
|
|
<?=gettext("Enable strongSwan's interfaces_use option to bind specific interfaces only. This option is known to break IPsec with dynamic IP interfaces. This is not recommended at this time."); ?>
|
360 |
|
|
</td>
|
361 |
|
|
</tr>
|
362 |
737b18f2
|
Ermal
|
<tr>
|
363 |
|
|
<td width="22%" valign="top" class="vncell"><?=gettext("Unencrypted payloads in IKEv1 Main Mode"); ?></td>
|
364 |
|
|
<td width="78%" class="vtable">
|
365 |
|
|
<input name="acceptunencryptedmainmode" type="checkbox" id="acceptunencryptedmainmode" value="yes" <?php if ($pconfig['acceptunencryptedmainmode']) echo "checked=\"checked\""; ?> />
|
366 |
|
|
<strong><?=gettext("Accept unencrypted ID and HASH payloads in IKEv1 Main Mode"); ?></strong>
|
367 |
|
|
<br />
|
368 |
|
|
<?=gettext("Some implementations send the third Main Mode message unencrypted, probably to find the PSKs for the specified ID for authentication." .
|
369 |
|
|
"This is very similar to Aggressive Mode, and has the same security implications: " .
|
370 |
|
|
"A passive attacker can sniff the negotiated Identity, and start brute forcing the PSK using the HASH payload." .
|
371 |
|
|
" It is recommended to keep this option to no, unless you know exactly what the implications are and require compatibility to such devices (for example, some SonicWall boxes).");?>
|
372 |
|
|
</td>
|
373 |
|
|
</tr>
|
374 |
71172088
|
jim-p
|
<tr>
|
375 |
|
|
<td width="22%" valign="top" class="vncell"><?=gettext("Maximum MSS"); ?></td>
|
376 |
|
|
<td width="78%" class="vtable">
|
377 |
|
|
<input name="maxmss_enable" type="checkbox" id="maxmss_enable" value="yes" <?php if ($pconfig['maxmss_enable'] == true) echo "checked=\"checked\""; ?> onclick="maxmss_checked(this)" />
|
378 |
|
|
<strong><?=gettext("Enable MSS clamping on VPN traffic"); ?></strong>
|
379 |
|
|
<br />
|
380 |
7a29e654
|
jim-p
|
<input name="maxmss" id="maxmss" value="<?php if ($pconfig['maxmss'] <> "") echo htmlspecialchars($pconfig['maxmss']); else "1400"; ?>" class="formfld unknown" <?php if ($pconfig['maxmss_enable'] == false) echo "disabled=\"disabled\""; ?> />
|
381 |
71172088
|
jim-p
|
<br />
|
382 |
|
|
<?=gettext("Enable MSS clamping on TCP flows over VPN. " .
|
383 |
|
|
"This helps overcome problems with PMTUD on IPsec VPN links. If left blank, the default value is 1400 bytes. "); ?>
|
384 |
|
|
</td>
|
385 |
|
|
</tr>
|
386 |
845f9f78
|
Ermal LUÇI
|
<tr>
|
387 |
|
|
<td width="22%" valign="top" class="vncell"><?=gettext("Disable Cisco Extensions"); ?></td>
|
388 |
|
|
<td width="78%" class="vtable">
|
389 |
|
|
<input name="unityplugin" type="checkbox" id="unityplugin" value="yes" <?php if ($pconfig['unityplugin'] == true) echo "checked=\"checked\""; ?> />
|
390 |
|
|
<strong><?=gettext("Disable Unity Plugin"); ?></strong>
|
391 |
|
|
<br />
|
392 |
|
|
<?=gettext("Disable Unity Plugin which provides Cisco Extension support as Split-Include, Split-Exclude, Split-Dns, ..."); ?>
|
393 |
|
|
</td>
|
394 |
|
|
</tr>
|
395 |
7361628b
|
Chris Buechler
|
<tr>
|
396 |
|
|
<td width="22%" valign="top" class="vncell"><?=gettext("Strict CRL Checking"); ?></td>
|
397 |
|
|
<td width="78%" class="vtable">
|
398 |
|
|
<input name="strictcrlpolicy" type="checkbox" id="strictcrlpolicy" value="yes" <?php if ($pconfig['strictcrlpolicy'] == true) echo "checked=\"checked\""; ?> />
|
399 |
|
|
<strong><?=gettext("Enable strict Certificate Revocation List checking"); ?></strong>
|
400 |
|
|
<br />
|
401 |
|
|
<?=gettext("Check this to require availability of a fresh CRL for peer authentication based on RSA signatures to succeed."); ?>
|
402 |
|
|
</td>
|
403 |
|
|
</tr>
|
404 |
1d839e6d
|
Ermal LUÇI
|
<tr>
|
405 |
|
|
<td width="22%" valign="top" class="vncell"><?=gettext("Make before Break"); ?></td>
|
406 |
|
|
<td width="78%" class="vtable">
|
407 |
|
|
<input name="makebeforebreak" type="checkbox" id="makebeforebreak" value="yes" <?php if ($pconfig['makebeforebreak'] == true) echo "checked=\"checked\""; ?> />
|
408 |
|
|
<strong><?=gettext("Initiate IKEv2 reauthentication with a make-before-break"); ?></strong>
|
409 |
|
|
<br />
|
410 |
|
|
<?=gettext("instead of a break-before-make scheme. Make-before-break uses overlapping IKE and CHILD_SA during reauthentication " .
|
411 |
|
|
"by first recreating all new SAs before deleting the old ones. This behavior can be beneficial to avoid connectivity gaps " .
|
412 |
|
|
"during reauthentication, but requires support for overlapping SAs by the peer.");?>
|
413 |
|
|
</td>
|
414 |
|
|
</tr>
|
415 |
53475389
|
Ermal LUÇI
|
<tr>
|
416 |
c5292060
|
Chris Buechler
|
<td width="22%" valign="top" class="vncell"><?=gettext("Auto-exclude LAN address"); ?></td>
|
417 |
53475389
|
Ermal LUÇI
|
<td width="78%" class="vtable">
|
418 |
ee72e2ca
|
Chris Buechler
|
<input name="noshuntlaninterfaces" type="checkbox" id="noshuntlaninterfaces" value="yes" <?php if ($pconfig['noshuntlaninterfaces'] != true) echo "checked=\"checked\""; ?> />
|
419 |
c5292060
|
Chris Buechler
|
<strong><?=gettext("Enable bypass for LAN interface IP"); ?></strong>
|
420 |
53475389
|
Ermal LUÇI
|
<br />
|
421 |
c5292060
|
Chris Buechler
|
<?=gettext("Exclude traffic from LAN subnet to LAN IP address from IPsec."); ?>
|
422 |
53475389
|
Ermal LUÇI
|
</td>
|
423 |
|
|
</tr>
|
424 |
71172088
|
jim-p
|
<tr>
|
425 |
|
|
<td width="22%" valign="top"> </td>
|
426 |
|
|
<td width="78%">
|
427 |
391453a1
|
Colin Fleming
|
<input name="submit" type="submit" class="formbtn" value="<?=gettext("Save"); ?>" />
|
428 |
71172088
|
jim-p
|
</td>
|
429 |
|
|
</tr>
|
430 |
|
|
</table>
|
431 |
|
|
</div>
|
432 |
|
|
</td>
|
433 |
|
|
</tr>
|
434 |
|
|
</table>
|
435 |
|
|
</form>
|
436 |
|
|
<?php include("fend.inc"); ?>
|
437 |
|
|
</body>
|
438 |
|
|
</html>
|