Skip to content

Commit

Permalink
Merge pull request #8252 from rgacogne/dnsdist-dynblocks-quiet
Browse files Browse the repository at this point in the history
dnsdist: Add a Lua binding for `DynBlockRulesGroup:setQuiet(quiet)`
  • Loading branch information
rgacogne committed Aug 30, 2019
2 parents a0d790f + 2bd700b commit 287efc4
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions pdns/dnsdist-lua-inspection.cc
Original file line number Diff line number Diff line change
Expand Up @@ -745,5 +745,6 @@ void setupLuaInspection()
g_lua.registerFunction<void(std::shared_ptr<DynBlockRulesGroup>::*)()>("apply", [](std::shared_ptr<DynBlockRulesGroup>& group) {
group->apply();
});
g_lua.registerFunction("setQuiet", &DynBlockRulesGroup::setQuiet);
g_lua.registerFunction("toString", &DynBlockRulesGroup::toString);
}
8 changes: 8 additions & 0 deletions pdns/dnsdistdist/docs/reference/config.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1043,6 +1043,14 @@ faster than the existing rules.

Walk the in-memory query and response ring buffers and apply the configured rate-limiting rules, adding dynamic blocks when the limits have been exceeded.

.. method:: DynBlockRulesGroup:setQuiet(quiet)

.. versionadded:: 1.4.0

Set whether newly blocked clients or domains should be logged.

:param bool quiet: True means that insertions will not be logged, false that they will. Default is false.

.. method:: DynBlockRulesGroup:excludeRange(netmasks)

.. versionadded:: 1.3.1
Expand Down

0 comments on commit 287efc4

Please sign in to comment.