summaryrefslogtreecommitdiffstats
path: root/src/usr/local
diff options
context:
space:
mode:
Diffstat (limited to 'src/usr/local')
-rw-r--r--src/usr/local/www/guiconfig.inc2
-rw-r--r--src/usr/local/www/pkg_edit.php8
-rw-r--r--src/usr/local/www/services_snmp.php24
-rw-r--r--src/usr/local/www/system_advanced_network.php18
-rw-r--r--src/usr/local/www/vpn_ipsec_settings.php27
5 files changed, 46 insertions, 33 deletions
diff --git a/src/usr/local/www/guiconfig.inc b/src/usr/local/www/guiconfig.inc
index d4fc383..ab9fa09 100644
--- a/src/usr/local/www/guiconfig.inc
+++ b/src/usr/local/www/guiconfig.inc
@@ -508,7 +508,7 @@ function genhtmltitle($title) {
$bc = "";
}
- return $heading . $bc;
+ return $bc;
}
/* update the changedesc and changecount(er) variables */
diff --git a/src/usr/local/www/pkg_edit.php b/src/usr/local/www/pkg_edit.php
index bfb4514..ba8815d 100644
--- a/src/usr/local/www/pkg_edit.php
+++ b/src/usr/local/www/pkg_edit.php
@@ -1500,6 +1500,10 @@ if ($pkg['custom_php_after_form_command']) {
eval($pkg['custom_php_after_form_command']);
}
+
+$hidemsg = gettext("Show Advanced Options");
+$showmsg = gettext("Hide Advanced Options");
+
if ($pkg['fields']['field'] != "") { ?>
<script type="text/javascript">
//<![CDATA[
@@ -1520,10 +1524,10 @@ if ($pkg['fields']['field'] != "") { ?>
if (advanced_visible) {
$('.advancedoptions').show();
- $("#showadv").prop('value', 'Hide advanced Options');
+ $("#showadv").html('<i class="fa fa-cog icon-embed-btn"></i>' + "<?=$showmsg?>");
} else {
$('.advancedoptions').hide();
- $("#showadv").prop('value', 'Show advanced Options');
+ $("#showadv").html('<i class="fa fa-cog icon-embed-btn"></i>' + "<?=$hidemsg?>");
}
});
diff --git a/src/usr/local/www/services_snmp.php b/src/usr/local/www/services_snmp.php
index 66caf4f..e138300 100644
--- a/src/usr/local/www/services_snmp.php
+++ b/src/usr/local/www/services_snmp.php
@@ -33,6 +33,8 @@
require_once("guiconfig.inc");
require_once("functions.inc");
+$specplatform = system_identify_specific_platform();
+
if (!is_array($config['snmpd'])) {
$config['snmpd'] = array();
$config['snmpd']['rocommunity'] = "public";
@@ -316,12 +318,14 @@ $group->add(new Form_MultiCheckbox(
$pconfig['pf']
));
-$group->add(new Form_MultiCheckbox(
- 'hostres',
- null,
- 'Host Resources',
- $pconfig['hostres']
-));
+if (!(($specplatform['name'] == 'VMware') && (file_exists('/dev/cd0')))) {
+ $group->add(new Form_MultiCheckbox(
+ 'hostres',
+ null,
+ 'Host Resources',
+ $pconfig['hostres']
+ ));
+}
$group->add(new Form_MultiCheckbox(
'ucd',
@@ -338,6 +342,14 @@ $group->add(new Form_MultiCheckbox(
));
$section->add($group);
+if ((($specplatform['name'] == 'VMware') && (file_exists('/dev/cd0')))) {
+ $section->addInput(new Form_StaticText(
+ NULL,
+ NULL
+ ))->setHelp(sprint_info_box('The hostres module is not compatible with VMware virtual ' .
+ 'machines configured with a virtual CD/DVD Drive.', 'warning', false));
+}
+
$form->add($section);
$section = new Form_Section('Interface Binding');
diff --git a/src/usr/local/www/system_advanced_network.php b/src/usr/local/www/system_advanced_network.php
index acfe18d..1200996 100644
--- a/src/usr/local/www/system_advanced_network.php
+++ b/src/usr/local/www/system_advanced_network.php
@@ -174,23 +174,27 @@ $section->addInput(new Form_Checkbox(
))->setHelp('NOTE: This does not disable any IPv6 features on the firewall, it only '.
'blocks traffic.');
-$group = new Form_Group('IPv6 over IPv4 Tunneling');
+
+$group = new Form_Group('IPv6 over IPv4');
+
$group->add(new Form_Checkbox(
'ipv6nat_enable',
'IPv6 over IPv4 Tunneling',
- 'Enable IPv4 NAT encapsulation of IPv6 packets',
+ 'Enable IPv6 over IPv4 tunneling',
$pconfig['ipv6nat_enable']
));
$group->add(new Form_Input(
'ipv6nat_ipaddr',
- 'IP address',
+ 'IPv4 address of Tunnel Peer',
'text',
$pconfig['ipv6nat_ipaddr']
-))->setHelp('Enable IPv4 NAT encapsulation of IPv6 packets. <br/>This provides an '.
- 'RFC 2893 compatibility mechanism that can be used to tunneling IPv6 packets over '.
- 'IPv4 routing infrastructures. If enabled, don\'t forget to add a firewall rule to '.
- 'permit IPv6 packets.');
+));
+
+$group->setHelp('These options create an RFC 2893 compatible mechanism for IPv4 NAT encapsulation of IPv6 packets, ' .
+ 'that can be used to tunnel IPv6 packets over IPv4 routing infrastructures. ' .
+ 'IPv6 firewall rules are <a href="firewall_rules.php">also required</a>, to control and pass encapsulated traffic.');
+
$section->add($group);
diff --git a/src/usr/local/www/vpn_ipsec_settings.php b/src/usr/local/www/vpn_ipsec_settings.php
index 4360837..8d140c3 100644
--- a/src/usr/local/www/vpn_ipsec_settings.php
+++ b/src/usr/local/www/vpn_ipsec_settings.php
@@ -33,16 +33,7 @@ require_once("shaper.inc");
require_once("ipsec.inc");
require_once("vpn.inc");
-$def_loglevel = '1';
-
-foreach (array_keys($ipsec_log_cats) as $cat) {
- if (isset($config['ipsec']['logging'][$cat])) {
- $pconfig[$cat] = $config['ipsec']['logging'][$cat];
- } else {
- $pconfig[$cat] = $def_loglevel;
- }
-}
-
+$pconfig['logging'] = ipsec_get_loglevels();
$pconfig['unityplugin'] = isset($config['ipsec']['unityplugin']);
$pconfig['strictcrlpolicy'] = isset($config['ipsec']['strictcrlpolicy']);
$pconfig['makebeforebreak'] = isset($config['ipsec']['makebeforebreak']);
@@ -59,8 +50,10 @@ if ($_POST) {
$pconfig = $_POST;
foreach ($ipsec_log_cats as $cat => $desc) {
- if (!in_array(intval($pconfig[$cat]), array_keys($ipsec_log_sevs), true)) {
+ if (!in_array(intval($pconfig['logging_' . $cat]), array_keys($ipsec_log_sevs), true)) {
$input_errors[] = sprintf(gettext("A valid value must be specified for %s debug."), $desc);
+ } else {
+ $pconfig['logging'][$cat] = $pconfig['logging_' . $cat];
}
}
@@ -79,12 +72,12 @@ if ($_POST) {
* get set when we save, even if it's to the default level.
*/
foreach (array_keys($ipsec_log_cats) as $cat) {
- if (!isset($pconfig[$cat])) {
+ if (!isset($pconfig['logging'][$cat])) {
continue;
}
- if ($pconfig[$cat] != $config['ipsec']['logging'][$cat]) {
- $config['ipsec']['logging'][$cat] = $pconfig[$cat];
- vpn_update_daemon_loglevel($cat, $pconfig[$cat]);
+ if ($pconfig['logging'][$cat] != $config['ipsec']['logging'][$cat]) {
+ $config['ipsec']['logging'][$cat] = $pconfig['logging'][$cat];
+ vpn_update_daemon_loglevel($cat, $pconfig['logging'][$cat]);
}
}
@@ -241,9 +234,9 @@ $section = new Form_Section('IPsec Logging Controls');
foreach ($ipsec_log_cats as $cat => $desc) {
$section->addInput(new Form_Select(
- $cat,
+ 'logging_' . $cat,
$desc,
- $pconfig[$cat],
+ $pconfig['logging'][$cat],
$ipsec_log_sevs
))->setWidth(2);
}
OpenPOWER on IntegriCloud