[OpenSIPS-Users] permissions module / OpenSIPS 2.3.2 / register permissions

Bogdan-Andrei Iancu bogdan at opensips.org
Thu Oct 12 15:52:52 EDT 2017


Hi Alexey,

The usage of the "address" table is more generic so you need to do some 
scripting for it.

So, if you decide to have group "1" for blocking registrations, use 
check_source_address("1") before handling a REGISTER request and drop 
the request if the check id true.

Regards,

Bogdan-Andrei Iancu
   OpenSIPS Founder and Developer
   http://www.opensips-solutions.com

On 10/12/2017 10:24 AM, Alexey K. via Users wrote:
> Hello all.
>
> Preface
> ------------------
> - OpenSIPS 2.3.2
> - permissions module (register permissions handling)
>
> I'd like to deny registrations from certain IP, and I've done it 
> successfully using register.deny file.
> But now I'd like to add/remove addresses without restarting OpenSIPS 
> each time.
>
> The MI function 'fifo address_reload' works for 'address' table, not 
> for register.allow/register.deny files.
> (We already use some tables (for dispatcher and LB) as dbtext, works 
> fine.)
>
>
> The Problem:
> ------------------
> So, I have 2 questions:
> 1. the right syntax of filling the txt table (txt structure is here 
> TAR.GZ/opensips-2.3.2/scripts/dbtext/opensips/address and description 
> here 
> http://www.opensips.org/Documentation/Install-DBSchema-2-3#GEN-DB-ADDRESS)
>
> As for now, I have this, but not sure that it's OK (added underlines 
> for better visibility):
>
> id(int,auto) grp(int) ip(string) mask(int) port(int) proto(string) 
> pattern(string,null) context_info(string,null)
> 1_________0 ___10.145.13.5__32____ 0 ______any
> 2_________0 ___10.145.13.11_32____ 0 ______any
>
>
>
> 2. I can not understand where will be the decision applied - either 
> allow or deny?! In case of using register.allow and register.deny it 
> was quite straightforward, and it worked fine. In case of using 
> address table - where have I to set if to allow or to deny?! There are 
> no such fields in the table.
>
> Best regards, Alexey
>
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20171012/c7046ff7/attachment-0001.html>


More information about the Users mailing list