[OpenSIPS-Users] auth_db

nutxase nutxase at proton.me
Wed Jan 18 16:13:47 UTC 2023


anyone have any pointers why uac's wont auth :(

Sent with [Proton Mail](https://proton.me/) secure email.

------- Original Message -------
On Wednesday, January 18th, 2023 at 1:17 PM, nutxase via Users <users at lists.opensips.org> wrote:

> Hey All
>
> I am trying to get my UAC to register to opensips using auth_db
> but i keep getting unathorised, and what i can see is the contact is showing the extension and the phone local ip
>
> any ideas what im missing?
> here is the config
>
> modparam("auth_db", "db_url", "mysql://xxxx:xxx@172.17.0.3/opensips")
> modparam("auth_db", "user_column", "username")
> modparam("auth_db", "password_column", "password")
> modparam("auth_db", "calculate_ha1", 1)
> modparam("auth_db", "use_domain", 1)
> modparam("auth_db", "domain_column", "domain")
> modparam("auth_db", "uri_domain_column", "domain")
> modparam("auth_db", "uri_user_column", "username")
> modparam("auth_db", "load_credentials", "$avp(13)=rpid;email_address")
>
> if (is_method("REGISTER")) {
> if (!www_authorize("[sip.xxx.com](http://sip.sipalto.com)", "subscriber"))
> {
> if (!www_authorize("[sip.xxx.com](http://sip.sipalto.com)", "subscriber"))
> www_challenge("", "auth");
> exit;
> }
> if (!proxy_authorize("", "subscriber"))
> proxy_challenge("", "auth");
> #if (!db_is_from_authorized("uri")) {
> if (!db_does_uri_exist($ru, "subscriber")) {
>
> xlog("User $tu is not authorized to authenticate with $au credential\n");
>
> sl_send_reply(403,"Forbidden auth ID");
> exit;
> }
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20230118/8bce5644/attachment.html>


More information about the Users mailing list