summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
authorErmal Luçi <eri@pfsense.org>2010-02-01 10:23:54 +0000
committerErmal Luçi <eri@pfsense.org>2010-02-01 10:23:54 +0000
commitd76ecf1368b049bd775e3cd4bf9feb00fa0fda40 (patch)
tree8a65a65cfc807580ab8044b19e38f393208547fd /etc
parentc26bda2e81af9dae07d73a7c31c596a3a1e8da69 (diff)
downloadpfsense-d76ecf1368b049bd775e3cd4bf9feb00fa0fda40.zip
pfsense-d76ecf1368b049bd775e3cd4bf9feb00fa0fda40.tar.gz
Expand aliases for reflection entries to be generated normaly. Reported-by: http://forum.pfsense.org/index.php/topic,22535.0.html
Diffstat (limited to 'etc')
-rw-r--r--etc/inc/filter.inc8
1 files changed, 6 insertions, 2 deletions
diff --git a/etc/inc/filter.inc b/etc/inc/filter.inc
index 8456fa4..152cbb3 100644
--- a/etc/inc/filter.inc
+++ b/etc/inc/filter.inc
@@ -752,8 +752,12 @@ function filter_generate_reflection($rule, $target, $extport, &$starting_localho
else
$range_end = ($extport[0]);
$range_end++;
- $extaddr = alias_expand($rule['external-address']);
- if(!$extaddr)
+ /* TODO: support multiple ip's in an alias. */
+ if (is_alias($rule['external-address']))
+ $extaddr = filter_expand_alias($rule['external-address']);
+ else if(is_ipaddr($rule['external-address']))
+ $extaddr = $rule['external-address'];
+ else if (is_ipaddr($FilterIflist[$rule['interface']]['ip']))
$extaddr = $FilterIflist[$rule['interface']]['ip'];
if($rule['local-port'])
$lrange_start = $rule['local-port'];
OpenPOWER on IntegriCloud