Jump to content

KAZOO server behind NAT

Recommended Posts

Hi everyone!

I have set a KAZOO server behind NAT. The problem is that Kamailio fills the private IP address in SIP messages.
By modifying some parameters of Kamailio, SIP signaling transmission works well, but RTP forwarding still has problems.
Does anyone know how to configure SDP to use a public IP address?

Any guidance would be appreciated.


Share this post

Link to post
Share on other sites

Hey Tommy,

I would highly suggest you look at this post for help getting Kazoo working behind a NAT.  This discusses using Azure and AWS, all of which use NAT'ng.  Should get you all squared away... 


And to directly add some guidance to your question there, if your signaling is working correctly then you've most likely got Kamailio setup correctly (still double check with link above).  Freeswitch is what handles your media in the Kazoo setup and it needs to be told as well that it's behind a NAT.  

Share this post

Link to post
Share on other sites

if Media is not working, then go to freeswitch configs and change ext-sip-ip and ext-rtp-ip to your public ip since SDP is  running through freeswitch, Kamailio is only handling sip signaling.

Share this post

Link to post
Share on other sites

Hi all,

Thanks for all the answers, much appreciated. It finally worked by referring to Meat's detailed information.
Here is my configuration.

On Freeswitch  

vi /etc/kazoo/freeswitch/sip_profiles/sipinterface_1.xml

<param name="ext-rtp-ip" value="x.x.x.x"/>     ##x.x.x.x is the external IP address you have assigned to this instance

<param name="local-network-acl" value="NOPE"/>  ##this is the setting I hadn't configured before, so the RTP routing had problems.

systemctl restart kazoo-freeswitch


On Kamailio

vi /etc/kazoo/kamailio/local.cfg  

listen=udp:a.a.a.a:5060 advertise x.x.x.x:5060     ##a.a.a.a is your private IP address    x.x.x.x is the external IP address

systemctl restart kazoo-kamailio



  • Like 1

Share this post

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Create New...