aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoss Williams <ross@ross-williams.net>2013-08-16 15:49:52 -0400
committerRoss Williams <ross@ross-williams.net>2013-08-16 15:49:52 -0400
commita2072a21d04e8513300a8e7b7cef329ac657f52d (patch)
treeb41675f3613c13fd13673a561906703644cda6ba
parent443b634d759b51afdcce1f1bfa3e14abdb9ba961 (diff)
downloadpfsense-packages-a2072a21d04e8513300a8e7b7cef329ac657f52d.tar.gz
pfsense-packages-a2072a21d04e8513300a8e7b7cef329ac657f52d.tar.bz2
pfsense-packages-a2072a21d04e8513300a8e7b7cef329ac657f52d.zip
Allowing siproxd to run even if RTP proxy is disabled
-rw-r--r--config/siproxd.inc16
1 files changed, 3 insertions, 13 deletions
diff --git a/config/siproxd.inc b/config/siproxd.inc
index 13254a42..c99514fc 100644
--- a/config/siproxd.inc
+++ b/config/siproxd.inc
@@ -69,12 +69,6 @@ function siproxd_generate_rules($type) {
return;
}
- /* proxy is turned off in package settings */
- if($siproxd_conf['rtpenable'] == "0") {
- log_error("WARNING: siproxd RTP proxy has not been enabled. Not installing rules.");
- return "\n";
- }
-
$ifaces = explode(",", $siproxd_conf['if_inbound']);
$ifaces = array_map('convert_friendly_interface_to_real_interface_name', $ifaces);
$rtplower = ($siproxd_conf['rtplower'] ? $siproxd_conf['rtplower'] : 7070);
@@ -95,7 +89,9 @@ function siproxd_generate_rules($type) {
if($iface <> "") {
$rules .= "# allow SIP signaling and RTP traffic\n";
$rules .= "pass in on {$iface} proto udp from any to any port = {$port}\n";
- $rules .= "pass in on {$iface} proto udp from any to any port {$rtplower}:{$rtpupper}\n";
+ if($siproxd_conf['rtpenable'] == "1") {
+ $rules .= "pass in on {$iface} proto udp from any to any port {$rtplower}:{$rtpupper}\n";
+ }
}
}
break;
@@ -124,12 +120,6 @@ function sync_package_siproxd() {
fwrite($fout, "# This file was automatically generated by the pfSense\n");
fwrite($fout, "# package management system.\n\n");
- /* proxy is turned off in package settings */
- if($siproxd_conf['rtpenable'] == "0") {
- fclose($fout);
- return;
- }
-
if($siproxd_conf['if_inbound'] != "") {
fwrite($fout, "if_inbound = " . convert_friendly_interface_to_real_interface_name($siproxd_conf['if_inbound']) . "\n");
}