From faa8753e83239e757c2290fb07b7d49d7310f317 Mon Sep 17 00:00:00 2001 From: Seth Mos Date: Sun, 20 Aug 2006 18:11:18 +0000 Subject: Update the miniupnpd package and include a binary. Stop and restart now empties table after and before. Status page needs fixing still. --- packages/miniupnpd/miniupnpd.inc | 16 ++++++++++++---- packages/miniupnpd/miniupnpd.xml | 7 ++++++- packages/miniupnpd/sbin/miniupnpd | Bin 0 -> 47238 bytes 3 files changed, 18 insertions(+), 5 deletions(-) create mode 100755 packages/miniupnpd/sbin/miniupnpd diff --git a/packages/miniupnpd/miniupnpd.inc b/packages/miniupnpd/miniupnpd.inc index 06b1d8ea..e4d02402 100644 --- a/packages/miniupnpd/miniupnpd.inc +++ b/packages/miniupnpd/miniupnpd.inc @@ -20,14 +20,22 @@ $ifaces_final .= " -i {$wanif} -a {$addr}"; $first = 1; } else { - log_error("Could not resolve real interfaec {$iface}"); + log_error("Could not resolve real interface {$iface}"); } } - $start = "/usr/local/sbin/miniupnpd -p 2869{$ifaces_final}"; + $start = "# Clear existing rules and rdr entries \n"; + $start .= "/sbin/pfctl -aminiupnpd -Fr 2>&1 >/dev/null\n"; + $start .= "/sbin/pfctl -aminiupnpd -Fn 2>&1 >/dev/null\n"; + $start .= "/usr/local/sbin/miniupnpd -p 2869{$ifaces_final}"; + + $stop .= "/usr/bin/killall miniupnpd \n"; + $stop .= "# Clear existing rules and rdr entries \n"; + $stop .= "/sbin/pfctl -aminiupnpd -Fr 2>&1 >/dev/null\n"; + $stop .= "/sbin/pfctl -aminiupnpd -Fn 2>&1 >/dev/null\n"; write_rcfile(array( "file" => "miniupnpd.sh", "start" => $start, - "stop" => "/usr/bin/killall miniupnpd" + "stop" => $stop ) ); } @@ -36,4 +44,4 @@ config_unlock(); conf_mount_ro(); } -?> \ No newline at end of file +?> diff --git a/packages/miniupnpd/miniupnpd.xml b/packages/miniupnpd/miniupnpd.xml index 5509a5e8..6140e256 100644 --- a/packages/miniupnpd/miniupnpd.xml +++ b/packages/miniupnpd/miniupnpd.xml @@ -27,6 +27,11 @@ /usr/local/www/ 0777 + + /usr/local/sbin/ + 0755 + http://www.pfsense.com/packages/config/miniupnpd/sbin/miniupnpd + miniupnpd miniupnpd.sh @@ -66,4 +71,4 @@ exec("rm /usr/local/etc/rc.d/miniupnpd*"); - \ No newline at end of file + diff --git a/packages/miniupnpd/sbin/miniupnpd b/packages/miniupnpd/sbin/miniupnpd new file mode 100755 index 00000000..0b7b361b Binary files /dev/null and b/packages/miniupnpd/sbin/miniupnpd differ -- cgit v1.2.3