[SR-Users] Pseudo variables and uid_domain module compatibility

Daniel-Constantin Mierla miconda at gmail.com
Wed Jan 23 19:32:09 CET 2013


Hi Philippe,

do you have #!SER as first line? This part should be the same ... if pv 
not found, then it should be considered avp. I will try to see what is 
the issue.

Anyhow, for the moment, if not working, load pv and then try:
- $fd and $td must stay as parameters for lookup_domain()
- for strempty() try to use $avp(fd.did) and $avp(td.did)

Cheers,
Daniel

On 1/23/13 5:01 PM, Philippe Sultan wrote:
> Hi,
>
> According to docs of "uid_domain.so", $fd and $td are attribute groups 
> which are set when calling the lookup_domain function, to retrieve 
> domain attributes stored in an DB ($fd.did or $td.did) :
> lookup_domain("$fd", "@from.uri.host");
> lookup_domain("$td", "@ruri.host");
>
> if (strempty($fd.did) && strempty($td.did)) {
>   # Neither the calling nor the called domain is local
>   # This is a relaying attempt which should be forbidden
>   sl_reply("403", "Relaying Forbidden"); drop;
> }
>
> But then, starting Kamailio fails with a configuration file error :
>  0(2098) ERROR: <core> [pvapi.c:761]: error searching pvar "fd"
>  0(2098) ERROR: <core> [pvapi.c:965]: wrong char [d/100] in [$fd] at 
> [2 (0)]
>  0(2098) : <core> [cfg.y:3567]: parse error in config file 
> /usr/local/etc/kamailio/kamailio.cfg, line 332, column 15-17: unknown 
> script pseudo variable $fd
> ERROR: bad config file (1 errors)
>
> Line 332 is :
> if (strempty($fd.did) && strempty($td.did)) {
>
> I thought I could start Kamailio without "pv.so" (and use selects 
> instead), but the error still shows up, as it is reported by the core 
> pvapi.c file.
>
> So I'm kind of stuck, and asking help from the community to fix this 
> problem :D
>
> Philippe
>
>
> _______________________________________________
> 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
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
Kamailio World Conference, April 16-17, 2013, Berlin
  - http://conference.kamailio.com -

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20130123/44843aad/attachment.htm>


More information about the sr-users mailing list