summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2005-11-03 23:21:43 +0000
committerScott Ullrich <sullrich@pfsense.org>2005-11-03 23:21:43 +0000
commit31a3b9db6bbb3fd6ea0a86aa584d795d3d306107 (patch)
treebdeb07f518e0a910882bf8c04d4fec41900f5b9a /etc
parent95eb8424a371f4bad8be0495f23a85419aa08b51 (diff)
downloadpfsense-31a3b9db6bbb3fd6ea0a86aa584d795d3d306107.zip
pfsense-31a3b9db6bbb3fd6ea0a86aa584d795d3d306107.tar.gz
MFC 7317
Correct start pftpx helper when no external-address is specified
Diffstat (limited to 'etc')
-rw-r--r--etc/inc/filter.inc5
1 files changed, 4 insertions, 1 deletions
diff --git a/etc/inc/filter.inc b/etc/inc/filter.inc
index e201e17..29416c6 100644
--- a/etc/inc/filter.inc
+++ b/etc/inc/filter.inc
@@ -621,8 +621,11 @@ function filter_nat_rules_generate() {
if($extport[0] == "21" and !isset($config['system']['disableftpproxy'])) {
$helpers = exec("ps aux | grep pftpx | grep -v grep | grep {$target}");
if(!$helpers) {
+ $external_address = $rule['external-address'];
+ if($external_address == "")
+ $external_address = find_interface_ip(get_real_wan_interface());
/* install a pftpx helper, do not set a rule */
- mwexec_bg("/usr/local/sbin/pftpx -b {$rule['external-address']} -c 21 -f {$target} -g 21");
+ mwexec_bg("/usr/local/sbin/pftpx -b {$external_address} -c 21 -f {$target} -g 21");
continue;
}
}
OpenPOWER on IntegriCloud