<div>Hi, I am using Kamailio 3.2.0 (x86_64/linux) and since some days ago I am trying to call from a network with NAT to outside. This is the configuration:</div><div><br></div><div>Softphone (192.168.0.5) <--> Kamailio (192.168.0.3) <--> Router (192.168.0.1) <--> Softphone over smartphone</div>
<div><br></div><div>All the router ports are opened and redirected to 192.168.0.3. I have installed rtpproxy 1.2.1-1 with the following configuration:</div><div><br></div><div>--------------------------/etc/defaults/rtpproxy--------------------------------</div>
<div># The control socket.</div><div>#CONTROL_SOCK="unix:/var/run/rtpproxy/rtpproxy.sock"</div><div># To listen on an UDP socket, uncomment this line:</div><div>CONTROL_SOCK=udp:<a href="http://127.0.0.1:22222" target="_blank">127.0.0.1:22222</a></div>
<div><br></div><div># Additional options that are passed to the daemon.</div><div>EXTRA_OPTS="-l <a href="http://candamil.dyndns.org" target="_blank">candamil.dyndns.org</a>"</div><div>----------------------------------------------------------------------------------------</div>
<div><br></div><div>and works properly. This is the log message:</div><div><br></div><div>----------------------------------------------------------------------------------------------</div>
<div>Nov 12 20:09:13 condor kamailio[7001]: INFO: rtpproxy [rtpproxy.c:1415]:</div><div>rtp proxy <udp:<a href="http://127.0.0.1:22222" target="_blank">127.0.0.1:22222</a>> found, support for it enabled</div><div>-----------------------------------------------------------------------------------------------</div>
<div><br></div><div><br></div><div>Both softphones are "linphone". The configuration of the network softphone is the following:</div><div><br></div><div>SIP identity: <a href="mailto:sip%3A1001@192.168.0.3" target="_blank">sip:1001@192.168.0.3</a></div>
<div>SIP proxy: sip:192.168.0.3</div><div>Direct connection to the Internet.</div><div><br></div><div>In the softphone of the smartphone I set as proxy and domain "<a href="http://candamil.dyndns.org">candamil.dyndns.org</a>", the DNS address of my router IP.</div>
<div><br></div><div>In this case, these are the symptoms:</div><div>Both softphones can autentify correctly. When calling, both softphones ring, but when I answer, the voice signal is not received. This is the log error:</div>
<div><br></div><div>----------------------------------------------------------------------------------------------</div>
<div>Nov 12 20:23:14 condor kamailio[6991]: ERROR: rtpproxy [rtpproxy.c:2260]:</div><div>incorrect port 0 in reply from rtp proxy</div><div>----------------------------------------------------------------------------------------------</div>
<div><br></div><div><br></div><div>The same happens if I set in the network softphone that it's behind NAT, and I set the router IP.</div><div>The same happens if I set in the network softphone that it's behind NAT and with a STUN server (<a href="http://stunserver.org">stunserver.org</a>). In the three cases, in the softphone over smartphone, the caller is <a href="mailto:1001@192.168.0.3">1001@192.168.0.3</a>, and in the network softphone, the caller is <a href="mailto:1002@candamil.dyndns.org">1002@candamil.dyndns.org</a>.</div>
<div><br></div><div>If I set in the network softphone the proxy as sip:<a href="http://candamil.dyndns.org/" target="_blank">candamil.dyndns.org</a>, the same happens.</div><div>If what I do is setting the SIP identity as <a href="mailto:sip%3A1001@candamil.dyndns.org" target="_blank">sip:1001@candamil.dyndns.org</a>, when calling form inside to ouside the network, the softphone doesn't know that the call was answered, and there is the following error in the log:</div>
<div><br></div><div>----------------------------------------------------------------------------------------------------------</div>
<div>Nov 12 20:53:00 condor kamailio[7306]: ERROR: <core></div><div>[parser/parse_via.c:2600]: ERROR: parse_via: invalid port number</div><div><5060ranch=z9hG4bKc</div><div>50f.b4825246.0></div><div>Nov 12 20:53:00 condor kamailio[7306]: ERROR: <core></div>
<div>[parser/parse_via.c:2629]: ERROR: parse_via on: <SIP/2.0/UDP</div><div>192.168.0.3:5060ranch=z</div><div>9hG4bKc50f.b4825246.0;received=<a href="tel:87.223.138.84%23015%23" value="+18722313884" target="_blank">87.223.138.84#015#</a>012Via: SIP/2.0/UDP</div>
<div><a href="tel:87.223.138.84" value="+18722313884" target="_blank">87.223.138.84</a>:5060;rport=5060;branch=z9hG4bK1021772993#015#012From:</div>
<div><<a href="mailto:sip%3A1001@candamil.dyndns.org" target="_blank">sip:1001@candamil.dyndns.org</a>>;tag=783852345#015#012To: <</div><div><a href="mailto:sip%3A1002@candamil.dyndns.org" target="_blank">sip:1002@candamil.dyndns.org</a>>#015#012Call-ID: 1644787160#015#012CSeq: 21</div>
<div>INVITE#</div><div>015#012User-Agent: Linphone/3.4.0 (eXosip2/unknown)#015#012Content-Length:</div><div>0#015#012#015#012></div><div>------------------------------------------------------------------------------------------------------------</div>
<div><br></div><div>If the call is from outside to inside the network, it happens the same than in the previous cases.</div><div><br></div><div>This is the relevant kamailio configuration:</div><div><br>
</div><div>-----------------------------------------kamailio.cfg----------------------------------------------------</div><div>#!define WITH_MYSQL</div><div>#!define WITH_AUTH</div><div>#!define WITH_NAT</div><div><br></div>
<div>####### Defined Values #########</div><div><br></div><div># *** Value defines - IDs used later in config</div><div>#!ifdef WITH_MYSQL</div><div># - database URL - used to connect to database server by modules such</div>
<div># as: auth_db, acc, usrloc, a.s.o.</div><div>#!define DBURL "mysql://openser:openserrw@localhost/openser"</div><div>#!endif</div><div>#!ifdef WITH_MULTIDOMAIN</div><div># - the value for 'use_domain' parameters</div>
<div>#!define MULTIDOMAIN 1</div><div>#!else</div><div>#!define MULTIDOMAIN 0</div><div>#!endif</div><div><br></div><div># - flags</div><div># FLT_ - per transaction (message) flags</div><div># FLB_ - per branch flags</div>
<div>#!define FLT_ACC 1</div><div>#!define FLT_ACCMISSED 2</div><div>#!define FLT_ACCFAILED 3</div><div>#!define FLT_NATS 5</div><div><br></div><div>#!define FLB_NATB 6</div><div>#!define FLB_NATSIPPING 7</div><div><br></div>
<div>####### Global Parameters #########</div><div>/* uncomment the next line to disable the auto discovery of local aliases</div><div> based on reverse DNS on IPs (default on) */</div><div>#auto_aliases=no</div><div><br>
</div><div>/* add local domain aliases */</div><div>alias="<a href="http://candamil.dyndns.org" target="_blank">candamil.dyndns.org</a>"</div><div><br></div><div>/* port to listen to</div><div> * - can be specified more than once if needed to listen on many ports */</div>
<div>port=5060</div><div><br></div><div>#!ifdef WITH_TLS</div><div>enable_tls=yes</div><div>#!endif</div><div><br></div><div># life time of TCP connection when there is no traffic</div><div># - a bit higher than registration expires to cope with UA behind NAT</div>
<div>tcp_connection_lifetime=3605</div><div><br></div><div>####### Custom Parameters #########</div><div><br></div><div>#!ifdef WITH_PSTN</div><div># PSTN GW Routing</div><div>#</div><div># - pstn.gw_ip: valid IP or hostname as string value, example:</div>
<div># pstn.gw_ip = "10.0.0.101" desc "My PSTN GW Address"</div><div>#</div><div># - by default is empty to avoid misrouting</div><div>pstn.gw_ip = "" desc "PSTN GW Address"</div><div>
#!endif</div><div><br></div><div>####### Modules Section ########</div><div><br></div><div>#!ifdef WITH_MYSQL</div><div>loadmodule "db_mysql.so"</div><div>#!endif</div><div><br></div><div>#!ifdef WITH_AUTH</div>
<div>loadmodule "auth.so"</div><div>loadmodule "auth_db.so"</div><div><br></div><div>#!ifdef WITH_NAT</div><div>loadmodule "nathelper.so"</div><div>loadmodule "rtpproxy.so"</div><div>
#!endif</div><div><br></div><div># ----------------- setting module-specific parameters ---------------</div><div><br></div><div># ----- auth_db params -----</div><div>#!ifdef WITH_AUTH</div><div>modparam("auth_db", "db_url", DBURL)</div>
<div>modparam("auth_db", "calculate_ha1", yes)</div><div>modparam("auth_db", "password_column", "password")</div><div>modparam("auth_db", "load_credentials", "")</div>
<div>modparam("auth_db", "use_domain", MULTIDOMAIN)</div><div><br></div><div><br></div><div>#!ifdef WITH_NAT</div><div># ----- rtpproxy params -----</div><div>modparam("rtpproxy", "rtpproxy_sock", "udp:<a href="http://127.0.0.1:22222" target="_blank">127.0.0.1:22222</a>")</div>
<div><br></div><div># ----- nathelper params -----</div><div>modparam("nathelper", "natping_interval", 30)</div><div>modparam("nathelper", "ping_nated_only", 1)</div><div>modparam("nathelper", "sipping_bflag", FLB_NATSIPPING)</div>
<div>modparam("nathelper", "sipping_from", "<a href="mailto:sip%3Apinger@kamailio.org" target="_blank">sip:pinger@kamailio.org</a>")</div><div><br></div><div># params needed for NAT traversal in other modules</div>
<div>modparam("nathelper|registrar", "received_avp", "$avp(RECEIVED)")</div><div>modparam("usrloc", "nat_bflag", FLB_NATB)</div><div>#!endif</div><div><br></div><div>####### Routing Logic ########</div>
<div><br></div><div><br></div><div># Main SIP request routing logic</div><div># - processing of any incoming SIP request starts with this route</div><div># - note: this is the same as route { ... }</div><div>request_route {</div>
<div><br></div><div># per request initial checks</div><div>route(REQINIT);</div><div><br></div><div> # NAT detection</div><div>route(NATDETECT);</div><div><br></div><div># handle requests within SIP dialogs</div><div> route(WITHINDLG);</div>
<div><br></div><div>### only initial requests (no To tag)</div><div><br></div><div> # CANCEL processing</div><div>if (is_method("CANCEL"))</div><div>{</div><div> if (t_check_trans())</div><div>t_relay();</div><div>
exit;</div><div> }</div><div><br></div><div>t_check_trans();</div><div><br></div><div># authentication</div><div> route(AUTH);</div><div><br></div><div># record routing for dialog forming requests (in case they are routed)</div>
<div> # - remove preloaded route headers</div><div>remove_hf("Route");</div><div>if (is_method("INVITE|SUBSCRIBE"))</div><div> record_route();</div><div><br></div><div># account only INVITEs</div><div>
if (is_method("INVITE"))</div><div> {</div><div>setflag(FLT_ACC); # do accounting</div><div>}</div><div><br></div><div># dispatch requests to foreign domains</div><div>route(SIPOUT);</div><div><br></div><div> ### requests for my local domains</div>
<div><br></div><div># handle presence related requests</div><div> route(PRESENCE);</div><div><br></div><div># handle registrations</div><div>route(REGISTRAR);</div><div><br></div><div>if ($rU==$null)</div><div>{</div><div>
# request with no Username in RURI</div><div> sl_send_reply("484","Address Incomplete");</div><div>exit;</div><div>}</div><div><br></div><div># dispatch destinations to PSTN</div><div>route(PSTN);</div>
<div><br></div><div> # user location service</div><div>route(LOCATION);</div><div><br></div><div>route(RELAY);</div><div>}</div><div><br></div><div><br></div><div>route[RELAY] {</div><div><br></div><div># enable additional event routes for forwarded requests</div>
<div># - serial forking, RTP relaying handling, a.s.o.</div><div> if (is_method("INVITE|SUBSCRIBE")) {</div><div>t_on_branch("MANAGE_BRANCH");</div><div> t_on_reply("MANAGE_REPLY");</div><div>
}</div><div>if (is_method("INVITE")) {</div><div> t_on_failure("MANAGE_FAILURE");</div><div>}</div><div><br></div><div>if (!t_relay()) {</div><div> sl_reply_error();</div><div>}</div><div>exit;</div><div>
}</div><div><br></div><div># Per SIP request initial checks</div><div>route[REQINIT] {</div><div>#!ifdef WITH_ANTIFLOOD</div><div># flood dection from same IP and traffic ban for a while</div><div> # be sure you exclude checking trusted peers, such as pstn gateways</div>
<div># - local host excluded (e.g., loop to self)</div><div> if(src_ip!=myself)</div><div>{</div><div>if($sht(ipban=>$si)!=$null)</div><div> {</div><div># ip is already blocked</div><div>xdbg("request from blocked IP - $rm from $fu (IP:$si:$sp)\n");</div>
<div> exit;</div><div>}</div><div>if (!pike_check_req())</div><div> {</div><div>xlog("L_ALERT","ALERT: pike blocking $rm from $fu (IP:$si:$sp)\n");</div><div> $sht(ipban=>$si) = 1;</div><div>exit;</div>
<div>}</div><div> }</div><div>#!endif</div><div><br></div><div>if (!mf_process_maxfwd_header("10")) {</div><div> sl_send_reply("483","Too Many Hops");</div><div>exit;</div><div>}</div><div><br>
</div><div>if(!sanity_check("1511", "7"))</div><div>{</div><div>xlog("Malformed SIP message from $si:$sp\n");</div><div> exit;</div><div>}</div><div>}</div><div><br></div><div># Handle requests within SIP dialogs</div>
<div>route[WITHINDLG] {</div><div>if (has_totag()) {</div><div># sequential request withing a dialog should</div><div> # take the path determined by record-routing</div><div>if (loose_route()) {</div><div>if (is_method("BYE")) {</div>
<div> setflag(FLT_ACC); # do accounting ...</div><div>setflag(FLT_ACCFAILED); # ... even if the transaction fails</div><div> }</div><div>if ( is_method("ACK") ) {</div><div># ACK is forwarded statelessy</div><div>
route(NATMANAGE);</div><div>}</div><div>route(RELAY);</div><div> } else {</div><div>if (is_method("SUBSCRIBE") && uri == myself) {</div><div> # in-dialog subscribe requests</div><div>route(PRESENCE);</div>
<div>exit;</div><div> }</div><div>if ( is_method("ACK") ) {</div><div>if ( t_check_trans() ) {</div><div> # no loose-route, but stateful ACK;</div><div># must be an ACK after a 487</div><div># or e.g. 404 from upstream server</div>
<div> t_relay();</div><div>exit;</div><div>} else {</div><div> # ACK without matching transaction ... ignore and discard</div><div>exit;</div><div>}</div><div> }</div><div>sl_send_reply("404","Not here");</div>
<div>}</div><div> exit;</div><div>}</div><div>}</div><div><br></div><div># Handle SIP registrations</div><div>route[REGISTRAR] {</div><div> if (is_method("REGISTER"))</div><div>{</div><div>if(isflagset(FLT_NATS))</div>
<div> {</div><div>setbflag(FLB_NATB);</div><div># uncomment next line to do SIP NAT pinging</div><div> setbflag(FLB_NATSIPPING);</div><div>}</div><div>if (!save("location"))</div><div> sl_reply_error();</div><div>
<br></div><div>exit;</div><div>}</div><div>}</div><div><br></div><div># USER location service</div><div>route[LOCATION] {</div><div><br></div><div>#!ifdef WITH_SPEEDIAL</div><div># search for short dialing - 2-digit extension</div>
<div> if($rU=~"^[0-9][0-9]$")</div><div>if(sd_lookup("speed_dial"))</div><div>route(SIPOUT);</div><div>#!endif</div><div><br></div><div>#!ifdef WITH_ALIASDB</div><div># search in DB-based aliases</div>
<div>if(alias_db_lookup("dbaliases"))</div><div> route(SIPOUT);</div><div>#!endif</div><div><br></div><div>$avp(oexten) = $rU;</div><div>if (!lookup("location")) {</div><div> $var(rc) = $rc;</div><div>
route(TOVOICEMAIL);</div><div>t_newtran();</div><div> switch ($var(rc)) {</div><div>case -1:</div><div>case -3:</div><div> send_reply("404", "Not Found");</div><div>exit;</div><div>case -2:</div><div>
send_reply("405", "Method Not Allowed");</div>
<div>exit;</div><div>}</div><div> }</div><div><br></div><div># when routing via usrloc, log the missed calls also</div><div>if (is_method("INVITE"))</div><div> {</div><div>setflag(FLT_ACCMISSED);</div><div>}</div>
<div>}</div><div><br></div><div># Presence server route</div><div>route[PRESENCE] {</div><div>if(!is_method("PUBLISH|SUBSCRIBE"))</div><div>return;</div><div><br></div><div>#!ifdef WITH_PRESENCE</div><div>if (!t_newtran())</div>
<div>{</div><div>sl_reply_error();</div><div> exit;</div><div>};</div><div><br></div><div>if(is_method("PUBLISH"))</div><div> {</div><div>handle_publish();</div><div>t_release();</div><div> }</div><div>else</div>
<div>if( is_method("SUBSCRIBE"))</div><div> {</div><div>handle_subscribe();</div><div>t_release();</div><div> }</div><div>exit;</div><div>#!endif</div><div> # if presence enabled, this part will not be executed</div>
<div>if (is_method("PUBLISH") || $rU==$null)</div><div> {</div><div>sl_send_reply("404", "Not here");</div><div>exit;</div><div> }</div><div>return;</div><div>}</div><div><br></div><div># Authentication route</div>
<div>route[AUTH] {</div><div>#!ifdef WITH_AUTH</div><div>if (is_method("REGISTER"))</div><div>{</div><div># authenticate the REGISTER requests (uncomment to enable auth)</div><div> if (!www_authorize("$td", "subscriber"))</div>
<div>{</div><div>www_challenge("$td", "0");</div><div> exit;</div><div>}</div><div><br></div><div>if ($au!=$tU)</div><div> {</div><div>sl_send_reply("403","Forbidden auth ID");</div>
<div>exit;</div><div> }</div><div>} else {</div><div><br></div><div>#!ifdef WITH_IPAUTH</div><div>if(allow_source_address())</div><div> {</div><div># source IP allowed</div><div>return;</div><div> }</div><div>#!endif</div>
<div><br></div><div># authenticate if from local subscriber</div><div> if (from_uri==myself)</div><div>{</div><div>if (!proxy_authorize("$fd", "subscriber")) {</div><div> proxy_challenge("$fd", "0");</div>
<div>exit;</div><div>}</div><div> if (is_method("PUBLISH"))</div><div>{</div><div>if ($au!=$fU || $au!=$tU) {</div><div> sl_send_reply("403","Forbidden auth ID");</div><div>exit;</div><div> }</div>
<div>if ($au!=$rU) {</div><div>sl_send_reply("403","Forbidden R-URI");</div><div> exit;</div><div>}</div><div>#!ifdef WITH_MULTIDOMAIN</div><div>if ($fd!=$rd) {</div><div> sl_send_reply("403","Forbidden R-URI domain");</div>
<div>exit;</div><div> }</div><div>#!endif</div><div>} else {</div><div>if ($au!=$fU) {</div><div> sl_send_reply("403","Forbidden auth ID");</div><div>exit;</div><div> }</div><div>}</div><div><br></div>
<div>consume_credentials();</div><div> # caller authenticated</div><div>} else {</div><div># caller is not local subscriber, then check if it calls</div><div> # a local destination, otherwise deny, not an open relay here</div>
<div>if (!uri==myself)</div><div> {</div><div>sl_send_reply("403","Not relaying");</div><div>exit;</div><div> }</div><div>}</div><div>}</div><div>#!endif</div><div>return;</div><div>}</div><div><br></div>
<div># Caller NAT detection route</div><div>route[NATDETECT] {</div><div>#!ifdef WITH_NAT</div><div> force_rport();</div><div>if (nat_uac_test("19")) {</div><div>if (is_method("REGISTER")) {</div><div>
fix_nated_register();</div><div>} else {</div><div>fix_nated_contact();</div><div> }</div><div>setflag(FLT_NATS);</div><div>}</div><div>#!endif</div><div>return;</div><div>}</div><div><br></div><div># RTPProxy control</div>
<div>route[NATMANAGE] {</div><div>#!ifdef WITH_NAT</div><div>if (is_request()) {</div><div> if(has_totag()) {</div><div>if(check_route_param("nat=yes")) {</div><div>setbflag(FLB_NATB);</div><div> }</div><div>}</div>
<div>}</div><div> if (!(isflagset(FLT_NATS) || isbflagset(FLB_NATB)))</div><div>return;</div><div><br></div><div> rtpproxy_manage();</div><div><br></div><div>if (is_request()) {</div><div>if (!has_totag()) {</div><div> add_rr_param(";nat=yes");</div>
<div>}</div><div>}</div><div> if (is_reply()) {</div><div>if(isbflagset(FLB_NATB)) {</div><div>fix_nated_contact();</div><div> }</div><div>}</div><div>#!endif</div><div>return;</div><div>}</div><div><br></div><div># Routing to foreign domains</div>
<div>route[SIPOUT] {</div><div>if (!uri==myself)</div><div>{</div><div> append_hf("P-hint: outbound\r\n");</div><div>route(RELAY);</div><div>}</div><div>}</div><div><br></div><div># PSTN GW routing</div><div>route[PSTN] {</div>
<div>#!ifdef WITH_PSTN</div><div># check if PSTN GW IP is defined</div><div>if (strempty($sel(cfg_get.pstn.gw_ip))) {</div><div> xlog("SCRIPT: PSTN rotuing enabled but pstn.gw_ip not defined\n");</div><div>return;</div>
<div> }</div><div><br></div><div># route to PSTN dialed numbers starting with '+' or '00'</div><div> # (international format)</div><div># - update the condition to match your dialing rules for PSTN routing</div>
<div> if(!($rU=~"^(\+|00)[1-9][0-9]{3,20}$"))</div><div>return;</div><div><br></div><div> # only local users allowed to call</div><div>if(from_uri!=myself) {</div><div>sl_send_reply("403", "Not Allowed");</div>
<div> exit;</div><div>}</div><div><br></div><div>$ru = "sip:" + $rU + "@" + $sel(cfg_get.pstn.gw_ip);</div><div><br></div><div>route(RELAY);</div><div>exit;</div><div>#!endif</div><div><br></div><div>
return;</div>
<div>}</div><div><br></div><div># XMLRPC routing</div><div>#!ifdef WITH_XMLRPC</div><div>route[XMLRPC] {</div><div># allow XMLRPC from localhost</div><div>if ((method=="POST" || method=="GET")</div><div>
&& (src_ip==127.0.0.1)) {</div><div># close connection only for xmlrpclib user agents (there is a bug in</div><div> # xmlrpclib: it waits for EOF before interpreting the response).</div><div>if ($hdr(User-Agent) =~ "xmlrpclib")</div>
<div> set_reply_close();</div><div>set_reply_no_connect();</div><div>dispatch_rpc();</div><div> exit;</div><div>}</div><div>send_reply("403", "Forbidden");</div><div> exit;</div><div>}</div><div>#!endif</div>
<div><br></div><div># route to voicemail server</div><div>route[TOVOICEMAIL] {</div><div>#!ifdef WITH_VOICEMAIL</div><div> if(!is_method("INVITE"))</div><div>return;</div><div><br></div><div># check if VoiceMail server IP is defined</div>
<div> if (strempty($sel(cfg_get.voicemail.srv_ip))) {</div><div>xlog("SCRIPT: VoiceMail rotuing enabled but IP not defined\n");</div><div> return;</div><div>}</div><div>if($avp(oexten)==$null)</div><div> return;</div>
<div><br></div><div>$ru = "sip:" + $avp(oexten) + "@" + $sel(cfg_get.voicemail.srv_ip)</div><div> + $sel(cfg_get.voicemail.srv_port);</div><div>route(RELAY);</div><div>exit;</div><div>#!endif</div><div>
<br></div><div>return;</div><div>}</div><div><br></div><div># manage outgoing branches</div><div>branch_route[MANAGE_BRANCH] {</div><div> xdbg("new branch [$T_branch_idx] to $ru\n");</div><div>route(NATMANAGE);</div>
<div>}</div><div><br></div><div># manage incoming replies</div><div>onreply_route[MANAGE_REPLY] {</div><div>xdbg("incoming reply\n");</div><div>if(status=~"[12][0-9][0-9]")</div><div> route(NATMANAGE);</div>
<div>}</div><div><br></div><div># manage failure routing cases</div><div>failure_route[MANAGE_FAILURE] {</div><div>route(NATMANAGE);</div><div><br></div><div>if (t_is_canceled()) {</div><div>exit;</div><div>}</div><div><br>
</div><div>#!ifdef WITH_BLOCK3XX</div><div># block call redirect based on 3xx replies.</div><div>if (t_check_status("3[0-9][0-9]")) {</div><div> t_reply("404","Not found");</div><div>exit;</div>
<div>}</div><div>#!endif</div><div><br></div><div>#!ifdef WITH_VOICEMAIL</div><div># serial forking</div><div># - route to voicemail on busy or no answer (timeout)</div><div> if (t_check_status("486|408")) {</div>
<div>route(TOVOICEMAIL);</div><div>exit;</div><div> }</div><div>#!endif</div><div>}</div><div>--------------------------------------------------------------------------------------------------------------</div><div><br></div>
<div><br></div><div>I hope you can help me. Thanks for your time.</div>