~drizzle-trunk/drizzle/development

2397.1.1 by Daniel Nichter
Skeleton documentation for all plugins, more complete docu for first half of plugins.
1
Regex-based Authorization
2
=========================
3
2397.1.3 by Daniel Nichter
Complete documenting 2nd half of plugins.
4
:program:`regex_policy` is an :doc:`/administration/authorization` plugin
5
that uses regex patterns to match policies.
2397.1.1 by Daniel Nichter
Skeleton documentation for all plugins, more complete docu for first half of plugins.
6
7
.. _regex_policy_loading:
8
9
Loading
10
-------
11
12
To load this plugin, start :program:`drizzled` with::
13
14
   --plugin-add=regex_policy
15
16
Loading the plugin may not enable or configure it.  See the plugin's
17
:ref:`regex_policy_configuration` and :ref:`regex_policy_variables`.
18
19
.. seealso:: :doc:`/options` for more information about adding and removing plugins.
20
21
.. _regex_policy_configuration:
22
23
Configuration
24
-------------
25
26
These command line options configure the plugin when :program:`drizzled`
27
is started.  See :doc:`/configuration` for more information about specifying
28
command line options.
29
30
.. program:: drizzled
31
32
.. option:: --regex-policy.policy ARG
33
2397.1.3 by Daniel Nichter
Complete documenting 2nd half of plugins.
34
   :Default: :file:`drizzle.policy`
2397.1.1 by Daniel Nichter
Skeleton documentation for all plugins, more complete docu for first half of plugins.
35
   :Variable: :ref:`regex_policy_policy <regex_policy_policy>`
36
2397.1.3 by Daniel Nichter
Complete documenting 2nd half of plugins.
37
   File to load for regex authorization policies.
2397.1.1 by Daniel Nichter
Skeleton documentation for all plugins, more complete docu for first half of plugins.
38
39
.. _regex_policy_variables:
40
41
Variables
42
---------
43
44
These variables show the running configuration of the plugin.
45
See `variables` for more information about querying and setting variables.
46
47
.. _regex_policy_policy:
48
49
* ``regex_policy_policy``
50
51
   :Scope: Global
52
   :Dynamic: No
53
   :Option: :option:`--regex-policy.policy`
54
2397.1.3 by Daniel Nichter
Complete documenting 2nd half of plugins.
55
   File to load for regex authorization policies.
56
57
.. _regex_policy_file_format:
58
59
Regex Policy File Format
60
------------------------
61
62
The general line format of a regex policy file is::
63
64
   USER_PATTERN SCHEMA_OBJECT_PATTERN POLICY
65
66
For example::
67
68
   # This is a comment line and should be skipped
69
   .+ schema=DATA_DICTIONARY ACCEPT
70
   .+ schema=INFORMATION_SCHEMA ACCEPT
71
   .+ schema=data_dictionary ACCEPT
72
   .+ schema=information_schema ACCEPT
73
   root table=.+ ACCEPT
74
   root schema=.+ ACCEPT
75
   root process=.+ ACCEPT
76
   user1 schema=user1 ACCEPT
77
   user2 schema=user2 ACCEPT
78
   user1 process=user1 ACCEPT
79
   user2 process=user2 ACCEPT
80
   # Default to denying everything
81
   .+ schema=.+ DENY
82
   .+ process=.+ DENY
2397.1.1 by Daniel Nichter
Skeleton documentation for all plugins, more complete docu for first half of plugins.
83
84
Examples
85
--------
86
87
Sorry, there are no examples for this plugin.
88
89
.. _regex_policy_authors:
90
91
Authors
92
-------
93
94
Clint Byrum
95
96
.. _regex_policy_version:
97
98
Version
99
-------
100
101
This documentation applies to **regex_policy 1.0**.
102
103
To see which version of the plugin a Drizzle server is running, execute:
104
105
.. code-block:: mysql
106
107
   SELECT MODULE_VERSION FROM DATA_DICTIONARY.MODULES WHERE MODULE_NAME='regex_policy'
108
2397.1.3 by Daniel Nichter
Complete documenting 2nd half of plugins.
109
Changelog
110
---------
111
112
v1.0
113
^^^^
114
* First release.