-
-
Notifications
You must be signed in to change notification settings - Fork 405
[Feat] Unbound: Support per-rule (local-zone) ipset targets #1335
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
EngineersBox
wants to merge
30
commits into
NLnetLabs:master
Choose a base branch
from
EngineersBox:per-ipset-rules
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+747
−116
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Signed-off-by: Jack Kilrain <[email protected]>
Signed-off-by: EngineersBox <[email protected]>
Signed-off-by: EngineersBox <[email protected]>
Signed-off-by: EngineersBox <[email protected]>
…tead of str4list Signed-off-by: EngineersBox <[email protected]>
Currently, the DNS name to ipset mappings are stored in a list which is linear searched. This is obviously sub-optimal, however I am unsure as to what the preferred approach would be for this repo. I noted a RB-tree implementation that could serve as an efficient way to maintain the mappings and avoid the linear search cost. Happy to discuss and plan changes as necessary. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR addresses the issue: #1342
Notes
There are a few things to note, obviously this needs to have Unbound build with ipset support via
--enable-ipset
and the apparmor profile modified to include theCAP_NET_ADMIN
permission as well (necessitated by netlink framework).These changes would need to be included in the Debian package distribution and also potentially some refactor to allow the apparmor profile to be conditionally modified to include the capability when the USE_IPSET env var is detected from the
configure
script (I will raise a separate issue to deal with this as it is a more general problem to be solved with the Debian package).In a BSD distribution, compiled with the packet filter framework, there is no support for TTLs to be set on individual table entries. The only support that pf provides is invoking manual expiry of table entries past a delta of
n
seconds via thepfctl -t <table> -T expire <seconds>
flag (https://man.openbsd.org/pfctl#T~3).Thus no support is added there for TTLs and a suitable warning is raised from the parser when the config is checked.
Chore Additions