Hello I'm trying to register in Kamailio, an Asterisk working behind Nat. Here is the trunk:
The problem is: Asterisk is registering with its internal IP (192.168.1.25), as you can see here: sip:s@192.168.1.25 Q= Expires:: 81 Callid:: 480b40aa13ddd8707787b21a69656535@127.0.0.1 Cseq:: 103 User-agent:: Asterisk PBX
How can I force Asterisk to register with its public IP? Is there some configuration I can do in Kamailio? Thanks Regards Joao Pereira
Hi Joao!
There are 2 solutions: Either do the NAT traversal in the proxy (e.g. use the functions from the nathelper module --> see readme of nathelper module) or do the NAT traversal in Asterisk. (e.g. externalIP=..., stun.... - see the default sip.conf of Asterisk)
klaus
Joao Gomes Pereira wrote:
Hello I'm trying to register in Kamailio, an Asterisk working behind Nat. Here is the trunk:
The problem is: Asterisk is registering with its internal IP (192.168.1.25), as you can see here: sip:s@192.168.1.25 Q= Expires:: 81 Callid:: 480b40aa13ddd8707787b21a69656535@127.0.0.1 Cseq:: 103 User-agent:: Asterisk PBX
How can I force Asterisk to register with its public IP? Is there some configuration I can do in Kamailio? Thanks Regards Joao Pereira
El Martes, 1 de Diciembre de 2009, Joao Gomes Pereira escribió:
Hello I'm trying to register in Kamailio, an Asterisk working behind Nat. Here is the trunk:
The problem is: Asterisk is registering with its internal IP (192.168.1.25), as you can see here: sip:s@192.168.1.25 Q= Expires:: 81 Callid:: 480b40aa13ddd8707787b21a69656535@127.0.0.1 Cseq:: 103 User-agent:: Asterisk PBX
How can I force Asterisk to register with its public IP? Is there some configuration I can do in Kamailio?
You can force the external address in sip.conf (externip param) or you can "fix" the signalling NAT issues in Kamailio by using nathelper module.