Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Daniel Kahn Gillmor
Knot DNS Resolver
Commits
3bbdca30
Commit
3bbdca30
authored
Dec 17, 2015
by
Marek Vavruša
Browse files
modules: doc update
parent
7d8938f6
Changes
1
Hide whitespace changes
Inline
Side-by-side
modules/view/README.rst
View file @
3bbdca30
...
...
@@ -11,7 +11,7 @@ There are two identification mechanisms:
* ``subnet``
- identifies the client based on his subnet
* ``
key
``
* ``
tsig
``
- identifies the client based on a TSIG key
You can combine this information with :ref:`policy <mod-policy>` rules.
...
...
@@ -31,7 +31,7 @@ Example configuration
-- Load modules
modules = { 'policy', 'view' }
-- Whitelist queries identified by TSIG key
view:
key
('\5mykey', function (req, qry) return policy.PASS end)
view:
tsig
('\5mykey', function (req, qry) return policy.PASS end)
-- Block local clients (ACL like)
view:addr('127.0.0.1', function (req, qry) return policy.DENY end))
-- Drop queries with suffix match for remote client
...
...
@@ -51,7 +51,7 @@ Properties
Apply rule to clients in given subnet.
.. function:: view:
key(key_name
, rule)
.. function:: view:
tsig(key
, rule)
:param key: client TSIG key domain name, i.e. ``\5mykey``
:param rule: added rule, i.e. ``policy.pattern(policy.DENY, '[0-9]+\2cz')``
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment