~ubuntu-branches/ubuntu/vivid/drizzle/vivid-proposed

« back to all changes in this revision

Viewing changes to docs/plugins/regex_policy/index.rst

  • Committer: Package Import Robot
  • Author(s): Tobias Frost
  • Date: 2013-08-22 20:18:31 UTC
  • mto: (20.1.1 sid)
  • mto: This revision was merged to the branch mainline in revision 21.
  • Revision ID: package-import@ubuntu.com-20130822201831-gn3ozsh7o7wmc5tk
Tags: upstream-7.2.3
ImportĀ upstreamĀ versionĀ 7.2.3

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
=========================
5
5
 
6
6
:program:`regex_policy` is an :doc:`/administration/authorization` plugin
7
 
that uses regex patterns to match policies.
 
7
that uses regex patterns to match policies. When :program:`drizzled` is started with  ``--plugin-add=regex_policy``, the regex policy plugin is enabled with the default policy file. Policy file can be specified by either specifying ``--regex-policy.policy=<policy file>`` at the time of server startup or by changing the ``regex_policy_policy`` with ``SET GLOBAL``.
8
8
 
9
9
.. _regex_policy_loading:
10
10
 
64
64
The general line format of a regex policy file is::
65
65
 
66
66
   USER_PATTERN SCHEMA_OBJECT_PATTERN POLICY
 
67
   In Drizzle 7 and Drizzle 7.1 the POLICY values supported were 'ACCEPT' and 'DENY'. Beginning with Drizzle 7.2.0, the values used should be 'ALLOW' and 'DENY'. Although 'ACCEPT' and 'REJECT' are also supported for backward compatibility, but their use is deprecated.
67
68
 
68
69
For example::
69
70
 
70
71
   # 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
75
 
   root table=.+ ACCEPT
76
 
   root 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
 
72
   .+ schema=DATA_DICTIONARY ALLOW
 
73
   .+ schema=INFORMATION_SCHEMA ALLOW
 
74
   .+ schema=data_dictionary ALLOW
 
75
   .+ schema=information_schema ALLOW
 
76
   root table=.+ ALLOW
 
77
   root schema=.+ ALLOW
 
78
   root process=.+ ALLOW
 
79
   user1 schema=user1 ALLOW
 
80
   user2 schema=user2 ALLOW
 
81
   user1 process=user1 ALLOW
 
82
   user2 process=user2 ALLOW
82
83
   # Default to denying everything
83
84
   .+ schema=.+ DENY
84
85
   .+ process=.+ DENY
85
86
 
 
87
Changing policy file at runtime
 
88
-------------------------------
 
89
 
 
90
Policy file can be reloaded by::
 
91
 
 
92
   SET GLOBAL regex_policy_policy=@@regex_policy_policy
 
93
 
 
94
Moreover, the policy file can be changed by::
 
95
 
 
96
   SET GLOBAL regex_policy_policy=/path/to/new/policy/file
 
97
 
86
98
Examples
87
99
--------
88
100
 
100
112
Version
101
113
-------
102
114
 
103
 
This documentation applies to **regex_policy 1.0**.
 
115
This documentation applies to **regex_policy 2.0**.
104
116
 
105
117
To see which version of the plugin a Drizzle server is running, execute:
106
118
 
111
123
Changelog
112
124
---------
113
125
 
114
 
v1.0
 
126
v2.0
115
127
^^^^
116
128
* First release.