[Asterisk-Users] SIP INVITE IP address variable?

BJ Weschke bweschke at gmail.com
Thu Nov 17 22:39:53 MST 2005


On 11/17/05, John Todd <jtodd at loligo.com> wrote:
>
> Perhaps this was already discussed in the archives, but due to the
> generic nature of the keywords I've been unable to find it.  My
> apologies if it's an easy answer.
>
> I am looking for the variable or other method that will allow me to
> determine (from within the dialplan) the IP address of the origin of
> the SIP INVITE message for the current leg.  I know about $SIPURI -
> this is not sufficient.  That describes the SIP URI of the original
> requester.  I need to find the IP address which actually transmitted
> the final INVITE to Asterisk, regardless of the URI or any of the SIP
> headers.  Headers lie.  UDP packets don't.
>
> Note: this is for any SIP INVITE, regardless of if the INVITE is
> received in [general] or if it has a specific peer entry.
>

 JT,

 On a 1.2 machine, you should be able to use the SIPCHANINFO dialplan
function as SIPCHANINFO(recvip) to get what you're looking for.

 BJ

--
Bird's The Word Technologies, Inc.
http://www.btwtech.com/



More information about the asterisk-users mailing list