Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Submitted By: Andreas Westermaier (andwes)
Assigned to: Sergio Gutierrez (saguti)
Summary: Introduce get_auth_id() function for uri_db module
as I have already announced on the users mailing list, I now want to introduce an implementation of the get_auth_id() function for the uri_db module. We especially require this function to enforce an inbound _and_ outbound channel limit for our customers, which have a single authentication id and password but multiple sip accounts (uri's).
A global outbound channel limit for multiple sip accounts of a single user can simply be implemented by adding a dialog profile to the auth-id and realm. But on incoming calls, e.g. from our PSTN gateways, only the r-uri can be accessed. The attached patch adds the get_auth_id() function to the uri_db module to do a reverse-lookup to get the authentication id and realm of a corresponding uri from uri or subscriber table. This way the count of the previously created dialog profile bound to auth-id and realm can be fetched to get the total amount of calls this customer has currently open (inbound and outbound).
The attached patch is against the current svn head and also includes the documentation part.
Thanks a lot for your contribution. As currently we are in freeze period
of SVN because of the upcoming release of OpenSIPS 1.5, we are only
dedicated to bug fixing, so we can not upload your patch at this moment. We
will proceed to review it, and we will incorporate for the next development