[OpenSIPS-Users] Registrar with IP authentication - selecting variables from DB

Răzvan Crainea razvan at opensips.org
Wed Jan 18 03:33:06 EST 2017


You are probably using an old version of OpenSIPS, that's why you are 
not seeing negative return values.

Checking if the IP might still be ok, if your database is consistent and 
has an IP for every user. So for now I would go with this solution.

Best regards,

Răzvan Crainea
OpenSIPS Solutions
www.opensips-solutions.com

On 01/17/2017 11:03 AM, maatohewetbi wrote:
> I've just did it like this:
>
> xlog("$rc");
> and on Friday I got
> 18446744073709551615
> so You were right that it was unsigned int. But now if I want to read
> xlog("$rc") it has 1 value. And my table is empty.
> Now I've changed script and it looks:
>
> if ($avp(s:ip) == null ) {
>       xlog("no results found in DB");
>       xlog("$rc");
>
> and it is ok, and works like it should, because $avp(s:ip) is NULL when
> there's no records found. But I'm afraid it's not the best solution. What do
> You think?
>
>
>
> --
> View this message in context: http://opensips-open-sip-server.1449251.n2.nabble.com/Registrar-with-IP-authentication-selecting-variables-from-DB-tp7605514p7605600.html
> Sent from the OpenSIPS - Users mailing list archive at Nabble.com.
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users




More information about the Users mailing list