diff options
author | Renato Botelho <garga@FreeBSD.org> | 2013-02-13 21:50:37 -0200 |
---|---|---|
committer | Renato Botelho <garga@FreeBSD.org> | 2013-02-13 21:50:37 -0200 |
commit | 965c3e23a60f25d263389bf02b685bb7f20f3915 (patch) | |
tree | f820cd8e8067f00440ec597280ca5282ecb20838 /usr | |
parent | f1a831b8a821382646fb506514005f6bb754f22a (diff) | |
download | pfsense-965c3e23a60f25d263389bf02b685bb7f20f3915.zip pfsense-965c3e23a60f25d263389bf02b685bb7f20f3915.tar.gz |
Deal correct with bitmask for ipv6 on destination, same we did for src. If fixes #2451
Diffstat (limited to 'usr')
-rwxr-xr-x | usr/local/www/firewall_rules_edit.php | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/usr/local/www/firewall_rules_edit.php b/usr/local/www/firewall_rules_edit.php index 9d1e1f6..5cf6348 100755 --- a/usr/local/www/firewall_rules_edit.php +++ b/usr/local/www/firewall_rules_edit.php @@ -999,7 +999,13 @@ include("head.inc"); <?php $sel = is_specialnet($pconfig['dst']); ?> <option value="any" <?php if ($pconfig['dst'] == "any") { echo "selected"; } ?>><?=gettext("any");?></option> - <option value="single" <?php if (($pconfig['dstmask'] == 32) && !$sel) { echo "selected"; $sel = 1; } ?>><?=gettext("Single host or alias");?></option> + <option value="single" + <?php if (!$sel && + ((is_ipaddrv6($pconfig['dst']) && $pconfig['dstmask'] == 128) || + (is_ipaddrv4($pconfig['dst']) && $pconfig['dstmask'] == 32) || is_alias($pconfig['dst']))) + { echo "selected"; $sel = 1; } + ?> + ><?=gettext("Single host or alias");?></option> <option value="network" <?php if (!$sel) echo "selected"; ?>><?=gettext("Network");?></option> <?php if(have_ruleint_access("pptp")): ?> <option value="pptp" <?php if ($pconfig['dst'] == "pptp") { echo "selected"; } ?>><?=gettext("PPTP clients");?></option> |