uri Module

Table of Contents

1. Admin Guide
1.1. Overview
1.2. Dependencies
1.2.1. OpenSIPS Modules
1.2.2. External Libraries or Applications
1.3. Exported Parameters
1.3.1. aaa_url (string)
1.3.2. service_type (integer)
1.3.3. use_sip_uri_host (integer)
1.4. Exported Functions
1.4.1. aaa_does_uri_exist([pvar])
1.4.2. aaa_does_uri_user_exist([pvar])
2. Contributors
2.1. By Commit Statistics
2.2. By Commit Activity
3. Documentation
3.1. Contributors

List of Tables

2.1. Top contributors by DevScore(1), authored commits(2) and lines added/removed(3)
2.2. Most recently active contributors(1) to this module

List of Examples

1.1. Set aaa_url parameter
1.2. Set service_type parameter
1.3. Set use_sip_uri_host parameter
1.4. aaa_does_uri_exist usage
1.5. aaa_does_uri_user_exist usage

Chapter1.Admin Guide


Various checks related to SIP URI.

This module implements some URI related AAA based tests.


1.2.1.OpenSIPS Modules

At least one of the following modules must be loaded before this module:

  • an aaa protocol module .

1.2.2.External Libraries or Applications

The following libraries or applications must be installed before running OpenSIPS with this module loaded:

  • None.

1.3.Exported Parameters

1.3.1.aaa_url (string)

This is the url representing the AAA protocol used and the location of the configuration file of this protocol.

Example1.1.Set aaa_url parameter

modparam("uri", "aaa_url", "radius:/etc/radiusclient-ng/radiusclient.conf")

1.3.2.service_type (integer)

AAA service type used in aaa_does_uri_exist and aaa_does_uri_user_exist checks.

Default value is 10 (Call-Check).

Example1.2.Set service_type parameter

modparam("uri", "service_type", 11)

1.3.3.use_sip_uri_host (integer)

If zero, aaa_does_uri_exist sends to AAA server Request URI user@host in UserName attribute. If non-zero, aaa_does_uri_exist sends to AAA server Request URI user in UserName attribute and host in SIP-URI-Host attribute.

Default value is 0.

Example1.3.Set use_sip_uri_host parameter

modparam("uri", "use_sip_uri_host", 1)

1.4.Exported Functions

1.4.1. aaa_does_uri_exist([pvar])

Checks from Radius if user@host in Request-URI or in URI stored in pseudo variable argument belongs to a local user. Can be used to decide if 404 or 480 should be returned after lookup has failed. If yes, loads AVP based on SIP-AVP reply items returned from Radius. Each SIP-AVP reply item must have a string value of form:




Returns 1 if Radius returns Access-Accept, -1 if Radius returns Access-Reject, and -2 in case of internal error.

This function can be used from REQUEST_ROUTE.

Example1.4.aaa_does_uri_exist usage

if (aaa_does_uri_exist()) {

1.4.2. aaa_does_uri_user_exist([pvar])

Similar to aaa_does_uri_exist, but check is done based only on Request-URI user part or user stored in pseudo variable argument. User should thus be unique among all users, such as an E.164 number.

This function can be used from REQUEST_ROUTE.

Example1.5.aaa_does_uri_user_exist usage

if (aaa_does_uri_user_exist()) {


2.1.By Commit Statistics

Table2.1.Top contributors by DevScore(1), authored commits(2) and lines added/removed(3)

NameDevScoreCommitsLines ++Lines --
1. Jan Janak (@janakj)48201428877
2. Bogdan-Andrei Iancu (@bogdan-iancu)4427126866
3. Irina-Maria Stanescu2141845111
4. Daniel-Constantin Mierla (@miconda)1612167109
5. Liviu Chircu (@liviuchircu)141085113
6. Juha Heinanen (@juha-h)13744671
7. Razvan Crainea (@razvancrainea)861515
8. Edson Gellert Schubert710309
9. Jiri Kuthan (@jiriatipteldotorg)644331
10. Henning Westerholt (@henningw)631172

All remaining contributors: Andrei Pelinescu-Onciul, Anca Vamanu, Konstantin Bokarius, Sergio Gutierrez, Dusan Klinec, Peter Lemenkov (@lemenkov), Ionut Ionita (@ionutrazvanionita), Elena-Ramona Modroiu, Vlad Patrascu (@rvlad-patrascu).

(1) DevScore = author_commits + author_lines_added / (project_lines_added / project_commits) + author_lines_deleted / (project_lines_deleted / project_commits)

(2) including any documentation-related commits, excluding merge commits. Regarding imported patches/code, we do our best to count the work on behalf of the proper owner, as per the "fix_authors" and "mod_renames" arrays in opensips/doc/build-contrib.sh. If you identify any patches/commits which do not get properly attributed to you, please submit a pull request which extends "fix_authors" and/or "mod_renames".

(3) ignoring whitespace edits, renamed files and auto-generated files

2.2.By Commit Activity

Table2.2.Most recently active contributors(1) to this module

NameCommit Activity
1. Bogdan-Andrei Iancu (@bogdan-iancu)Jan 2006 - Oct 2018
2. Liviu Chircu (@liviuchircu)Oct 2013 - Jul 2018
3. Peter Lemenkov (@lemenkov)Jun 2018 - Jun 2018
4. Vlad Patrascu (@rvlad-patrascu)May 2017 - May 2017
5. Razvan Crainea (@razvancrainea)Jun 2011 - Jan 2016
6. Dusan KlinecDec 2015 - Dec 2015
7. Ionut Ionita (@ionutrazvanionita)Sep 2015 - Sep 2015
8. Irina-Maria StanescuAug 2009 - Dec 2009
9. Sergio GutierrezNov 2008 - Nov 2008
10. Daniel-Constantin Mierla (@miconda)Nov 2006 - Mar 2008

All remaining contributors: Konstantin Bokarius, Edson Gellert Schubert, Juha Heinanen (@juha-h), Henning Westerholt (@henningw), Anca Vamanu, Elena-Ramona Modroiu, Jiri Kuthan (@jiriatipteldotorg), Jan Janak (@janakj), Andrei Pelinescu-Onciul.

(1) including any documentation-related commits, excluding merge commits



Last edited by: Bogdan-Andrei Iancu (@bogdan-iancu), Peter Lemenkov (@lemenkov), Liviu Chircu (@liviuchircu), Ionut Ionita (@ionutrazvanionita), Razvan Crainea (@razvancrainea), Irina-Maria Stanescu, Daniel-Constantin Mierla (@miconda), Konstantin Bokarius, Edson Gellert Schubert, Juha Heinanen (@juha-h), Elena-Ramona Modroiu, Jan Janak (@janakj).

Documentation Copyrights:

Copyright 2005-2009 Voice Sistem SRL

Copyright 2003 FhG FOKUS