~drizzle-trunk/drizzle/development

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
.. _regex_policy_plugin:

Regex-based Authorization
=========================

:program:`regex_policy` is an :doc:`/administration/authorization` plugin
that uses regex patterns to match policies.

.. _regex_policy_loading:

Loading
-------

To load this plugin, start :program:`drizzled` with::

   --plugin-add=regex_policy

Loading the plugin may not enable or configure it.  See the plugin's
:ref:`regex_policy_configuration` and :ref:`regex_policy_variables`.

.. seealso:: :ref:`drizzled_plugin_options` for more information about adding and removing plugins.

.. _regex_policy_configuration:

Configuration
-------------

These command line options configure the plugin when :program:`drizzled`
is started.  See :ref:`command_line_options` for more information about specifying
command line options.

.. program:: drizzled

.. option:: --regex-policy.policy ARG

   :Default: :file:`drizzle.policy`
   :Variable: :ref:`regex_policy_policy <regex_policy_policy>`

   File to load for regex authorization policies.

.. _regex_policy_variables:

Variables
---------

These variables show the running configuration of the plugin.
See `variables` for more information about querying and setting variables.

.. _regex_policy_policy:

* ``regex_policy_policy``

   :Scope: Global
   :Dynamic: No
   :Option: :option:`--regex-policy.policy`

   File to load for regex authorization policies.

.. _regex_policy_file_format:

Regex Policy File Format
------------------------

The general line format of a regex policy file is::

   USER_PATTERN SCHEMA_OBJECT_PATTERN POLICY

For example::

   # This is a comment line and should be skipped
   .+ schema=DATA_DICTIONARY ACCEPT
   .+ schema=INFORMATION_SCHEMA ACCEPT
   .+ schema=data_dictionary ACCEPT
   .+ schema=information_schema ACCEPT
   root table=.+ ACCEPT
   root schema=.+ ACCEPT
   root process=.+ ACCEPT
   user1 schema=user1 ACCEPT
   user2 schema=user2 ACCEPT
   user1 process=user1 ACCEPT
   user2 process=user2 ACCEPT
   # Default to denying everything
   .+ schema=.+ DENY
   .+ process=.+ DENY

Examples
--------

Sorry, there are no examples for this plugin.

.. _regex_policy_authors:

Authors
-------

Clint Byrum

.. _regex_policy_version:

Version
-------

This documentation applies to **regex_policy 1.0**.

To see which version of the plugin a Drizzle server is running, execute:

.. code-block:: mysql

   SELECT MODULE_VERSION FROM DATA_DICTIONARY.MODULES WHERE MODULE_NAME='regex_policy'

Changelog
---------

v1.0
^^^^
* First release.