[Asterisk-Users] Talking to other SIP hosts, wrong IP
John Todd
jtodd at loligo.com
Tue Sep 16 21:55:14 MST 2003
>On Mon, 2003-09-15 at 22:35, Shaun Ewing wrote:
>> As per my problem yesterday with the Cisco 7960 and getting it talking to
>> Asterisk on a different subnet, I gave up trying and just put the Asterisk
>> box back on the internal subnet.
>>
>> However, I made two changes:
>>
>> - the external IP address is set on an ethernet alias eth0:0
>> - the main Linux router will change outgoing requests from 10.1.1.2 to the
>> external IP (rather than the default behaviour of NAT) - this seems to work
>> fine in testing.
>>
>> However, I've been trying to register with FWD.
>>
>> If I set the default gateway to be 10.1.0.1, Asterisk tries to register with
>> "Contact: <sip:xxxxx at 10.1.1.2>" (xxxxx = FWD number). Naturally FWD doesn't
>> like this.
>>
>> If I set the default gateway to be the public IP, Asterisk tries to regster
>> with "Contact: <sip:xxxxx at 127.0.0.1>".
>>
>> Does anybody know of a way I can tell external SIP gateways that I'm
>> @203.x.x.x whilst leaving the internal @10.1.1.2 ?
>
> This is the same problem I have trying to register to a SER server
>while * was behind NAT.
> I think if I found some spare time I´ll try to patch sip channel in
>order to register it´s internal IP address and then try the external.
>The idea is the same that Cisco ATAs uses, they register its own IP,
>when they receive the OK response most SIP servers add a
>"received=someip" where that someip is the IP address from they received
>the REGISTER request, normally our external IP address; so we unregister
>the first and register the external IP and change the Contact
>accordingly.
>
>--
>Juan J. Sierralta P. <juanjo at atmlab.utfsm.cl>
>UTFSM
There is already a feature request on the bugtracker for this - feel
free to pick up the project!
http://bugs.digium.com/bug_view_page.php?bug_id=0000104
JT
More information about the asterisk-users
mailing list