Copyright © 2003 FhG FOKUS
Copyright © 2005 voice-system.ro
Revision History | |
---|---|
Revision $Revision: 5611 $ | $Date: 2009-04-08 17:39:29 +0200 (Wed, 08 Apr 2009) $ |
Table of Contents
List of Examples
The following modules must be loaded before this module:
a OpenSIPS database module .
URL of the database to be used.
If the db_url string is empty, the default database URL will be used.
Default value is “mysql://opensipsro:opensipsro@localhost/opensips”.
Example 1.1. Set db_url
parameter
... modparam("uri_db", "db_url", "mysql://username:password@localhost/opensips") ...
The DB table that should be used. Its possible to use the
“subscriber” and “uri” table. If the
“uri” table should be used, an additional parameter
(Section 1.3.6, “use_uri_table
(integer)”) must be set.
Default value is “subscriber”.
Column holding usernames in the table.
Default value is “username”.
Column holding domain in the table.
Default value is “domain”.
Column holding URI username in the table.
Default value is “uri_user”.
Specify if the “uri” table should be used for checkings instead of “subscriber” table. A non-zero value means true.
Default value is “0 (false)”.
Specify if the domain part of the URI should be used to identify the users (along with username). This is useful in multi domain setups, a non-zero value means true.
This parameter is only evaluated for calls to “does_uri_exist”, all other functions checks the digest username and realm against the given username, if the “uri” table is used.
Default value is “0 (false)”.
Check To username against URI table (if use_uri_table is set) or digest credentials (no DB backend required).
This function can be used from REQUEST_ROUTE.
Check From username against URI table (if use_uri_table is set) or digest credentials (no DB backend required).
This function can be used from REQUEST_ROUTE.
Check if username in the request URI belongs to an existing user.
As the checking is done against URI table (if use_uri_table is set) or subscriber table.
This function can be used from REQUEST_ROUTE.
Checks given uri-string username against URI table (if use_uri_table is set) or subscriber table (database backend required). Returns true if the user exists in the database, and sets the given variables to the authentication id and realm corresponding to the given uri.
This function can be used from REQUEST_ROUTE.
Example 1.11. get_auth_id
usage
... if (get_auth_id("$ru", "$avp(s:auth_id)", "$avp(s:auth_realm)")) { ... }; ...
Exported statistics are listed in the next sections.