Module: kamailio Branch: master Commit: 534a35956b1a79598dcd2436248c5d7ce4e92da8 URL: https://github.com/kamailio/kamailio/commit/534a35956b1a79598dcd2436248c5d7ce4e92da8
Author: Donat Zenichev <dzenic...@sipwise.com> Committer: Victor Seva <linuxman...@torreviejawireless.org> Date: 2024-05-27T15:21:24+02:00 permissions: introduce func `allow_register_include_port()` Introduce new function: `allow_register_include_port()` to be able to check the whole Contact header including port. Example, register.deny content is: ALL : "^sip:.*192.168.0.101:5062" If the Contact is: "Contact: <sip:testuser1004@192.168.0.101:5062>" then this will check the Contact hf including port of it. Otherwise if usual `allow_register()` function is used, then only the "testuser1004@192.168.0.101" will be taken into account, which will lead the regex to be failing and letting the check to pass through. The func `allow_register_include_port()` works similarly as `allow_register()` except it checks Contact's port. Full backwards compatibility is kept in place, no need for users of the module to change anything in their configuration or kamailio script itself. --- Modified: src/modules/permissions/doc/permissions.xml Modified: src/modules/permissions/doc/permissions_admin.xml Modified: src/modules/permissions/permissions.c --- Diff: https://github.com/kamailio/kamailio/commit/534a35956b1a79598dcd2436248c5d7ce4e92da8.diff Patch: https://github.com/kamailio/kamailio/commit/534a35956b1a79598dcd2436248c5d7ce4e92da8.patch _______________________________________________ Kamailio (SER) - Development Mailing List To unsubscribe send an email to sr-dev-le...@lists.kamailio.org