summaryrefslogtreecommitdiffstats
path: root/usr
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2012-11-20 08:23:54 -0500
committerjim-p <jimp@pfsense.org>2012-11-20 08:31:34 -0500
commita6f64d307678097ae6257ca9183b2dcd6aea673c (patch)
tree022d195eeea8ac18ea9da350e9413ad858f84095 /usr
parente6a2acc15de2622af37d27b1aabd254e1cd381f9 (diff)
downloadpfsense-a6f64d307678097ae6257ca9183b2dcd6aea673c.zip
pfsense-a6f64d307678097ae6257ca9183b2dcd6aea673c.tar.gz
Only apply this port check for TCP and UDP.
Diffstat (limited to 'usr')
-rwxr-xr-xusr/local/www/firewall_nat_edit.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr/local/www/firewall_nat_edit.php b/usr/local/www/firewall_nat_edit.php
index aa5f710..8243d48 100755
--- a/usr/local/www/firewall_nat_edit.php
+++ b/usr/local/www/firewall_nat_edit.php
@@ -222,7 +222,7 @@ if ($_POST) {
if ($_POST['dstendport'] && !is_portoralias($_POST['dstendport']))
$input_errors[] = sprintf(gettext("%s is not a valid end destination port. It must be a port alias or integer between 1 and 65535."), $_POST['dstendport']);
- if (!isset($_POST['nordr']) && !is_portoralias($_POST['localbeginport'])) {
+ if ((strtoupper($_POST['proto']) == "TCP" || strtoupper($_POST['proto']) == "UDP" || strtoupper($_POST['proto']) == "TCP/UDP") && (!isset($_POST['nordr']) && !is_portoralias($_POST['localbeginport']))) {
$input_errors[] = sprintf(gettext("A valid local port must be specified. It must be a port alias or integer between 1 and 65535."), $_POST['localbeginport']);
}
OpenPOWER on IntegriCloud