summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--etc/inc/globals.inc2
-rw-r--r--etc/inc/interfaces.inc2
-rw-r--r--etc/inc/services.inc2
-rw-r--r--etc/inc/upgrade_config.inc39
-rwxr-xr-xusr/local/bin/checkreload.sh16
-rwxr-xr-xusr/local/captiveportal/index.php1
-rwxr-xr-xusr/local/www/services_snmp.php6
-rwxr-xr-xusr/local/www/system_usermanager_settings.php9
-rw-r--r--usr/local/www/vpn_ipsec_phase2.php16
-rw-r--r--usr/local/www/wizards/traffic_shaper_wizard.xml2
-rwxr-xr-xusr/local/www/wizards/traffic_shaper_wizard_dedicated.inc10
-rwxr-xr-xusr/local/www/wizards/traffic_shaper_wizard_dedicated.xml2
-rwxr-xr-xusr/local/www/wizards/traffic_shaper_wizard_multi_all.inc2
-rwxr-xr-xusr/local/www/wizards/traffic_shaper_wizard_multi_all.xml2
-rw-r--r--usr/local/www/wizards/traffic_shaper_wizard_multi_lan.xml2
15 files changed, 44 insertions, 69 deletions
diff --git a/etc/inc/globals.inc b/etc/inc/globals.inc
index 1b786bd..96b0d77 100644
--- a/etc/inc/globals.inc
+++ b/etc/inc/globals.inc
@@ -89,7 +89,7 @@ $g = array(
"disablehelpmenu" => false,
"disablehelpicon" => false,
"debug" => false,
- "latest_config" => "7.0",
+ "latest_config" => "7.1",
"nopkg_platforms" => array("cdrom"),
"minimum_ram_warning" => "105",
"minimum_ram_warning_text" => "128 MB",
diff --git a/etc/inc/interfaces.inc b/etc/inc/interfaces.inc
index 8e749e5..bb65766 100644
--- a/etc/inc/interfaces.inc
+++ b/etc/inc/interfaces.inc
@@ -844,7 +844,7 @@ function interface_bring_down($interface = "wan", $destroy = false) {
if ($realif == $ppp['if']) {
if (file_exists("{$g['varrun_path']}/{$ifcfg['ipaddr']}_{$interface}.pid")) {
killbypid("{$g['varrun_path']}/{$ifcfg['ipaddr']}_{$interface}.pid");
- sleep(2);
+ sleep(5);
}
unlink_if_exists("{$g['varetc_path']}/mpd_{$interface}.conf");
if (isset($ppp['ondemand']) && !$destroy)
diff --git a/etc/inc/services.inc b/etc/inc/services.inc
index 82166d6..6322436 100644
--- a/etc/inc/services.inc
+++ b/etc/inc/services.inc
@@ -590,7 +590,7 @@ function services_dhcrelay_configure() {
function services_dyndns_configure_client($conf) {
if (!isset($conf['enable']))
- continue;
+ return;
/* load up the dyndns.class */
require_once("dyndns.class");
diff --git a/etc/inc/upgrade_config.inc b/etc/inc/upgrade_config.inc
index 13e9094..a7f75a3 100644
--- a/etc/inc/upgrade_config.inc
+++ b/etc/inc/upgrade_config.inc
@@ -486,17 +486,6 @@ function upgrade_025_to_026() {
$cron_item['command'] = "/usr/bin/nice -n20 /usr/local/sbin/expiretable -t 1800 snort2c";
$config['cron']['item'][] = $cron_item;
-
- $cron_item = array();
- $cron_item['minute'] = "*/5";
- $cron_item['hour'] = "*";
- $cron_item['mday'] = "*";
- $cron_item['month'] = "*";
- $cron_item['wday'] = "*";
- $cron_item['who'] = "root";
- $cron_item['command'] = "/usr/local/bin/checkreload.sh";
-
- $config['cron']['item'][] = $cron_item;
}
@@ -507,22 +496,6 @@ function upgrade_026_to_027() {
function upgrade_027_to_028() {
global $config;
- $founditem = false;
- foreach($config['cron']['item'] as $cronitem) {
- if($cronitem['command'] == "/usr/local/bin/checkreload.sh")
- $founditem = true;
- }
- if($founditem == false) {
- $cron_item = array();
- $cron_item['minute'] = "*/5";
- $cron_item['hour'] = "*";
- $cron_item['mday'] = "*";
- $cron_item['month'] = "*";
- $cron_item['wday'] = "*";
- $cron_item['who'] = "root";
- $cron_item['command'] = "/usr/local/bin/checkreload.sh";
- $config['cron']['item'][] = $cron_item;
- }
}
@@ -2227,4 +2200,16 @@ function upgrade_069_to_070() {
}
}
+function upgrade_070_to_071() {
+ global $config;
+
+ if (is_array($config['cron']['item'])) {
+ foreach($config['cron']['item'] as $idx => $cronitem) {
+ if(stristr($cronitem['command'], "checkreload.sh")) {
+ unset($config['cron']['item'][$idx]);
+ break;
+ }
+ }
+ }
+}
?>
diff --git a/usr/local/bin/checkreload.sh b/usr/local/bin/checkreload.sh
deleted file mode 100755
index b1c1723..0000000
--- a/usr/local/bin/checkreload.sh
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/bin/sh
-
-CHECKRELOADSTATUS=`pgrep check_reload_status | wc -l`
-DATE=`date +%m-%d-%Y_at_%H%M%S`
-OUTFILE=/root/check_reload_status.log
-
-if [ ${CHECKRELOADSTATUS} -lt 1 ] ; then
- echo "${DATE}: Re-starting check_reload_status, it died for some reason..." >> ${OUTFILE}
- nohup /usr/bin/nice -n20 /usr/local/sbin/check_reload_status &
-fi
-
-if [ ${CHECKRELOADSTATUS} -gt 1 ] ; then
- echo "${DATE} There appears to be 2 or more check_reload_status processes. Forcing kill and restart of all now..." >> ${OUTFILE}
- kill -9 `pgrep check_reload_status`
- nohup /usr/bin/nice -n20 /usr/local/sbin/check_reload_status &
-fi
diff --git a/usr/local/captiveportal/index.php b/usr/local/captiveportal/index.php
index 1839f0a..6cbe1c0 100755
--- a/usr/local/captiveportal/index.php
+++ b/usr/local/captiveportal/index.php
@@ -43,6 +43,7 @@ header("Expires: 0");
header("Cache-Control: no-store, no-cache, must-revalidate");
header("Cache-Control: post-check=0, pre-check=0", false);
header("Pragma: no-cache");
+header("Connection: close");
$orig_host = $_ENV['HTTP_HOST'];
$orig_request = $_REQUEST['redirurl'];
diff --git a/usr/local/www/services_snmp.php b/usr/local/www/services_snmp.php
index d3cda15..8b79c66 100755
--- a/usr/local/www/services_snmp.php
+++ b/usr/local/www/services_snmp.php
@@ -84,6 +84,10 @@ if ($_POST) {
/* input validation */
if ($_POST['enable']) {
+ if (strstr($_POST['syslocation'],"#")) $input_errors[] = gettext("Invalid character '#' in system location");
+ if (strstr($_POST['syscontact'],"#")) $input_errors[] = gettext("Invalid character '#' in system contact");
+ if (strstr($_POST['rocommunity'],"#")) $input_errors[] = gettext("Invalid character '#' in read community string");
+
$reqdfields = explode(" ", "rocommunity");
$reqdfieldsn = array(gettext("Community"));
do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
@@ -96,6 +100,8 @@ if ($_POST) {
}
if ($_POST['trapenable']) {
+ if (strstr($_POST['trapstring'],"#")) $input_errors[] = gettext("Invalid character '#' in SNMP trap string");
+
$reqdfields = explode(" ", "trapserver");
$reqdfieldsn = array(gettext("Trap server"));
do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
diff --git a/usr/local/www/system_usermanager_settings.php b/usr/local/www/system_usermanager_settings.php
index cba9d57..d7e3e1a 100755
--- a/usr/local/www/system_usermanager_settings.php
+++ b/usr/local/www/system_usermanager_settings.php
@@ -41,9 +41,6 @@
##|*MATCH=system_usermanager_settings.php*
##|-PRIV
-if($_POST['savetest'])
- $save_and_test = true;
-
require("guiconfig.inc");
$pconfig['session_timeout'] = &$config['system']['webgui']['session_timeout'];
@@ -53,6 +50,7 @@ $pconfig['backend'] = &$config['system']['webgui']['backend'];
// Page title for main admin
$pgtitle = array(gettext("System"),gettext("User manager settings"));
+$save_and_test = false;
if ($_POST) {
unset($input_errors);
$pconfig = $_POST;
@@ -64,6 +62,11 @@ if ($_POST) {
}
if (!$input_errors) {
+ if ($_POST['savetest'] && $_POST['authmode'] == "ldap")
+ $save_and_test = true;
+ else
+ $savemsg = gettext("The test was not performed becuase it is supported only for ldap based backends.");
+
if(isset($_POST['session_timeout']) && $_POST['session_timeout'] != "")
$config['system']['webgui']['session_timeout'] = intval($_POST['session_timeout']);
diff --git a/usr/local/www/vpn_ipsec_phase2.php b/usr/local/www/vpn_ipsec_phase2.php
index ba69dcf..824ba19 100644
--- a/usr/local/www/vpn_ipsec_phase2.php
+++ b/usr/local/www/vpn_ipsec_phase2.php
@@ -217,10 +217,14 @@ function change_mode() {
value = document.iform.mode.options[index].value;
if (value == 'tunnel') {
document.getElementById('opt_localid').style.display = '';
+<?php if (!isset($pconfig['mobile'])): ?>
document.getElementById('opt_remoteid').style.display = '';
+<?php endif; ?>
} else {
document.getElementById('opt_localid').style.display = 'none';
+<?php if (!isset($pconfig['mobile'])): ?>
document.getElementById('opt_remoteid').style.display = 'none';
+<?php endif; ?>
}
}
@@ -253,15 +257,7 @@ function typesel_change_local(bits) {
}
}
-<?php if (isset($pconfig['mobile'])): ?>
-
-function typesel_change_remote(bits) {
-
- document.iform.remoteid_address.disabled = 1;
- document.iform.remoteid_netbits.disabled = 1;
-}
-
-<?php else: ?>
+<?php if (!isset($pconfig['mobile'])): ?>
function typesel_change_remote(bits) {
@@ -591,7 +587,9 @@ function change_protocol() {
change_mode('<?=$pconfig['mode']?>');
change_protocol('<?=$pconfig['proto']?>');
typesel_change_local(<?=$pconfig['localid_netbits']?>);
+<?php if (!isset($pconfig['mobile'])): ?>
typesel_change_remote(<?=$pconfig['remoteid_netbits']?>);
+<?php endif; ?>
//-->
</script>
<?php include("fend.inc"); ?>
diff --git a/usr/local/www/wizards/traffic_shaper_wizard.xml b/usr/local/www/wizards/traffic_shaper_wizard.xml
index 1279785..ce2b04c 100644
--- a/usr/local/www/wizards/traffic_shaper_wizard.xml
+++ b/usr/local/www/wizards/traffic_shaper_wizard.xml
@@ -227,7 +227,7 @@
<type>checkbox</type>
<typehint>Lower priority of Peer-to-Peer traffic</typehint>
<description>This will lower the priority of P2P traffic below all other traffic. Please check the items that you would like to prioritize lower than normal traffic.</description>
- <enablefields>p2pCatchAll,Bandwidth,Aimster,BitTorrent,BuddyShare,CuteMX,DCplusplus,dcc,DirectConnect,DirectFileExpress,EDonkey2000,FastTrack,Gnutella,grouper,hotComm,HotlineConnect,iMesh,Napster,OpenNap,Scour,Shareaza,SongSpy,WinMX</enablefields>
+ <enablefields>p2pCatchAll,Bandwidth,BandwidthSpeed,Aimster,BitTorrent,BuddyShare,CuteMX,DCplusplus,dcc,DirectConnect,DirectFileExpress,EDonkey2000,FastTrack,Gnutella,grouper,hotComm,HotlineConnect,iMesh,Napster,OpenNap,Scour,Shareaza,SongSpy,WinMX</enablefields>
<bindstofield>ezshaper-&gt;step5-&gt;enable</bindstofield>
</field>
<field>
diff --git a/usr/local/www/wizards/traffic_shaper_wizard_dedicated.inc b/usr/local/www/wizards/traffic_shaper_wizard_dedicated.inc
index b640c05..9909db7 100755
--- a/usr/local/www/wizards/traffic_shaper_wizard_dedicated.inc
+++ b/usr/local/www/wizards/traffic_shaper_wizard_dedicated.inc
@@ -736,12 +736,11 @@ function apply_all_choosen_items() {
$tmpcf['bandwidthtype'] = $config['ezshaper']['step2']["conn{$i}uploadspeed"];
}
else if ($sched == "HFSC") {
- $tmpcf['linkshare3'] = floatval($config['ezshaper']['step2']["conn{$i}upload"]) . $config['ezshaper']['step2']["conn{$i}uploadspeed"];
$tmpcf['upperlimit'] = "on";
$tmpcf['upperlimit3'] =
floatval($config['ezshaper']['step2']["conn{$i}upload"]) . $config['ezshaper']['step2']["conn{$i}uploadspeed"];
- $tmpcf['linkshare2'] = 100;
$tmpcf['linkshare'] = "on";
+ $tmpcf['linkshare3'] = floatval($config['ezshaper']['step2']["conn{$i}upload"]) . $config['ezshaper']['step2']["conn{$i}uploadspeed"];
$tmpcf['bandwidth'] = floatval($config['ezshaper']['step2']["conn{$i}upload"]);
$tmpcf['bandwidthtype'] = $config['ezshaper']['step2']["conn{$i}uploadspeed"];
}
@@ -1010,7 +1009,7 @@ function apply_all_choosen_items() {
array_pop($tmppath);
$downfactor = wizard_get_bandwidthtype_scale($config['ezshaper']['step2']["conn{$i}downloadspeed"]);
- $downbw = floatval($config['ezshaper']['step2']["conn{$i}download"]) * $upfactor;
+ $downbw = floatval($config['ezshaper']['step2']["conn{$i}download"]) * $downfactor;
$tmppath = array();
$altq =& new altq_root_queue();
@@ -1045,7 +1044,7 @@ function apply_all_choosen_items() {
$voip = true;
$voipbw = $config['ezshaper']['step3']["local{$i}download"];
$voipbwunit = $config['ezshaper']['step3']["local{$i}downloadspeed"];
- if ($scehd != HFSC) {
+ if ($sched != HFSC) {
if ($penaltybwunit == "%")
$factor = $downbw/100;
else
@@ -1122,11 +1121,10 @@ function apply_all_choosen_items() {
$tmpcf['bandwidthtype'] = $config['ezshaper']['step2']["conn{$i}downloadspeed"];
}
else if ($sched == "HFSC") {
- $tmpcf['linkshare3'] = floatval($config['ezshaper']['step2']["conn{$i}download"]) . $config['ezshaper']['step2']["conn{$i}downloadspeed"];
$tmpcf['upperlimit'] = "on";
$tmpcf['upperlimit3'] = floatval($config['ezshaper']['step2']["conn{$i}download"]) . $config['ezshaper']['step2']["conn{$i}downloadspeed"];
- $tmpcf['linkshare2'] = 100;
$tmpcf['linkshare'] = "on";
+ $tmpcf['linkshare3'] = floatval($config['ezshaper']['step2']["conn{$i}download"]) . $config['ezshaper']['step2']["conn{$i}downloadspeed"];
$tmpcf['bandwidth'] = floatval($config['ezshaper']['step2']["conn{$i}download"]);
$tmpcf['bandwidthtype'] = $config['ezshaper']['step2']["conn{$i}downloadspeed"];
}
diff --git a/usr/local/www/wizards/traffic_shaper_wizard_dedicated.xml b/usr/local/www/wizards/traffic_shaper_wizard_dedicated.xml
index 8688db1..5d83553 100755
--- a/usr/local/www/wizards/traffic_shaper_wizard_dedicated.xml
+++ b/usr/local/www/wizards/traffic_shaper_wizard_dedicated.xml
@@ -232,7 +232,7 @@
<type>checkbox</type>
<typehint>Lower priority of Peer-to-Peer traffic</typehint>
<description>This will lower the priority of P2P traffic below all other traffic. Please check the items that you would like to prioritize lower than normal traffic.</description>
- <enablefields>p2pCatchAll,Bandwidth,Aimster,BitTorrent,BuddyShare,CuteMX,DCplusplus,dcc,DirectConnect,DirectFileExpress,EDonkey2000,FastTrack,Gnutella,grouper,hotComm,HotlineConnect,iMesh,Napster,OpenNap,Scour,Shareaza,SongSpy,WinMX</enablefields>
+ <enablefields>p2pCatchAll,Bandwidth,BandwidthSpeed,Aimster,BitTorrent,BuddyShare,CuteMX,DCplusplus,dcc,DirectConnect,DirectFileExpress,EDonkey2000,FastTrack,Gnutella,grouper,hotComm,HotlineConnect,iMesh,Napster,OpenNap,Scour,Shareaza,SongSpy,WinMX</enablefields>
<bindstofield>ezshaper-&gt;step5-&gt;enable</bindstofield>
</field>
<field>
diff --git a/usr/local/www/wizards/traffic_shaper_wizard_multi_all.inc b/usr/local/www/wizards/traffic_shaper_wizard_multi_all.inc
index 7e88216..b44a0b8 100755
--- a/usr/local/www/wizards/traffic_shaper_wizard_multi_all.inc
+++ b/usr/local/www/wizards/traffic_shaper_wizard_multi_all.inc
@@ -1088,7 +1088,7 @@ function apply_all_choosen_items() {
$voip = true;
$voipbw = $config['ezshaper']['step3']["local{$i}download"];
$voipbwunit = $config['ezshaper']['step3']["local{$i}downloadspeed"];
- if ($scehd != HFSC) {
+ if ($sched != HFSC) {
if ($penaltybwunit == "%")
$factor = $lanbw/100;
else
diff --git a/usr/local/www/wizards/traffic_shaper_wizard_multi_all.xml b/usr/local/www/wizards/traffic_shaper_wizard_multi_all.xml
index a138054..9fca078 100755
--- a/usr/local/www/wizards/traffic_shaper_wizard_multi_all.xml
+++ b/usr/local/www/wizards/traffic_shaper_wizard_multi_all.xml
@@ -240,7 +240,7 @@
<type>checkbox</type>
<typehint>Lower priority of Peer-to-Peer traffic</typehint>
<description>This will lower the priority of P2P traffic below all other traffic. Please check the items that you would like to prioritize lower than normal traffic.</description>
- <enablefields>p2pCatchAll,Bandwidth,Aimster,BitTorrent,BuddyShare,CuteMX,DCplusplus,dcc,DirectConnect,DirectFileExpress,EDonkey2000,FastTrack,Gnutella,grouper,hotComm,HotlineConnect,iMesh,Napster,OpenNap,Scour,Shareaza,SongSpy,WinMX</enablefields>
+ <enablefields>p2pCatchAll,Bandwidth,BandwidthSpeed,Aimster,BitTorrent,BuddyShare,CuteMX,DCplusplus,dcc,DirectConnect,DirectFileExpress,EDonkey2000,FastTrack,Gnutella,grouper,hotComm,HotlineConnect,iMesh,Napster,OpenNap,Scour,Shareaza,SongSpy,WinMX</enablefields>
<bindstofield>ezshaper-&gt;step5-&gt;enable</bindstofield>
</field>
<field>
diff --git a/usr/local/www/wizards/traffic_shaper_wizard_multi_lan.xml b/usr/local/www/wizards/traffic_shaper_wizard_multi_lan.xml
index f99f9e7..9ed7c44 100644
--- a/usr/local/www/wizards/traffic_shaper_wizard_multi_lan.xml
+++ b/usr/local/www/wizards/traffic_shaper_wizard_multi_lan.xml
@@ -289,7 +289,7 @@
<type>checkbox</type>
<typehint>Lower priority of Peer-to-Peer traffic</typehint>
<description>This will lower the priority of P2P traffic below all other traffic. Please check the items that you would like to prioritize lower than normal traffic.</description>
- <enablefields>p2pCatchAll,Bandwidth,Aimster,BitTorrent,BuddyShare,CuteMX,DCplusplus,dcc,DirectConnect,DirectFileExpress,EDonkey2000,FastTrack,Gnutella,grouper,hotComm,HotlineConnect,iMesh,Napster,OpenNap,Scour,Shareaza,SongSpy,WinMX</enablefields>
+ <enablefields>p2pCatchAll,Bandwidth,BandwidthSpeed,Aimster,BitTorrent,BuddyShare,CuteMX,DCplusplus,dcc,DirectConnect,DirectFileExpress,EDonkey2000,FastTrack,Gnutella,grouper,hotComm,HotlineConnect,iMesh,Napster,OpenNap,Scour,Shareaza,SongSpy,WinMX</enablefields>
<bindstofield>ezshaper-&gt;step5-&gt;enable</bindstofield>
</field>
<field>
OpenPOWER on IntegriCloud