[Freeswitch-users] FS uses external IP address for Contact in 200 to internal server

Vallimamod Abdullah vma at vallimamod.org
Fri May 25 08:56:51 UTC 2018


Hi,

> <param name="inbound-proxy-media" value="true"/>
> <param name="local-network-acl" value="localnet.auto"/>
> <param name="ext-rtp-ip" value="$${external_rtp_ip}"/>
> <param name="ext-sip-ip" value="$${external_sip_ip}"/>

These are not channel variables but profile params. So they have to be set on the profile configuration file under sip_profiles.

And for your case, if all your traffic is internal on this profile, remove the last 2 params (ext-sip-ip and est-rtp-ip) as freeswitch use them to set the public ip on the contact and SDP if your server is nated.

Best Regards,
-- 
Vallimamod Abdullah
SIP Solutions
vma at sip.solutions <mailto:vma at sip.solutions>
linkedin.com/in/vallimamod <http://linkedin.com/in/vallimamod>
.



> On 24 May 2018, at 22:43, M Yudkowsky <speech at pobox.com <mailto:speech at pobox.com>> wrote:
> 
> Comrades!
> 
> I'm using FreeSWITCH (FS) as a proxy between an internal server that makes calls and an external SIP provider. The internal server is a speech recognition server that has a telephony component to originate and terminate calls.
> 
> Here's the sequence of messages between the internal server (IS) and FS:
> 
> Starting the call, we see:
> 
> IS (internal IP)  == INVITE ==> FS (internal IP)
> IS (internal IP)  <== 100 == FS (internal IP)
> IS (internal IP)  <== 183 == FS (internal IP)
> 
>   FS gets a connection to SIP provider, and the internal call continues:
> 
> IS (internal IP)  <== 200 OK == FS (internal IP)
> 
>   But the 200 OK from FS contains, in the Contact field, the *external* IP address:
>   Contact: <sip:xxxxx@ <sip:xxxxx@>(external IP):5060;transport=udp>
>   As a result, the IS sends a response to the *external* IP address:
> 
> IS (external IP)  == ACK ==> FS (external IP)
> 
>   FS resends several 200's, which IS properly ignores.
>   Eventually FS gives up on hearing from IS and sends a 
>   BYE with a Reason of 408 ACK Timeout.
> 
> 
> I'm not clear which server is to "blame," if either. FS has "inbound-proxy-media" set to true in (my-dialplan).xml, and I would therefore expect that the Contact field would treat internal servers as internal and use internal IP addresses exclusively. Or is FS correct? Is the problem that IS attempting to do NAT based on the Contact and making an error? (I tried disabling IS's NAT, and almost certainly did it correctly, but that does not seem to help.)
> 
> Variables set in (my_dialplan).xml:
> 
> <param name="inbound-proxy-media" value="true"/>
> <param name="local-network-acl" value="localnet.auto"/>
> <param name="ext-rtp-ip" value="$${external_rtp_ip}"/>
> <param name="ext-sip-ip" value="$${external_sip_ip}"/>
> 
> And the next two were added on in an attempt to fix this, but failed to do so:
> 
> <param name="aggressive-nat-detection" value="true"/>
> <param name="NDLB-force-rport" value="true"/>
> 
> So, any ideas?
> 
> -- 
>  Moshe Yudkowsky
>  Disaggregate Corporation
>  2952 W Fargo
>  Chicago, IL 60645 USA
> 
>  +1 773 764 8727
>   speech at pobox.com <mailto:speech at pobox.com>
> 
>   http://www.Disaggregate.com <http://www.disaggregate.com/>
>   http://www.PebbleAndAvalanche.com <http://www.pebbleandavalanche.com/>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20180525/769682db/attachment-0001.html>


More information about the FreeSWITCH-users mailing list