e524524fb8b1043dcc87bc1f0db9ee8a1f055d0c
[sip-router] / src / modules / dialplan / doc / dialplan_admin.xml
1 <?xml version="1.0" encoding='ISO-8859-1'?>
2 <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
3 "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
4
5 <!-- Include general documentation entities -->
6 <!ENTITY % docentities SYSTEM "../../../../doc/docbook/entities.xml">
7 %docentities;
8
9 ]>
10
11 <!-- Module User's Guide -->
12
13 <chapter>
14     <title>&adminguide;</title>
15
16         <section id="dialplan.overview">
17         <title>Overview</title>
18         <para>
19         This module implements generic string translations based on matching and
20         replacement rules. It can be used to manipulate the request URI or a PV and to
21         translate it to a new format/value. Dialplan can also be used to match
22         a given URI and retrieve a set of attributes based on the match. It is a very
23         flexible module that can be used to handle call routing, prefix rewrites
24         and much more.
25         </para>
26         </section>
27
28         <section id="dialplan.introduction">
29         <title>How it works</title>
30         <para>
31         At startup the module will load a set of matching and transformation rules from a
32         database. Rules are grouped into dialplans. Every database row will be
33         stored in memory as a dialplan rule. Each rule will describe how the
34         matching will be made, how the input value will be modified and which
35         attributes that will be set for the matching transformation.
36         </para>
37         <para>
38         The module expects an input value which will be matched against a rule
39         by using regular expressions (see 'man pcresyntax' for syntax), string
40         or fnmatch (see 'man fnmatch') matching. Overlapping matching expressions
41         can be controlled via priorities. One priority can have multiple
42         dialplan entries. Priorities need not be numbered with consecutive
43         numbers. The next higher priority will be used after trying to match all
44         entries in one priority.
45         </para>
46         <para>
47         Once a rule is matched, the defined transformation (if any) is applied and
48         the result is returned as output value. Also, if any string attribute is
49         associated to the rule, this will be returned to the script along with
50         the output value. This can be used to identify the used rule.
51         </para>
52         <para>
53         <emphasis> The first matching rule will be processed.</emphasis>
54         </para>
55         </section>
56
57         <section id="dialplan.usecases">
58         <title>Dialplan use cases</title>
59         <para>
60         The module can be used to implement multiple dialplans - to do
61         auto-completion of dialed numbers (like national to international),
62         to convert generic numbers to specific numbers (like for emergency numbers).
63         </para>
64         <para>
65         The module can also be used for detecting a range or sets of numbers mapped
66         on a service/case - the attribute string can be used to store extra
67         information about the service/case.
68         </para>
69         <para>
70         Non-SIP string translation can be implemented - like converting country
71         names from all possible formats to a canonical format:
72         <emphasis>(UK, England, United Kingdom) -> GB.
73         </emphasis></para>
74         <para>
75         Any other string-base translation or detection for whatever other purposes.
76         </para>
77         </section>
78
79
80         <section>
81         <title>Dependencies</title>
82         <section>
83                 <title>&kamailio; Modules</title>
84                 <para>
85                 The following modules must be loaded before this module:
86                         <itemizedlist>
87                         <listitem>
88                         <para>
89                                 <emphasis>A database module</emphasis>
90                         </para>
91                         </listitem>
92                         </itemizedlist>
93                 </para>
94         </section>
95
96
97         <section>
98                 <title>External Libraries or Applications</title>
99                 <para>
100                 The following libraries or applications must be installed before
101                 running &kamailio; with this module loaded:
102                         <itemizedlist>
103                         <listitem>
104                         <para>
105                                  <emphasis>libpcre - the libraries of <ulink url="http://www.pcre.org/">PCRE</ulink></emphasis>.
106                         </para>
107                         </listitem>
108                         </itemizedlist>
109                 </para>
110         </section>
111         </section>
112
113
114         <section>
115         <title>Parameters</title>
116         <section id="dialplan.p.db_url">
117                 <title><varname>db_url</varname> (string)</title>
118                 <para>
119                 The translation rules will be loaded using this database URL.
120                 </para>
121                 <para>
122                 <emphasis>
123                         Default value is
124                                 <quote>&defaultdb;</quote>.
125                 </emphasis>
126                 </para>
127                 <example>
128                 <title>Set <varname>db_url</varname> parameter</title>
129                 <programlisting format="linespecific">
130 ...
131 modparam("dialplan", "db_url", "mysql://user:passwb@localhost/db")
132 ...
133                 </programlisting>
134                 </example>
135         </section>
136
137         <section id="dialplan.p.table_name">
138                 <title><varname>table_name</varname> (string)</title>
139                 <para>
140                 The name of the database table used to load the translation rules.
141                 </para>
142                 <para>
143                 <emphasis>
144                         Default value is <quote>dialplan</quote>.
145                 </emphasis>
146                 </para>
147                 <example>
148                 <title>Set <varname>table_name</varname> parameter</title>
149                 <programlisting format="linespecific">
150 ...
151 modparam("dialplan", "table_name", "my_table")
152 ...
153                 </programlisting>
154                 </example>
155         </section>
156
157         <section id="dialplan.p.dpid_col">
158                 <title><varname>dpid_col</varname> (string)</title>
159                 <para>
160                 The column name used to store the dialplan group ID.
161                 </para>
162                 <para>
163                 <emphasis>
164                         Default value is <quote>dpid</quote>.
165                 </emphasis>
166                 </para>
167                 <example>
168                 <title>Set <varname>dpid_col</varname> parameter</title>
169                 <programlisting format="linespecific">
170 ...
171 modparam("dialplan", "dpid_col", "column_name")
172 ...
173                 </programlisting>
174                 </example>
175         </section>
176
177         <section id="dialplan.p.pr_col">
178                 <title><varname>pr_col</varname> (string)</title>
179                 <para>
180                 The column name used to store the priority of the corresponding rule from the database
181                 row.
182                 </para>
183                 <para>
184                 <emphasis>
185                         Default value is <quote>pr</quote>.
186                 </emphasis>
187                 </para>
188                 <example>
189                 <title>Set <varname>pr_col</varname> parameter</title>
190                 <programlisting format="linespecific">
191 ...
192 modparam("dialplan", "pr_col", "column_name")
193 ...
194                 </programlisting>
195                 </example>
196         </section>
197
198         <section id="dialplan.p.match_op_col">
199                 <title><varname>match_op_col</varname> (string)</title>
200                 <para>
201                 The column name used to store the type of matching of the rule.
202                 </para>
203                 <para>
204                 <emphasis>
205                         Default value is <quote>match_op</quote>.
206                 </emphasis>
207                 </para>
208                 <example>
209                 <title>Set <varname>match_op_col</varname> parameter</title>
210                 <programlisting format="linespecific">
211 ...
212 modparam("dialplan", "match_op_col", "column_name")
213 ...
214                 </programlisting>
215                 </example>
216         </section>
217
218         <section id="dialplan.p.match_exp_col">
219                 <title><varname>match_exp_col</varname> (string)</title>
220                 <para>
221                 The column name to store the rule match expression.
222                 </para>
223                 <para>
224                 <emphasis>
225                         Default value is <quote>match_exp</quote>.
226                 </emphasis>
227                 </para>
228                 <example>
229                 <title>Set <varname>match_exp_col</varname> parameter</title>
230                 <programlisting format="linespecific">
231 ...
232 modparam("dialplan", "match_exp_col", "column_name")
233 ...
234                 </programlisting>
235                 </example>
236         </section>
237
238         <section id="dialplan.p.match_len_col">
239                 <title><varname>match_len_col</varname> (string)</title>
240                 <para>
241                 The column name to store the length of a string matching the
242                 match expression.
243                 </para>
244                 <para>
245                 <emphasis>
246                         Default value is <quote>match_len</quote>.
247                 </emphasis>
248                 </para>
249                 <example>
250                 <title>Set <varname>pr_col</varname> parameter</title>
251                 <programlisting format="linespecific">
252 ...
253 modparam("dialplan", "match_len_col", "column_name")
254 ...
255                 </programlisting>
256                 </example>
257         </section>
258
259         <section id="dialplan.p.subst_exp_col">
260                 <title><varname>subst_exp_col</varname> (string)</title>
261                 <para>
262                 The column name to store the rule's substitution expression.
263                 </para>
264                 <para>
265                 <emphasis>
266                         Default value is <quote>subst_exp</quote>.
267                 </emphasis>
268                 </para>
269                 <example>
270                 <title>Set <varname>pr_col</varname> parameter</title>
271                 <programlisting format="linespecific">
272 ...
273 modparam("dialplan", "subst_exp_col", "column_name")
274 ...
275                 </programlisting>
276                 </example>
277         </section>
278
279         <section id="dialplan.p.repl_exp_col">
280                 <title><varname>repl_exp_col</varname> (string)</title>
281                 <para>
282                 The column name to store the rule's replacement expression.
283                 </para>
284                 <para>
285                 <emphasis>
286                         Default value is <quote>repl_exp</quote>.
287                 </emphasis>
288                 </para>
289                 <example>
290                 <title>Set <varname>repl_exp_col</varname> parameter</title>
291                 <programlisting format="linespecific">
292 ...
293 modparam("dialplan", "repl_exp_col", "column_name")
294 ...
295                 </programlisting>
296                 </example>
297         </section>
298
299         <section id="dialplan.p.attrs_col">
300                 <title><varname>attrs_col</varname> (string)</title>
301                 <para>
302                 The column name to store the rule's attributes to be set after match (see
303                 <varname>attrs_pvar</varname> )
304                 </para>
305                 <para>
306                 <emphasis>
307                         Default value is <quote>attrs</quote>.
308                 </emphasis>
309                 </para>
310                 <example>
311                 <title>Set <varname>attrs_col</varname> parameter</title>
312                 <programlisting format="linespecific">
313 ...
314 modparam("dialplan", "attrs_col", "column_name")
315 ...
316                 </programlisting>
317                 </example>
318         </section>
319
320         <section id="dialplan.p.attrs_pvar">
321                 <title><varname>attrs_pvar</varname> (string)</title>
322                 <para>
323                 The pseudovariable used to store the rule's attributes,
324                 after translation (when <function>dp_translate</function>() succeeds).
325                 This parameter can be an <quote>AVP</quote> or a script variable (<quote>$var()</quote>)..
326                 </para>
327                 <para>
328                 <emphasis>
329                         Default value is <quote>NULL</quote>.
330                 </emphasis>
331                 </para>
332                 <example>
333                 <title>Set <varname>attrs_pvar</varname> parameter</title>
334                 <programlisting format="linespecific">
335 ...
336 modparam("dialplan", "attrs_pvar", "$avp(s:dest)")
337 ...
338                 </programlisting>
339                 </example>
340         </section>
341
342         <section id="dialplan.p.fetch_rows">
343                 <title><varname>fetch_rows</varname> (int)</title>
344                 <para>
345                 The number of rows to be fetched at once from database
346                 </para>
347                 <para>
348                 <emphasis>
349                         Default value is <quote>1000</quote>.
350                 </emphasis>
351                 </para>
352                 <example>
353                 <title>Set <varname>fetch_rows</varname> parameter</title>
354                 <programlisting format="linespecific">
355 ...
356 modparam("dialplan", "fetch_rows", 4000)
357 ...
358                 </programlisting>
359                 </example>
360         </section>
361
362         <section id="dialplan.p.match_dynamic">
363                 <title><varname>match_dynamic</varname> (int)</title>
364                 <para>
365                 If set to 1, the match and substitution expressions can
366                 include script variables and their values are evaluated at
367                 runtime.
368                 </para>
369                 <para>
370                 During the loading process, the values that contain
371                 variables are no longer pre-compiled to PCRE structure in
372                 memory, because the values change at runtime, thus expect slightly
373                 slower performances. Values without script variables are pre-compiled
374                 even if this parameter is enabled.
375                 </para>
376                 <para>
377                 <emphasis>
378                         Default value is <quote>0</quote> (disabled).
379                 </emphasis>
380                 </para>
381                 <example>
382                 <title>Set <varname>match_dynamic</varname> parameter</title>
383                 <programlisting format="linespecific">
384 ...
385 modparam("dialplan", "match_dynamic", 1)
386 ...
387                 </programlisting>
388                 </example>
389         </section>
390         <section id="dialplan.p.append_branch">
391                 <title><varname>append_branch</varname> (int)</title>
392                 <para>
393                 If set to 1, the module appends a new outgoing branch when request
394                 URI (r-uri) or its user part are changed by dp_translate() or
395                 dp_replace() inside a failure_route block. Set it to 0 if the branch
396                 should not be added.
397                 </para>
398                 <para>
399                 <emphasis>
400                         Default value is <quote>1</quote>.
401                 </emphasis>
402                 </para>
403                 <example>
404                 <title>Set <varname>append_branch</varname> parameter</title>
405                 <programlisting format="linespecific">
406 ...
407 modparam("dialplan", "append_branch", 0)
408 ...
409                 </programlisting>
410                 </example>
411         </section>
412
413         <section id="dialplan.p.reload_delta">
414                 <title><varname>reload_delta</varname> (int)</title>
415                 <para>
416                 The number of seconds that have to be waited before executing a new reload
417                 of dialplan rules. By default there is a rate limiting of maximum one reload
418                 in five seconds.
419                 </para>
420                 <para>
421                 If set to 0, no rate limit is configured. Note carefully: use this configuration
422                 only in tests environments because executing two dialplan reloads at the same
423                 time can cause to kamailio to crash.
424                 </para>
425                 <para>
426                 <emphasis>
427                         Default value is <quote>5</quote>.
428                 </emphasis>
429                 </para>
430                 <example>
431                 <title>Set <varname>reload_delta</varname> parameter</title>
432                 <programlisting format="linespecific">
433 ...
434 modparam("dialplan", "reload_delta", 1)
435 ...
436                 </programlisting>
437                 </example>
438         </section>
439
440         </section>
441
442
443         <section>
444         <title>Functions</title>
445
446         <section id="dialplan.p.dp_replace">
447         <title>
448                 <function moreinfo="none">dp_replace(dpid, inval, outvar)</function>
449         </title>
450         <para>
451         The function translates the input value 'inval' using the rules with dialplan
452         id 'dpid', storing the value in the variable 'outvar'. If the rule that was
453         applied has attributes, they are stored in the variable provided via the
454         module parameter 'attrs_pvar'.
455         </para>
456         <para>
457         The behavior is same as dp_translate("dpid", "inval/outvar"), but the
458         parameters have a more flexible format.
459         </para>
460         <para>Meaning of the parameters is as follows:</para>
461         <itemizedlist>
462         <listitem>
463                 <para>
464                 <emphasis>dpid</emphasis> - the dialplan id to match the rules and apply
465                 the transformations. It can be a static string or a config variable
466                 holding an integer value.
467                 </para>
468         </listitem>
469         <listitem>
470                 <para>
471                 <emphasis>inval</emphasis> - input value. It can be a static or a
472                 dynamic string. The dynamic string can contain config variables,
473                 combined or not with static strings, that are evaluated at runtime.
474                 </para>
475     </listitem>
476         <listitem>
477                 <para>
478                 <emphasis>outvar</emphasis> - output variable name. The value resulted
479                 after applying the matching rule is stored in this variable. The name
480                 must refer to a writable variable.
481                 </para>
482     </listitem>
483         </itemizedlist>
484         <para>
485         This function can be used from ANY_ROUTE.
486         </para>
487         <example>
488         <title><function>dp_replace</function> usage</title>
489         <programlisting format="linespecific">
490 ...
491 dp_replace("240", "$rU", "$var(newru)");
492 xlog("'$rU' was translated to '$var(newru)'\n");
493 dp_replace("240", "+49$rU", "$var(newval)");
494 ...
495         </programlisting>
496         </example>
497         </section>
498
499         <section id="dialplan.p.dp_match">
500         <title>
501                 <function moreinfo="none">dp_match(dpid, inval)</function>
502         </title>
503         <para>
504         The function matches the input value 'inval' using the rules with dialplan
505         id 'dpid'. If the rule that was applied has attributes, they are stored in
506         the variable provided via the module parameter 'attrs_pvar'.
507         </para>
508         <para>
509         The behavior is same as dp_translate("dpid", "inval"), but the
510         parameters have a more flexible format.
511         </para>
512         <para>Meaning of the parameters is as follows:</para>
513         <itemizedlist>
514         <listitem>
515                 <para>
516                 <emphasis>dpid</emphasis> - the dialplan id to match the rules and apply
517                 the transformations. It can be a static string or a config variable
518                 holding an integer value.
519                 </para>
520         </listitem>
521         <listitem>
522                 <para>
523                 <emphasis>inval</emphasis> - input value. It can be a static or a
524                 dynamic string. The dynamic string can contain config variables,
525                 combined or not with static strings, that are evaluated at runtime.
526                 </para>
527     </listitem>
528         </itemizedlist>
529         <para>
530         This function can be used from ANY_ROUTE.
531         </para>
532         <example>
533         <title><function>dp_match</function> usage</title>
534         <programlisting format="linespecific">
535 ...
536 dp_match("240", "+49$rU");
537 xlog("the attributes associated with '+49$rU' are '$var(attrs)'\n");
538 ...
539         </programlisting>
540         </example>
541         </section>
542
543         <section id="dialplan.p.dp_translate">
544         <title>
545                 <function moreinfo="none">dp_translate(id, [src[/dest]])</function>
546         </title>
547         <para>
548         Will try to translate <quote>src</quote> into <quote>dest</quote> according to
549         the translation rules in the dialplan identified by <quote>id</quote> .
550         If src/dest is missing the default parameter <quote>ruri.user/ruri.user</quote> will
551         be used, thus translating the request URI user part. If only <quote>dest</quote> is
552         missing, only matching and storing of the matching rule's attributes is done.
553
554         </para>
555         <para>
556           Returns 1, if translation succeeded, -1 in case of some error
557           occurred, and -2 if dialplan with ID equal to id does not exist.
558         </para>
559         <para>Meaning of the parameters is as follows:</para>
560         <itemizedlist>
561         <listitem>
562                 <para>
563                 <emphasis>id</emphasis> -the dialplan id of the possible matching rules.
564                 This parameter can have the following types:
565                 </para>
566                 <itemizedlist>
567                         <listitem>
568                         <para><emphasis>integer</emphasis>- the dialplan id is statically
569                         assigned </para>
570                         </listitem>
571
572                         <listitem>
573                         <para><emphasis>avp var</emphasis>
574                         - the dialplan id is the value of an existing avp variable
575                         </para>
576                         </listitem>
577
578                         <listitem>
579                         <para><emphasis>script var</emphasis>
580                         - the dialplan id is the value of an existing script variable.</para>
581                         </listitem>
582                 </itemizedlist>
583         </listitem>
584
585         <listitem>
586                 <para>
587                 <emphasis>src/dest</emphasis> - input and output of the function.
588                 </para>
589                 <para>Input parameter src can be any pseudo variable.
590                 Output parameter dest can be:
591                 </para>
592                 <itemizedlist>
593                         <listitem>
594                         <para><emphasis>R-URI</emphasis></para>
595                         <para>
596                         - the string is the r-uri or r-uri user part
597                         </para>
598                         </listitem>
599
600                         <listitem>
601                         <para><emphasis>avp var</emphasis> </para>
602                         <para>
603                         - At input the function will get the input string from an existing
604                         avp variable. At output the function will add an avp with the
605                         value of the output string.
606                         </para>
607                         </listitem>
608
609                         <listitem>
610                         <para><emphasis>script var</emphasis> </para>
611                         <para>
612                         - At input the function will get the input string from an existing
613                         script variable. At output the function will set an script variable
614                         with the value of the output string.
615                         </para>
616                         </listitem>
617         </itemizedlist>
618         </listitem>
619         </itemizedlist>
620         <para>
621         This function can be used from ANY_ROUTE.
622         </para>
623         <example>
624         <title><function>dp_translate</function> usage</title>
625         <programlisting format="linespecific">
626 ...
627 dp_translate("240", "$ruri.user/$avp(s:dest)");
628 xlog("translated to var $avp(s:dest) \n");
629 ...
630         </programlisting>
631         </example>
632         <example>
633         <title><function>dp_translate</function> usage</title>
634         <programlisting format="linespecific">
635 ...
636 $avp(s:src) = $ruri.user;
637 dp_translate("$var(x)", "$avp(s:src)/$var(y)");
638 xlog("translated to var $var(y) \n");
639 ...
640         </programlisting>
641         </example>
642
643         </section>
644
645         <section id="dispatcher.f.dp_reload">
646                 <title>
647                 <function moreinfo="none">dp_reload()</function>
648                 </title>
649                 <para>
650                 Reload the translation rules from the database. Note that there is a
651                 rate limiting defined by 'reload_delta' paramenter. By default is allowed
652                 maximum one reload in five seconds.
653                 </para>
654                 <para>
655                 Name: <emphasis>dp_reload</emphasis>
656                 </para>
657                 <para>Parameters: <emphasis>none</emphasis></para>
658                 <para>
659                 This function can be used from ANY_ROUTE.
660                 </para>
661         </section>
662
663         </section>
664
665
666         <section>
667         <title>RPC Commands</title>
668
669                 <section id="dialplan.r.dp.dump">
670                         <title><varname>dialplan.dump</varname></title>
671                         <para>
672                         Dumps the content of one dialplan ID
673                         </para>
674                         <para>
675                         Name: <emphasis>dialplan.dump</emphasis>
676                         </para>
677                         <para>Parameters: <emphasis>Dialplan ID</emphasis></para>
678                         <para>
679                         Example:
680                         </para>
681         <programlisting  format="linespecific">
682                 &kamcmd; dialplan.dump 100
683                 </programlisting>
684                 </section>
685                 <section id="dialplan.r.dp.reload">
686                         <title><varname>dialplan.reload</varname></title>
687                         <para>
688                         Forces an update of the translation rules from the database.
689                         </para>
690                         <para>
691                         Name: <emphasis>dialplan.reload</emphasis>
692                         </para>
693                         <para>Parameters: <emphasis>none</emphasis></para>
694                         <para>
695                         Example:
696                         </para>
697         <programlisting  format="linespecific">
698                 &kamcmd; dialplan.reload
699                 </programlisting>
700                 </section>
701
702                 <section id="dialplan.r.dp.translate">
703                         <title><varname>dialplan.translate</varname></title>
704                         <para>
705                         Will apply a translation rule identified by a dialplan
706                         id and an input string.
707                         </para>
708                         <para>
709                         Name: <emphasis>dialplan.translate</emphasis>
710                         </para>
711                         <para>Parameters: <emphasis>2</emphasis></para>
712                         <itemizedlist>
713                         <listitem>
714                                         <para><emphasis>Dial plan ID</emphasis> (number)</para>
715                         </listitem>
716                         <listitem>
717                                         <para><emphasis>Input string</emphasis> (string) - it
718                                         can be prefixed with 's:' to avoid auto-conversion when
719                                         the command is executed with CLI apps such as &kamcmd;.</para>
720                         </listitem>
721                         </itemizedlist>
722                         <para>
723                         Example:
724                         </para>
725                 <programlisting  format="linespecific">
726                 &kamcmd; dialplan.translate 1 "abcdxyz"
727                 &kamcmd; dialplan.translate 1 s:123456789
728                 </programlisting>
729                 </section>
730         </section>
731
732         <section id="dialplan.installation">
733             <title>Installation</title>
734             <para>
735                 The modules requires one table in &kamailio; database: dialplan.
736                 The SQL syntax to create them can be found in dialplan-create.sql
737                  script in the database directories in the kamailio/scripts folder.
738                 You can also find the complete database documentation on the
739                 project webpage, &kamailiodbdocslink;.
740                 </para>
741                 <para>
742                 Some sample records from a dialplan table are presented in the next
743                 figure.
744                 </para>
745                 <example>
746                 <title>Example of rules</title>
747                 <programlisting format="linespecific">
748 ...
749 dpid: 1
750 pr: 1
751 match_op: 1
752 match_exp: ^0[1-9][0-9]+$
753 match_len: 0
754 subst_exp: ^0([1-9][0-9]+)$
755 repl_exp: 0049\1
756 attrs: de
757 ...
758 dpid: 1
759 pr: 2
760 match_op: 1
761 match_exp: ^0[1-9][0-9]+$
762 match_len: 0
763 subst_exp: ^0(.+)$
764 repl_exp: $var(prefix)\1
765 attrs: xyz
766 ...
767                 </programlisting>
768                 </example>
769                 <para>
770                 Note that you can use config variables in the replacement expression
771                 (repl_exp) field. However, not all of config variables are safe to use
772                 there - specifically the variables that have in their name other
773                 variables (variables with dynamic name). References to SIP message,
774                 private variables ($var(...)) and AVPs with static name are among
775                 those that are safe to use in replacement expressions.
776                 </para>
777                 <para>
778                 The match_op field specify matching operator, valid values:
779                 <itemizedlist>
780                 <listitem>
781                 0 - string comparison;
782                 </listitem>
783                 <listitem>
784                 1 - regular expression matching (pcre);
785                 </listitem>
786                 <listitem>
787                 2 - fnmatch (shell-like pattern) matching.
788                 </listitem>
789                 </itemizedlist>
790                 </para>
791     </section>
792
793 </chapter>