-
Notifications
You must be signed in to change notification settings - Fork 62
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
Add support for extended error codes in blocklist-v2 #373
Conversation
Works but could this be extended to the other block types (i.e. |
Just added the same to |
Works now with
Enabling
I'd suggest a bash-like syntax like
( Other (less useful) variables could be
|
Fixed the nil pointer, missed that one earlier. As for the placeholders, I do want to keep using templating offered by the standard library, so can support syntax like |
This is fine by me. Like I said, I don't care how it looks as long as it's documented. As for the IP address, does that work yet? What's the keyword? Or would that not work with these "templates"? |
Finally found a bit of time to work on this again. I simplified the way templates can access query values. Now it's possible to just use |
8055a0e
to
2d0e974
Compare
Supports extended errors for blocklists. The
text
field in the error message is a template that has access to the query and can use that to customize the message.edns0-ede
will only be used if the blocklist actually blocks, not when it just spoofs response IPs.