diff options
-rwxr-xr-x | config/haproxy-legacy/haproxy_frontends_edit.php | 11 | ||||
-rwxr-xr-x | config/haproxy-legacy/haproxy_global.php | 6 | ||||
-rwxr-xr-x | config/haproxy-legacy/haproxy_servers_edit.php | 6 | ||||
-rwxr-xr-x | config/haproxy/haproxy_global.php | 6 | ||||
-rwxr-xr-x | config/haproxy/haproxy_listeners_edit.php | 11 | ||||
-rwxr-xr-x | config/haproxy/haproxy_pool_edit.php | 6 | ||||
-rw-r--r-- | config/tinc/status_tinc.php | 74 | ||||
-rw-r--r-- | pkg_config.10.xml | 12 | ||||
-rw-r--r-- | pkg_config.8.xml | 14 | ||||
-rw-r--r-- | pkg_config.8.xml.amd64 | 12 |
10 files changed, 95 insertions, 63 deletions
diff --git a/config/haproxy-legacy/haproxy_frontends_edit.php b/config/haproxy-legacy/haproxy_frontends_edit.php index db1c71be..b32cb762 100755 --- a/config/haproxy-legacy/haproxy_frontends_edit.php +++ b/config/haproxy-legacy/haproxy_frontends_edit.php @@ -96,12 +96,19 @@ if ($_POST) { $reqdfieldsn = explode(",", "Name,Connection timeout,Server timeout"); } - do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); + $pf_version=substr(trim(file_get_contents("/etc/version")),0,3); + if ($pf_version < 2.1) + $input_errors = eval('do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); return $input_errors;'); + else + do_input_validation($_POST, $reqdfields, $reqdfieldsn, $input_errors); $reqdfields = explode(" ", "name type port max_connections client_timeout"); $reqdfieldsn = explode(",", "Name,Type,Port,Max connections,Client timeout"); - do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); + if ($pf_version < 2.1) + $input_errors = eval('do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); return $input_errors;'); + else + do_input_validation($_POST, $reqdfields, $reqdfieldsn, $input_errors); if (preg_match("/[^a-zA-Z0-9\.\-_]/", $_POST['name'])) $input_errors[] = "The field 'Name' contains invalid characters."; diff --git a/config/haproxy-legacy/haproxy_global.php b/config/haproxy-legacy/haproxy_global.php index 509fdfe2..4ea03c75 100755 --- a/config/haproxy-legacy/haproxy_global.php +++ b/config/haproxy-legacy/haproxy_global.php @@ -57,7 +57,11 @@ if ($_POST) { $reqdfieldsn = explode(",", "Maximum connections"); } - do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); + $pf_version=substr(trim(file_get_contents("/etc/version")),0,3); + if ($pf_version < 2.1) + $input_errors = eval('do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); return $input_errors;'); + else + do_input_validation($_POST, $reqdfields, $reqdfieldsn, $input_errors); if ($_POST['maxconn'] && (!is_numeric($_POST['maxconn']))) $input_errors[] = "The maximum number of connections should be numeric."; diff --git a/config/haproxy-legacy/haproxy_servers_edit.php b/config/haproxy-legacy/haproxy_servers_edit.php index 86431992..843ecca5 100755 --- a/config/haproxy-legacy/haproxy_servers_edit.php +++ b/config/haproxy-legacy/haproxy_servers_edit.php @@ -70,7 +70,11 @@ if ($_POST) { $reqdfields = explode(" ", "name address weight"); $reqdfieldsn = explode(",", "Name,Address,Weight"); - do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); + $pf_version=substr(trim(file_get_contents("/etc/version")),0,3); + if ($pf_version < 2.1) + $input_errors = eval('do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); return $input_errors;'); + else + do_input_validation($_POST, $reqdfields, $reqdfieldsn, $input_errors); if (preg_match("/[^a-zA-Z0-9\.\-_]/", $_POST['name'])) $input_errors[] = "The field 'Name' contains invalid characters."; diff --git a/config/haproxy/haproxy_global.php b/config/haproxy/haproxy_global.php index 16f5152d..40b5cd90 100755 --- a/config/haproxy/haproxy_global.php +++ b/config/haproxy/haproxy_global.php @@ -59,7 +59,11 @@ if ($_POST) { if ($_POST['carpdev'] == "disabled") unset($_POST['carpdev']); - do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); + $pf_version=substr(trim(file_get_contents("/etc/version")),0,3); + if ($pf_version < 2.1) + $input_errors = eval('do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); return $input_errors;'); + else + do_input_validation($_POST, $reqdfields, $reqdfieldsn, $input_errors); if ($_POST['maxconn'] && (!is_numeric($_POST['maxconn']))) $input_errors[] = "The maximum number of connections should be numeric."; diff --git a/config/haproxy/haproxy_listeners_edit.php b/config/haproxy/haproxy_listeners_edit.php index 2b71c7ea..be45fd8b 100755 --- a/config/haproxy/haproxy_listeners_edit.php +++ b/config/haproxy/haproxy_listeners_edit.php @@ -113,12 +113,19 @@ if ($_POST) { $reqdfieldsn = explode(",", "Name,Connection timeout,Server timeout"); } - do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); + $pf_version=substr(trim(file_get_contents("/etc/version")),0,3); + if ($pf_version < 2.1) + $input_errors = eval('do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); return $input_errors;'); + else + do_input_validation($_POST, $reqdfields, $reqdfieldsn, $input_errors); $reqdfields = explode(" ", "name type port max_connections client_timeout"); $reqdfieldsn = explode(",", "Name,Type,Port,Max connections,Client timeout"); - do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); + if ($pf_version < 2.1) + $input_errors = eval('do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); return $input_errors;'); + else + do_input_validation($_POST, $reqdfields, $reqdfieldsn, $input_errors); if (preg_match("/[^a-zA-Z0-9\.\-_]/", $_POST['name'])) $input_errors[] = "The field 'Name' contains invalid characters."; diff --git a/config/haproxy/haproxy_pool_edit.php b/config/haproxy/haproxy_pool_edit.php index 4da508f2..6feab2ff 100755 --- a/config/haproxy/haproxy_pool_edit.php +++ b/config/haproxy/haproxy_pool_edit.php @@ -71,7 +71,11 @@ if ($_POST) { $reqdfields = explode(" ", "name"); $reqdfieldsn = explode(",", "Name"); - do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); + $pf_version=substr(trim(file_get_contents("/etc/version")),0,3); + if ($pf_version < 2.1) + $input_errors = eval('do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); return $input_errors;'); + else + do_input_validation($_POST, $reqdfields, $reqdfieldsn, $input_errors); if (preg_match("/[^a-zA-Z0-9\.\-_]/", $_POST['name'])) $input_errors[] = "The field 'Name' contains invalid characters."; diff --git a/config/tinc/status_tinc.php b/config/tinc/status_tinc.php index cd7b0aad..f50ea640 100644 --- a/config/tinc/status_tinc.php +++ b/config/tinc/status_tinc.php @@ -12,27 +12,28 @@ function tinc_status_1() { $clog_path = "/usr/local/sbin/clog"; } elseif (is_executable("/usr/sbin/clog")) { $clog_path = "/usr/sbin/clog"; + } if (!empty($clog_path)) exec("{$clog_path} /var/log/tinc.log | sed -e 's/.*tinc\[.*\]: //'",$result); - $i=0; - foreach($result as $line) - { - if(preg_match("/Connections:/",$line)) - $begin=$i; - if(preg_match("/End of connections./",$line)) - $end=$i; - $i++; - } - $output=""; - $i=0; - foreach($result as $line) - { - if($i >= $begin && $i<= $end) - $output .= $line . "\n"; - $i++; - } - return $output; + $i=0; + foreach($result as $line) + { + if(preg_match("/Connections:/",$line)) + $begin=$i; + if(preg_match("/End of connections./",$line)) + $end=$i; + $i++; + } + $output=""; + $i=0; + foreach($result as $line) + { + if($i >= $begin && $i<= $end) + $output .= $line . "\n"; + $i++; + } + return $output; } function tinc_status_2() { @@ -44,27 +45,28 @@ function tinc_status_2() { $clog_path = "/usr/local/sbin/clog"; } elseif (is_executable("/usr/sbin/clog")) { $clog_path = "/usr/sbin/clog"; + } if (!empty($clog_path)) exec("{$clog_path} /var/log/tinc.log | sed -e 's/.*tinc\[.*\]: //'",$result); - $i=0; - foreach($result as $line) - { - if(preg_match("/Statistics for Generic BSD tun device/",$line)) - $begin=$i; - if(preg_match("/End of subnet list./",$line)) - $end=$i; - $i++; - } - $output=""; - $i=0; - foreach($result as $line) - { - if($i >= $begin && $i<= $end) - $output .= $line . "\n"; - $i++; - } - return $output; + $i=0; + foreach($result as $line) + { + if(preg_match("/Statistics for Generic BSD tun device/",$line)) + $begin=$i; + if(preg_match("/End of subnet list./",$line)) + $end=$i; + $i++; + } + $output=""; + $i=0; + foreach($result as $line) + { + if($i >= $begin && $i<= $end) + $output .= $line . "\n"; + $i++; + } + return $output; } $shortcut_section = "tinc"; diff --git a/pkg_config.10.xml b/pkg_config.10.xml index 9c2e4592..6ae602b6 100644 --- a/pkg_config.10.xml +++ b/pkg_config.10.xml @@ -94,7 +94,7 @@ <package> <name>Strikeback</name> <descr>Detect port scans with iplog and strikeback</descr> - <website></website> + <website/> <pkginfolink>https://forum.pfsense.org/index.php/topic,37225.0.html</pkginfolink> <category>Services</category> <version>0.1</version> @@ -154,7 +154,7 @@ Supports acl's for smart backend switching.]]></descr> <website>http://haproxy.1wt.eu/</website> <category>Services</category> - <version>1.4.24_1 pkg v 1.2.4</version> + <version>1.4.24_1 pkg v 1.2.5</version> <status>Release</status> <required_version>2.2</required_version> <config_file>https://packages.pfsense.org/packages/config/haproxy/haproxy.xml</config_file> @@ -172,7 +172,7 @@ (Legacy version)]]></descr> <website>http://haproxy.1wt.eu/</website> <category>Services</category> - <version>1.4.24_1 pkg v 1.1</version> + <version>1.4.24_1 pkg v 1.1.1</version> <status>Release</status> <required_version>2.2</required_version> <config_file>https://packages.pfsense.org/packages/config/haproxy-legacy/haproxy.xml</config_file> @@ -466,9 +466,9 @@ <!-- NOTE: Distfile must be fetched manually from http://dansguardian.org/downloads/2/Alpha/dansguardian-2.12.0.0.tar.gz --> </package> <package> - <name>jailscanner</name> + <name>mailscanner</name> <internal_name>mailscanner</internal_name> - <website>www.mailscanner.info</website> + <website>http://www.mailscanner.info</website> <descr><![CDATA[MailScanner is an e-mail security and anti-spam package for e-mail gateway systems.<br /> This is a level3 mail scanning tool with high CPU load.]]></descr> <category>Services</category> @@ -1285,7 +1285,7 @@ <category>Services</category> <version>1.2.1</version> <status>BETA</status> - <website>www.winton.org.uk/zebedee/</website> + <website>http://www.winton.org.uk/zebedee/</website> <maintainer>jorgelustosa@gmail.com marcellocoutinho@gmail.com</maintainer> <required_version>2.2</required_version> <depends_on_package_pbi>zebedee-2.5.3-##ARCH##.pbi</depends_on_package_pbi> diff --git a/pkg_config.8.xml b/pkg_config.8.xml index ef2b9d31..05cd4f1f 100644 --- a/pkg_config.8.xml +++ b/pkg_config.8.xml @@ -97,7 +97,7 @@ <package> <name>Strikeback</name> <descr>Detect port scans with iplog and strikeback</descr> - <website></website> + <website/> <pkginfolink>https://forum.pfsense.org/index.php/topic,37225.0.html</pkginfolink> <category>Services</category> <version>0.1</version> @@ -157,7 +157,7 @@ Supports acl's for smart backend switching.]]></descr> <website>http://haproxy.1wt.eu/</website> <category>Services</category> - <version>1.4.24 pkg v 1.2.4</version> + <version>1.4.24 pkg v 1.2.5</version> <status>Release</status> <required_version>2.0</required_version> <config_file>https://packages.pfsense.org/packages/config/haproxy/haproxy.xml</config_file> @@ -175,7 +175,7 @@ (Legacy version)]]></descr> <website>http://haproxy.1wt.eu/</website> <category>Services</category> - <version>1.4.24 pkg v 1.1</version> + <version>1.4.24 pkg v 1.1.1</version> <status>Release</status> <required_version>2.0</required_version> <config_file>https://packages.pfsense.org/packages/config/haproxy-legacy/haproxy.xml</config_file> @@ -591,7 +591,7 @@ <depends_on_package_pbi>postfix-2.10.2-i386.pbi</depends_on_package_pbi> <version>2.10.2 pkg v.2.3.7</version> <status>Release</status> - <required_version>2.0</required_version> + <required_version>2.1</required_version> <configurationfile>postfix.xml</configurationfile> <build_port_path>/usr/ports/mail/postfix</build_port_path> <build_options>WITH_PCRE=true;WITH_SPF=true;WITH_SASL2=true;WITH_TLS=true</build_options> @@ -623,7 +623,7 @@ <package> <name>mailscanner</name> <internal_name>mailscanner</internal_name> - <website>www.mailscanner.info</website> + <website>http://www.mailscanner.info</website> <descr><![CDATA[MailScanner is an e-mail security and anti-spam package for e-mail gateway systems.<br /> This is a level3 mail scanning tool with high CPU load.]]></descr> <category>Services</category> @@ -1616,7 +1616,7 @@ <package> <name>widescreen</name> <descr>The package makes pfSense adapt to browser's current width. It is particularly convenient for Status->Dashboard page that allocates columns for widgets according to browser's current width. ATTENTION: the package heavily modifies pfsense_ng theme and affects other's themes appearance. Please REFRESH your browser's window after installing/uninstalling this package.</descr> - <website></website> + <website/> <pkginfolink></pkginfolink> <category>Enhancements</category> <version>0.2</version> @@ -1702,7 +1702,7 @@ <category>Services</category> <version>1.2.1</version> <status>BETA</status> - <website>www.winton.org.uk/zebedee/</website> + <website>http://www.winton.org.uk/zebedee/</website> <maintainer>jorgelustosa@gmail.com marcellocoutinho@gmail.com</maintainer> <required_version>2.0</required_version> <depends_on_package_base_url>https://files.pfsense.org/packages/8/All/</depends_on_package_base_url> diff --git a/pkg_config.8.xml.amd64 b/pkg_config.8.xml.amd64 index 399c424a..ed4bdea8 100644 --- a/pkg_config.8.xml.amd64 +++ b/pkg_config.8.xml.amd64 @@ -144,7 +144,7 @@ Supports acl's for smart backend switching.]]></descr> <website>http://haproxy.1wt.eu/</website> <category>Services</category> - <version>1.4.24 pkg v 1.2.4</version> + <version>1.4.24 pkg v 1.2.5</version> <status>Release</status> <required_version>2.0</required_version> <config_file>https://packages.pfsense.org/packages/config/haproxy/haproxy.xml</config_file> @@ -162,7 +162,7 @@ (Legacy version)]]></descr> <website>http://haproxy.1wt.eu/</website> <category>Services</category> - <version>1.4.24 pkg v 1.1</version> + <version>1.4.24 pkg v 1.1.1</version> <status>Release</status> <required_version>2.0</required_version> <config_file>https://packages.pfsense.org/packages/config/haproxy-legacy/haproxy.xml</config_file> @@ -578,7 +578,7 @@ <depends_on_package_pbi>postfix-2.10.2-amd64.pbi</depends_on_package_pbi> <version>2.10.2 pkg v.2.3.7</version> <status>Release</status> - <required_version>2.0</required_version> + <required_version>2.1</required_version> <configurationfile>postfix.xml</configurationfile> <build_port_path>/usr/ports/mail/postfix</build_port_path> <build_options>WITH_PCRE=true;WITH_SPF=true;WITH_SASL2=true;WITH_TLS=true</build_options> @@ -610,7 +610,7 @@ <package> <name>mailscanner</name> <internal_name>mailscanner</internal_name> - <website>www.mailscanner.info</website> + <website>http://www.mailscanner.info</website> <descr><![CDATA[MailScanner is an e-mail security and anti-spam package for e-mail gateway systems.<br /> This is a level3 mail scanning tool with high CPU load.]]></descr> <category>Services</category> @@ -1603,7 +1603,7 @@ <package> <name>widescreen</name> <descr>The package makes pfSense adapt to browser's current width. It is particularly convenient for Status->Dashboard page that allocates columns for widgets according to browser's current width. ATTENTION: the package heavily modifies pfsense_ng theme and affects other's themes appearance. Please REFRESH your browser's window after installing/uninstalling this package.</descr> - <website></website> + <website/> <pkginfolink></pkginfolink> <category>Enhancements</category> <version>0.2</version> @@ -1689,7 +1689,7 @@ <category>Services</category> <version>1.2.1</version> <status>BETA</status> - <website>www.winton.org.uk/zebedee/</website> + <website>http://www.winton.org.uk/zebedee/</website> <maintainer>jorgelustosa@gmail.com marcellocoutinho@gmail.com</maintainer> <required_version>2.0</required_version> <depends_on_package_base_url>https://files.pfsense.org/packages/8/All/</depends_on_package_base_url> |