[Asterisk-Users] Remote SIP client HACK JOB

Kevin P. Fleming kpfleming at backtobasicsmgmt.com
Wed Jun 30 16:59:17 MST 2004


Ryan Courtnage wrote:

>>With bindaddr = 0.0.0.0 and externip=<external IP> :
>>
> 
> Contact: <sip:*98 at 192.168.1.102>	

OK, so the Asterisk server is not specifying the external IP in the SIP 
header, when it should be. This is probably because when the SIP INVITE 
arrives, it appears to be coming from a internal IP address (your 
port-forwarding firewall), instead of an external address. Granted, 
there are addresses within the SIP INVITE from the phone that are 
external, but the actual IP address that the INVITE arrives from will be 
internal.

With nat=yes in sip.conf for that SIP peer, Asterisk is going to ignore 
the IP address that the SIP client puts into the SIP header, and use the 
actual source IP address instead (this is what is needed when the SIP 
client is behind a NAT and does not know its own external address). I 
suspect you could solve this problem by removing nat=yes from sip.conf 
for this client, since you've eliminated the need for it by using 
port-forwarding.



More information about the asterisk-users mailing list