-
-
Notifications
You must be signed in to change notification settings - Fork 358
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
Downstream DNS Server Cookies a la RFC7873 and RFC9018 #762
Conversation
Create server cookies for clients that send client cookies. Needs to be turned on in the config file with: answer-cookie: yes A cookie-secret can be configured for anycast setups. Also adds an access control list that will allow queries with either a valid cookie or over a stateful transport.
…heir own file in util/rfc_1982.[ch].
…figparser.c, configparser.h).
by allowing Cookies to bypass the ratelimit, but still allowing ratelimit to valid DNS Cookie clients via the new ip-ratelimit-cookie option.
thread and total: num.queries_cookie_valid, num.queries_cookie_client, num.queries.cookie_invalid.
@wcawijngaards, with the recent changes for refactoring, unit/rpl/tdir tests, cookie/ip_ratelimiting interaction and new stat counters for queries with cookies, I believe this is ready for merging after your final review :) |
8 bytes after a client option of length 8, and then ignore them to recreate a 24 byte response. The fixup does not read out of bounds, and puts zeroes in the buffer at that point, that then are ignored.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed the code and committed couple of fixes. Nice to have the additional feature.
- Merge PR #762: Downstream DNS Server Cookies a la RFC7873 and RFC9018. Create server cookies for clients that send client cookies. This needs to be explicitly turned on in the config file with: `answer-cookie: yes`. A `cookie-secret:` can be configured for anycast setups. Without one, a random cookie secret is generated. The acl option `allow_cookie` allows queries with either a valid cookie or over a stateful transport. The statistics output has `queries_cookie_valid` and `queries_cookie_client` and `queries_cookie_invalid` information. The `ip\-ratelimit\-cookie:` value determines a rate limit for queries with cookies, if desired.
Create server cookies for clients that send client cookies.
This needs to be explicitly turned on in the config file with:
A
cookie-secret:
can be configured for anycast setups. Without one, a random cookie secret is generated.This PR also adds an access control list policy
allow_cookie
that allows queries with either a valid cookie or over a stateful transport.This PR replaces #322