[asterisk-users] Sending Calls via SIP trunk from two different IP addresses from same Asterisk Machine

Tilghman Lesher tilghman at mail.jeffandtilghman.com
Sun Feb 1 13:24:48 CST 2009


On Sunday 01 February 2009 11:32:51 bilal ghayyad wrote:
> I can assign for my Asterisk Machine a two IP addresses (xxx.xxx.xxx.yyy
> and xxx.xxx.xxx.yyz), how can I use these two IP's so I can let one call
> sent with a source IP address xxx.xxx.xxx.yyy and another call to be sent
> with another source IP address xxx.xxx.xxx.yyz, I need this because I need
> the side to authorize my calls by the IP address, and some calls to be
> authorized with the first IP address and other calls to be authorized with
> another IP address, ofcourse I have some reason for this.
>
> The idea is: how to control the source IP address that I am sending from it
> to the other side?
>
> Can I determine the source IP address of the SIP trunk while I am
> configuing my SIP section for that connection? What about the bindaddress?

You cannot.  This behavior is not supported, even in trunk.  What is currently
supported in 1.6.0 and above, however, is responding back on the same IP, if
the opposing SIP server started the request.  This was necessary to support
TCP.  It may no longer be that difficult to support specifying a source IP per
peer, given the changes necessary to support TCP, but as I have not attempted
it, I'll hold off on pronouncing that an easy change.

-- 
Tilghman



More information about the asterisk-users mailing list