1
.. _regex_policy_plugin:
3
Regex-based Authorization
4
=========================
6
:program:`regex_policy` is an :doc:`/administration/authorization` plugin
7
that uses regex patterns to match policies.
9
.. _regex_policy_loading:
14
To load this plugin, start :program:`drizzled` with::
16
--plugin-add=regex_policy
18
Loading the plugin may not enable or configure it. See the plugin's
19
:ref:`regex_policy_configuration` and :ref:`regex_policy_variables`.
21
.. seealso:: :ref:`drizzled_plugin_options` for more information about adding and removing plugins.
23
.. _regex_policy_configuration:
28
These command line options configure the plugin when :program:`drizzled`
29
is started. See :ref:`command_line_options` for more information about specifying
34
.. option:: --regex-policy.policy ARG
36
:Default: :file:`drizzle.policy`
37
:Variable: :ref:`regex_policy_policy <regex_policy_policy>`
39
File to load for regex authorization policies.
41
.. _regex_policy_variables:
46
These variables show the running configuration of the plugin.
47
See `variables` for more information about querying and setting variables.
49
.. _regex_policy_policy:
51
* ``regex_policy_policy``
55
:Option: :option:`--regex-policy.policy`
57
File to load for regex authorization policies.
59
.. _regex_policy_file_format:
61
Regex Policy File Format
62
------------------------
64
The general line format of a regex policy file is::
66
USER_PATTERN SCHEMA_OBJECT_PATTERN POLICY
70
# This is a comment line and should be skipped
71
.+ schema=DATA_DICTIONARY ACCEPT
72
.+ schema=INFORMATION_SCHEMA ACCEPT
73
.+ schema=data_dictionary ACCEPT
74
.+ schema=information_schema ACCEPT
77
root process=.+ ACCEPT
78
user1 schema=user1 ACCEPT
79
user2 schema=user2 ACCEPT
80
user1 process=user1 ACCEPT
81
user2 process=user2 ACCEPT
82
# Default to denying everything
89
Sorry, there are no examples for this plugin.
91
.. _regex_policy_authors:
98
.. _regex_policy_version:
103
This documentation applies to **regex_policy 1.0**.
105
To see which version of the plugin a Drizzle server is running, execute:
107
.. code-block:: mysql
109
SELECT MODULE_VERSION FROM DATA_DICTIONARY.MODULES WHERE MODULE_NAME='regex_policy'