[SR-Users] Get registration information of a specific subscriber in script

Daniel-Constantin Mierla miconda at gmail.com
Tue Oct 19 09:41:51 CEST 2010


  Hello,

the lookup("location") is the one that you look for.

In this particular case, you have to make a backup of r-uri username, 
change it with spa3102 username, do location lookup and then set back 
the r-uri username with pstn number and relay.

There is a function to fetch details of registered contacts for a user, 
see readme of registrar module, but then you have to set manually the 
destination address details.

Cheers,
Daniel

On 10/19/10 3:46 AM, Adieu wrote:
> Hello everybody,
>
> I just started to use kamailio. For the basic functions, I can get
> them working properly.
>
> But when I started to write my own script, I encountered some problem.
>
> The scenario is like this:
>
> I have a linksys spa3102 pstn-voip gateway at home which register
> itself at my server on the internet. I use adsl at home so the ip
> address change dynamically.  When I want to route all my pstn calls to
> spa3102, I have to figure out the current ip address of my home
> connection. I tried to use dynamic dns, but my router does not update
> the ip address sometimes. So I was thinking about solving this problem
> in the kamailio configuration script.
>
> All I need is to get the registration information of spa3102 so that I
> can route my pstn call to it.
>
> I guess there might be a function doing this work. It expect a
> subscriber name as a variable and returns the registration information
> of the subscriber. I tried to dig the function out of kamailio
> documents but failed. And google doesn't seem to provide much help. I
> don't know if this function exist or not. Could someone confirm my
> guess or point out where I can find it? I will be much appreciated.
>
> //bow
>
> Adieu
>
> _______________________________________________
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users at lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

-- 
Daniel-Constantin Mierla
http://www.asipto.com




More information about the sr-users mailing list