Browse code

modules: readme files regenerated - auth_db ... [skip ci]

Kamailio Dev authored on 10/03/2020 11:16:20
Showing 1 changed files
... ...
@@ -50,6 +50,7 @@ Jan Janak
50 50
               3.7. use_domain (integer)
51 51
               3.8. load_credentials (string)
52 52
               3.9. version_table (integer)
53
+              3.10. force_generate_avps (integer)
53 54
 
54 55
         4. Functions
55 56
 
... ...
@@ -71,10 +72,11 @@ Jan Janak
71 72
    1.7. use_domain parameter usage
72 73
    1.8. load_credentials parameter usage
73 74
    1.9. version_table parameter usage
74
-   1.10. www_authorize usage
75
-   1.11. proxy_authorize usage
76
-   1.12. auth_check usage
77
-   1.13. is_subscriber usage
75
+   1.10. force_generate_avps parameter usage
76
+   1.11. www_authorize usage
77
+   1.12. proxy_authorize usage
78
+   1.13. auth_check usage
79
+   1.14. is_subscriber usage
78 80
 
79 81
 Chapter 1. Admin Guide
80 82
 
... ...
@@ -97,6 +99,7 @@ Chapter 1. Admin Guide
97 99
         3.7. use_domain (integer)
98 100
         3.8. load_credentials (string)
99 101
         3.9. version_table (integer)
102
+        3.10. force_generate_avps (integer)
100 103
 
101 104
    4. Functions
102 105
 
... ...
@@ -145,6 +148,7 @@ Chapter 1. Admin Guide
145 148
    3.7. use_domain (integer)
146 149
    3.8. load_credentials (string)
147 150
    3.9. version_table (integer)
151
+   3.10. force_generate_avps (integer)
148 152
 
149 153
 3.1. db_url (string)
150 154
 
... ...
@@ -297,6 +301,19 @@ modparam("auth_db", "load_credentials", "$avp(i:123)=rpid;email_address")
297 301
 modparam("auth_db", "version_table", 0)
298 302
 ...
299 303
 
304
+3.10. force_generate_avps (integer)
305
+
306
+   If set to different than 0, the module will fetch user DB attributes
307
+   even if authentication failed.
308
+
309
+   Default value is “0” (don't fetch user DB attributes if authentication
310
+   failed).
311
+
312
+   Example 1.10. force_generate_avps parameter usage
313
+...
314
+modparam("auth_db", "force_generate_avps", 1)
315
+...
316
+
300 317
 4. Functions
301 318
 
302 319
    4.1. www_authenticate(realm, table [, method])
... ...
@@ -348,7 +365,7 @@ modparam("auth_db", "version_table", 0)
348 365
 
349 366
    This function can be used from REQUEST_ROUTE.
350 367
 
351
-   Example 1.10. www_authorize usage
368
+   Example 1.11. www_authorize usage
352 369
 ...
353 370
 if (!www_authorize("kamailio.org", "subscriber")) {
354 371
         www_challenge("kamailio.org", "1");
... ...
@@ -388,7 +405,7 @@ if (!www_authorize("kamailio.org", "subscriber")) {
388 405
 
389 406
    This function can be used from REQUEST_ROUTE.
390 407
 
391
-   Example 1.11. proxy_authorize usage
408
+   Example 1.12. proxy_authorize usage
392 409
 ...
393 410
 if (!proxy_authorize("$fd", "subscriber)) {
394 411
         proxy_challenge("$fd", "1");  # Realm will be autogenerated
... ...
@@ -439,7 +456,7 @@ if (!proxy_authorize("$fd", "subscriber)) {
439 456
 
440 457
    This function can be used from REQUEST_ROUTE.
441 458
 
442
-   Example 1.12. auth_check usage
459
+   Example 1.13. auth_check usage
443 460
 ...
444 461
 if (!auth_check("$fd", "subscriber", "1")) {
445 462
     auth_challenge("$fd", "1");
... ...
@@ -472,7 +489,7 @@ if (!auth_check("$fd", "subscriber", "1")) {
472 489
 
473 490
    This function can be used from ANY_ROUTE.
474 491
 
475
-   Example 1.13. is_subscriber usage
492
+   Example 1.14. is_subscriber usage
476 493
 ...
477 494
 if (!is_subscriber("$ru", "subscriber", "3")) {
478 495
     # callee is not a local subscriber
Browse code

modules: readme files regenerated - acc ... [skip ci]

Kamailio Dev authored on 28/02/2018 17:03:37 • The Root committed on 28/02/2018 19:11:36
Showing 1 changed files
... ...
@@ -219,7 +219,7 @@ modparam("auth_db", "password_column_2", "ha1_2")
219 219
 3.6. calculate_ha1 (integer)
220 220
 
221 221
    This parameter tells the server whether it should use a pre-calculated
222
-   HA1 string or plaintext passwords for authentification.
222
+   HA1 string or plaintext passwords for authentication.
223 223
 
224 224
    If the parameter is set to 0 and the username parameter of credentials
225 225
    contains also “@domain” (some user agents append the domain to the
... ...
@@ -268,7 +268,7 @@ modparam("auth_db", "use_domain", 1)
268 268
 
269 269
    This parameter specifies of credentials to be fetch from database when
270 270
    the authentication is performed. The loaded credentials will be stored
271
-   in AVPs. If the AVP name is not specificaly given, it will be used a
271
+   in AVPs. If the AVP name is not specifically given, it will be used a
272 272
    NAME AVP with the same name as the column name.
273 273
 
274 274
    Parameter syntax:
... ...
@@ -276,7 +276,7 @@ modparam("auth_db", "use_domain", 1)
276 276
      * credential = (avp_specification '=' column_name) | (column_name)
277 277
      * avp_specification = '$avp(' + 'i:'ID | 's:'NAME | alias + ')'
278 278
 
279
-   Default value of this parameter is “NULL” (no credientials loaded).
279
+   Default value of this parameter is “NULL” (no credentials loaded).
280 280
 
281 281
    Example 1.8. load_credentials parameter usage
282 282
 ...
... ...
@@ -431,7 +431,7 @@ if (!proxy_authorize("$fd", "subscriber)) {
431 431
        user. All other requests: From header must match the authentication
432 432
        user. If bit 2 is set as well (flags==3), the ID check is skipped
433 433
        for INVITE, BYE, PRACK, UPDATE, MESSAGE - these requests can come
434
-       with anonymoys caller id.
434
+       with anonymous caller id.
435 435
        Additionally all domains in the checked URIs and the realm in the
436 436
        authentication header will be checked to match the provided realm
437 437
        parameter.
Browse code

modules: readme files regenerated - auth_db ... [skip ci]

Kamailio Dev authored on 09/02/2017 14:31:15
Showing 1 changed files
... ...
@@ -318,8 +318,9 @@ modparam("auth_db", "version_table", 0)
318 318
    call www_challenge which will challenge the user again.
319 319
 
320 320
    Negative codes may be interpreted as follows:
321
-     * -1 (generic error) - some generic error occurred and no reply was
322
-       sent out;
321
+     * -1 (generic error) - Bad credentials , couldn't parse credentials ,
322
+       no memory left , couldn't fetch from table , couldn't get realm or
323
+       some generic error occurred and no reply was sent out;
323 324
      * -2 (invalid password) - wrong password;
324 325
      * -3 (invalid user) - authentication user does not exist.
325 326
      * -4 (nonce expired) - the nonce has expired
Browse code

core, lib, modules: restructured source code tree

- new folder src/ to hold the source code for main project applications
- main.c is in src/
- all core files are subfolder are in src/core/
- modules are in src/modules/
- libs are in src/lib/
- application Makefiles are in src/
- application binary is built in src/ (src/kamailio)

Daniel-Constantin Mierla authored on 07/12/2016 11:03:51
Showing 1 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,480 @@
1
+Auth_db Module
2
+
3
+Jan Janak
4
+
5
+   FhG Fokus
6
+   <jan@iptel.org>
7
+
8
+Jakob Schlyter
9
+
10
+   <jakob@schlyter.se>
11
+
12
+Bogdan-Andrei Iancu
13
+
14
+   Voice Sistem SRL
15
+   <bogdan@voice-system.ro>
16
+
17
+Daniel-Constantin Mierla
18
+
19
+   <miconda@gmail.com>
20
+
21
+Edited by
22
+
23
+Jan Janak
24
+
25
+   <jan@iptel.org>
26
+
27
+   Copyright © 2002, 2003 FhG FOKUS
28
+
29
+   Copyright © 2005 Voice Sistem SRL
30
+     __________________________________________________________________
31
+
32
+   Table of Contents
33
+
34
+   1. Admin Guide
35
+
36
+        1. Overview
37
+        2. Dependencies
38
+
39
+              2.1. Kamailio Modules
40
+              2.2. External Libraries or Applications
41
+
42
+        3. Parameters
43
+
44
+              3.1. db_url (string)
45
+              3.2. user_column (string)
46
+              3.3. domain_column (string)
47
+              3.4. password_column (string)
48
+              3.5. password_column_2 (string)
49
+              3.6. calculate_ha1 (integer)
50
+              3.7. use_domain (integer)
51
+              3.8. load_credentials (string)
52
+              3.9. version_table (integer)
53
+
54
+        4. Functions
55
+
56
+              4.1. www_authenticate(realm, table [, method])
57
+              4.2. www_authorize(realm, table)
58
+              4.3. proxy_authenticate(realm, table)
59
+              4.4. proxy_authorize(realm, table)
60
+              4.5. auth_check(realm, table, flags)
61
+              4.6. is_subscriber(uri, dbtable, flags)
62
+
63
+   List of Examples
64
+
65
+   1.1. db_url parameter usage
66
+   1.2. user_column parameter usage
67
+   1.3. domain_column parameter usage
68
+   1.4. password_column parameter usage
69
+   1.5. password_column_2 parameter usage
70
+   1.6. calculate_ha1 parameter usage
71
+   1.7. use_domain parameter usage
72
+   1.8. load_credentials parameter usage
73
+   1.9. version_table parameter usage
74
+   1.10. www_authorize usage
75
+   1.11. proxy_authorize usage
76
+   1.12. auth_check usage
77
+   1.13. is_subscriber usage
78
+
79
+Chapter 1. Admin Guide
80
+
81
+   Table of Contents
82
+
83
+   1. Overview
84
+   2. Dependencies
85
+
86
+        2.1. Kamailio Modules
87
+        2.2. External Libraries or Applications
88
+
89
+   3. Parameters
90
+
91
+        3.1. db_url (string)
92
+        3.2. user_column (string)
93
+        3.3. domain_column (string)
94
+        3.4. password_column (string)
95
+        3.5. password_column_2 (string)
96
+        3.6. calculate_ha1 (integer)
97
+        3.7. use_domain (integer)
98
+        3.8. load_credentials (string)
99
+        3.9. version_table (integer)
100
+
101
+   4. Functions
102
+
103
+        4.1. www_authenticate(realm, table [, method])
104
+        4.2. www_authorize(realm, table)
105
+        4.3. proxy_authenticate(realm, table)
106
+        4.4. proxy_authorize(realm, table)
107
+        4.5. auth_check(realm, table, flags)
108
+        4.6. is_subscriber(uri, dbtable, flags)
109
+
110
+1. Overview
111
+
112
+   This module contains all authentication related functions that need the
113
+   access to the database. This module should be used together with auth
114
+   module, it cannot be used independently because it depends on the
115
+   module. Select this module if you want to use database to store
116
+   authentication information like subscriber usernames and passwords. If
117
+   you want to use radius authentication, then use auth_radius instead.
118
+
119
+2. Dependencies
120
+
121
+   2.1. Kamailio Modules
122
+   2.2. External Libraries or Applications
123
+
124
+2.1. Kamailio Modules
125
+
126
+   The module depends on the following modules (in the other words the
127
+   listed modules must be loaded before this module):
128
+     * auth -- Generic authentication functions
129
+     * database -- Any database module (currently mysql, postgres, dbtext)
130
+
131
+2.2. External Libraries or Applications
132
+
133
+   The following libraries or applications must be installed before
134
+   running Kamailio with this module loaded:
135
+     * none
136
+
137
+3. Parameters
138
+
139
+   3.1. db_url (string)
140
+   3.2. user_column (string)
141
+   3.3. domain_column (string)
142
+   3.4. password_column (string)
143
+   3.5. password_column_2 (string)
144
+   3.6. calculate_ha1 (integer)
145
+   3.7. use_domain (integer)
146
+   3.8. load_credentials (string)
147
+   3.9. version_table (integer)
148
+
149
+3.1. db_url (string)
150
+
151
+   This is URL of the database to be used. Value of the parameter depends
152
+   on the database module used. For example for mysql and postgres modules
153
+   this is something like mysql://username:password@host:port/database.
154
+   For dbtext module (which stores data in plaintext files) it is
155
+   directory in which the database resides.
156
+
157
+   Default value is “mysql://kamailioro:kamailioro@localhost/kamailio”.
158
+
159
+   Example 1.1. db_url parameter usage
160
+...
161
+modparam("auth_db", "db_url", "dbdriver://username:password@dbhost/dbname")
162
+...
163
+
164
+3.2. user_column (string)
165
+
166
+   This is the name of the column holding usernames. Default value is fine
167
+   for most people. Use the parameter if you really need to change it.
168
+
169
+   Default value is “username”.
170
+
171
+   Example 1.2. user_column parameter usage
172
+...
173
+modparam("auth_db", "user_column", "user")
174
+...
175
+
176
+3.3. domain_column (string)
177
+
178
+   This is the name of the column holding domains of users. Default value
179
+   is fine for most people. Use the parameter if you really need to change
180
+   it.
181
+
182
+   Default value is “domain”.
183
+
184
+   Example 1.3. domain_column parameter usage
185
+...
186
+modparam("auth_db", "domain_column", "domain")
187
+...
188
+
189
+3.4. password_column (string)
190
+
191
+   This is the name of the column holding passwords. Passwords can be
192
+   either stored as plain text or pre-calculated HA1 strings. HA1 strings
193
+   are MD5 hashes of username, password, and realm. HA1 strings are more
194
+   safe because the server doesn't need to know plaintext passwords and
195
+   they cannot be obtained from HA1 strings.
196
+
197
+   Default value is “ha1”.
198
+
199
+   Example 1.4. password_column parameter usage
200
+...
201
+modparam("auth_db", "password_column", "password")
202
+...
203
+
204
+3.5. password_column_2 (string)
205
+
206
+   As described in the previous section this parameter contains name of
207
+   column holding pre-calculated HA1 string that were calculated including
208
+   the domain in the username. This parameter is used only when
209
+   calculate_ha1 is set to 0 and user agent send a credentials containing
210
+   the domain in the username.
211
+
212
+   Default value of the parameter is ha1b.
213
+
214
+   Example 1.5. password_column_2 parameter usage
215
+...
216
+modparam("auth_db", "password_column_2", "ha1_2")
217
+...
218
+
219
+3.6. calculate_ha1 (integer)
220
+
221
+   This parameter tells the server whether it should use a pre-calculated
222
+   HA1 string or plaintext passwords for authentification.
223
+
224
+   If the parameter is set to 0 and the username parameter of credentials
225
+   contains also “@domain” (some user agents append the domain to the
226
+   username parameter), then the server will use the HA1 values from the
227
+   column specified in the “password_column_2” parameter. If the username
228
+   parameter doesn't contain a domain, the server will use the HA1 values
229
+   from the column given in the “password_column”parameter.
230
+
231
+   If the parameter is set to 1 then the HA1 value will be calculated from
232
+   the column specified in the “password_column” parameter.
233
+
234
+   The “password_column_2”column contain also HA1 strings but they should
235
+   be calculated including the domain in the username parameter (as
236
+   opposed to password_column which (when containing HA1 strings) should
237
+   always contains HA1 strings calculated without domain in username.
238
+
239
+   This ensures that the authentication will always work when using
240
+   pre-calculated HA1 strings, not depending on the presence of the domain
241
+   in username.
242
+
243
+   Default value of this parameter is 0.
244
+
245
+   Example 1.6. calculate_ha1 parameter usage
246
+...
247
+modparam("auth_db", "calculate_ha1", 1)
248
+...
249
+
250
+3.7. use_domain (integer)
251
+
252
+   If true (not 0), domain will be also used when looking up in the
253
+   subscriber table. If you have a multi-domain setup, it is strongly
254
+   recommended to turn on this parameter to avoid username overlapping
255
+   between domains.
256
+
257
+   IMPORTANT: before turning on this parameter, be sure that the domain
258
+   column in subscriber table is properly populated.
259
+
260
+   Default value is “0 (false)”.
261
+
262
+   Example 1.7. use_domain parameter usage
263
+...
264
+modparam("auth_db", "use_domain", 1)
265
+...
266
+
267
+3.8. load_credentials (string)
268
+
269
+   This parameter specifies of credentials to be fetch from database when
270
+   the authentication is performed. The loaded credentials will be stored
271
+   in AVPs. If the AVP name is not specificaly given, it will be used a
272
+   NAME AVP with the same name as the column name.
273
+
274
+   Parameter syntax:
275
+     * load_credentials = credential (';' credential)*
276
+     * credential = (avp_specification '=' column_name) | (column_name)
277
+     * avp_specification = '$avp(' + 'i:'ID | 's:'NAME | alias + ')'
278
+
279
+   Default value of this parameter is “NULL” (no credientials loaded).
280
+
281
+   Example 1.8. load_credentials parameter usage
282
+...
283
+# load rpid column into $avp(i:123) and email_address column
284
+# into $avp(s:email_address)
285
+modparam("auth_db", "load_credentials", "$avp(i:123)=rpid;email_address")
286
+...
287
+
288
+3.9. version_table (integer)
289
+
290
+   If set to 0, the module will skip checking the version for subscriber
291
+   table.
292
+
293
+   Default value is “1 (check for table version)”.
294
+
295
+   Example 1.9. version_table parameter usage
296
+...
297
+modparam("auth_db", "version_table", 0)
298
+...
299
+
300
+4. Functions
301
+
302
+   4.1. www_authenticate(realm, table [, method])
303
+   4.2. www_authorize(realm, table)
304
+   4.3. proxy_authenticate(realm, table)
305
+   4.4. proxy_authorize(realm, table)
306
+   4.5. auth_check(realm, table, flags)
307
+   4.6. is_subscriber(uri, dbtable, flags)
308
+
309
+4.1.  www_authenticate(realm, table [, method])
310
+
311
+   Name alias: www_authorize(realm, table)
312
+
313
+   The function verifies credentials according to RFC2617. If the
314
+   credentials are verified successfully then the function will succeed
315
+   and mark the credentials as authorized (marked credentials can be later
316
+   used by some other functions). If the function was unable to verify the
317
+   credentials for some reason then it will fail and the script should
318
+   call www_challenge which will challenge the user again.
319
+
320
+   Negative codes may be interpreted as follows:
321
+     * -1 (generic error) - some generic error occurred and no reply was
322
+       sent out;
323
+     * -2 (invalid password) - wrong password;
324
+     * -3 (invalid user) - authentication user does not exist.
325
+     * -4 (nonce expired) - the nonce has expired
326
+     * -5 (no credentials) - request does not contain an Authorization
327
+       header with the correct realm.
328
+     * -6 (nonce reused) - the nonce has already been used to authenticate
329
+       a previous request
330
+     * -8 (authuser mismatch) - depending on the method, th From/To/RURI
331
+       user does not match the authentication user (see auth_check()
332
+       function).
333
+
334
+   Meaning of the parameters is as follows:
335
+     * realm - Realm is a opaque string that the user agent should present
336
+       to the user so he can decide what username and password to use.
337
+       Usually this is domain of the host the server is running on.
338
+       It must not be empty string “”. In case of REGISTER requests To
339
+       header field domain (e.g., variable $td) can be used (because this
340
+       header field represents the user being registered), for all other
341
+       messages From header field domain can be used (e.g., variable $fd).
342
+       The string may contain pseudo variables.
343
+     * table - Table to be used to lookup usernames and passwords (usually
344
+       subscribers table).
345
+     * method - the method to be used for authentication. This parameter
346
+       is optional and if not set is the first "word" on the request-line.
347
+
348
+   This function can be used from REQUEST_ROUTE.
349
+
350
+   Example 1.10. www_authorize usage
351
+...
352
+if (!www_authorize("kamailio.org", "subscriber")) {
353
+        www_challenge("kamailio.org", "1");
354
+};
355
+...
356
+
357
+4.2.  www_authorize(realm, table)
358
+
359
+   It is same function as www_authenticate(realm, table). This name is
360
+   kept for backward compatibility, since it was named this way first time
361
+   by it actually does user authentication.
362
+
363
+4.3.  proxy_authenticate(realm, table)
364
+
365
+   Name alias: proxy_authorize(realm, table)
366
+
367
+   The function verifies credentials according to RFC2617. If the
368
+   credentials are verified successfully then the function will succeed
369
+   and mark the credentials as authorized (marked credentials can be later
370
+   used by some other functions). If the function was unable to verify the
371
+   credentials for some reason then it will fail and the script should
372
+   call proxy_challenge which will challenge the user again.
373
+
374
+   Negative return codes have the same meaning as for www_authenticate().
375
+
376
+   Meaning of the parameters is as follows:
377
+     * realm - Realm is a opaque string that the user agent should present
378
+       to the user so he can decide what username and password to use.
379
+       Usually this is domain of the host the server is running on.
380
+       It must not be empty string “”. Apart of a static string, typical
381
+       value is From header field domain (e.g., variable $fd).
382
+       If an empty string “” is used then the server will generate it from
383
+       the request. From header field domain will be used as realm.
384
+       The string may contain pseudo variables.
385
+     * table - Table to be used to lookup usernames and passwords (usually
386
+       subscribers table).
387
+
388
+   This function can be used from REQUEST_ROUTE.
389
+
390
+   Example 1.11. proxy_authorize usage
391
+...
392
+if (!proxy_authorize("$fd", "subscriber)) {
393
+        proxy_challenge("$fd", "1");  # Realm will be autogenerated
394
+};
395
+...
396
+
397
+4.4.  proxy_authorize(realm, table)
398
+
399
+   It is same function as proxy_authenticate(realm, table). This name is
400
+   kept for backward compatibility, since it was named this way first time
401
+   but it actually does user authentication.
402
+
403
+4.5.  auth_check(realm, table, flags)
404
+
405
+   The function combines the functionalities of www_authenticate and
406
+   proxy_authenticate, first being exectuted if the SIP request is a
407
+   REGISTER, the second for the rest.
408
+
409
+   In addition, a matter of flags parameter value, the function checks if
410
+   authentication username matches From/To header username, and
411
+   Request-URI in case of PUBLISH.
412
+
413
+   Negative return codes have the same meaning as for www_authenticate().
414
+
415
+   Meaning of the parameters is as follows:
416
+     * realm - Realm is a opaque string that the user agent should present
417
+       to the user so he can decide what username and password to use.
418
+       Usually this is domain of the host the server is running on.
419
+       It must not be empty string “”. Apart of a static string, typical
420
+       value is From header field domain (e.g., variable $fd).
421
+       The string may contain pseudo variables.
422
+     * table - Table to be used to lookup usernames and passwords (usually
423
+       subscribers table).
424
+       The string may contain pseudo variables.
425
+     * flags - set of flags to control the behaviour of the function. If
426
+       it is 1, then the function will check to see if the authentication
427
+       username matches either To or From header username. REGISTER
428
+       requests: From and To must match the authentication user. PUBLISH
429
+       requests: From, To and Request-URI must match the authentication
430
+       user. All other requests: From header must match the authentication
431
+       user. If bit 2 is set as well (flags==3), the ID check is skipped
432
+       for INVITE, BYE, PRACK, UPDATE, MESSAGE - these requests can come
433
+       with anonymoys caller id.
434
+       Additionally all domains in the checked URIs and the realm in the
435
+       authentication header will be checked to match the provided realm
436
+       parameter.
437
+       The string may contain pseudo variables.
438
+
439
+   This function can be used from REQUEST_ROUTE.
440
+
441
+   Example 1.12. auth_check usage
442
+...
443
+if (!auth_check("$fd", "subscriber", "1")) {
444
+    auth_challenge("$fd", "1");
445
+    exit;
446
+}
447
+...
448
+
449
+4.6.  is_subscriber(uri, dbtable, flags)
450
+
451
+   The function checks if there is a subscriber corresponding to the AoR
452
+   in uri parameter. It uses same database connection as for
453
+   authentication functions.
454
+
455
+   In addition, if the subscriber record is found, then the
456
+   load_credentials attributes are loaded. An use case can be loading the
457
+   credential attributes for callee.
458
+
459
+   Meaning of the parameters is as follows:
460
+     * uri - a valid SIP URI value to identify the subscriber. The string
461
+       may contain pseudo variables.
462
+     * dbtable - Table to be used to lookup username and domain from URI
463
+       (usually subscriber table). The string may contain pseudo
464
+       variables.
465
+     * flags - set of flags to control the behaviour of the function. If
466
+       1st bit is set, then the function will use the domain part of the
467
+       URI to perform the database table search. If 2nd bit is set, then
468
+       the credentials are not loaded in variables (a simple check if
469
+       subscriber exists).
470
+       The parameter may be a pseudo variable.
471
+
472
+   This function can be used from ANY_ROUTE.
473
+
474
+   Example 1.13. is_subscriber usage
475
+...
476
+if (!is_subscriber("$ru", "subscriber", "3")) {
477
+    # callee is not a local subscriber
478
+    ...
479
+}
480
+...