[Freeswitch-users] NAT traversal: replacing rttproxy with external RTP IP address in FS

Ben Hood 0x6e6562 at gmail.com
Fri Feb 6 03:53:11 MSK 2015


Hi all,

TL;DR: Does anybody know of a way to convince FS to insert an external
RTP IP into the SDP even if the signalling is coming from a client
behind the same NAT?

I'm currently using kamailio and rtpproxy behind a NAT in conjunction
with FS, but I'd like to eliminate rtpproxy from the equation and get
FS to handle all of the RTP NAT.

I've set the ext-rtp-ip in the SIP profile and FS seems to have
accepted it, but FS still sends out SDPs with the local IP address in
them.

I'm assuming that this is happening because the client that is
forwarding the INVITE is behind the same NAT and therefore FS is not
inserting the external IP address into the SDP, but I might be wrong.

I'm using version 1.4.15-1.

Currently I've got this topology for signalling:

CLIENT <-> PUBLIC INTERNET <-> NAT <-> KAMAILIO <-> FS

And this topology for media:

CLIENT <-> PUBLIC INTERNET <-> NAT <-> RTPPROXY <-> FS

whereby rttproxy advertises itself on a public IP and the external
firewall has static port forwards set up for ephemeral RTP ports.

FS is a B2BUA in this setup.

I'd like to replace the media topology with this:

CLIENT <-> PUBLIC INTERNET <-> NAT <-> FS

and port forward RTP to the FS instance in the firewall.

As a proof of concept hack, I was able to get end to end media going
between two different clients, by rewriting the local IP of the FS
instance in the outgoing SDP on the outbound leg in kamailio.

But I'd like to be able to set the correct external IP as part of the
normal SDP patching process in FS.

Thanks,

Ben



Join us at ClueCon 2016 Aug 8-12, 2016
More information about the FreeSWITCH-users mailing list