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

dnsdist: Check the flags to detect collisions in the packet cache #6747

Merged
merged 1 commit into from Jun 28, 2018

Conversation

Projects
None yet
1 participant
@rgacogne
Member

rgacogne commented Jun 21, 2018

Short description

In the unlikely but quite real event two queries with the same qname, qtype and qclass but different EDNS options or flags end up with the same hash, the packet cache would return a answer that might
not be suitable for the query. Reduce the odds by checking the flags present in the dns header in addition to the qname, qtype and qclass.
For the same reason we might need to consider storing the ECS subnet if any.

Checklist

I have:

  • read the CONTRIBUTING.md document
  • compiled this code
  • tested this code
  • included documentation (including possible behaviour changes)
  • documented the code
  • added or modified regression test(s)
  • added or modified unit test(s)

@rgacogne rgacogne added this to the dnsdist-1.3.x milestone Jun 21, 2018

dnsdist: Check the flags to detect collisions in the packet cache
In the unlikely but quite real event two queries with the same qname,
qtype and qclass but different EDNS options or flags end up with
the same hash, the packet cache would return a answer that might
not be suitable for the query. Reduce the odds by checking the
flags present in the dns header in addition to the qname, qtype
and qclass.
For the same reason we might need to consider storing the ECS
subnet if any.

@rgacogne rgacogne force-pushed the rgacogne:dnsdist-flags-collision branch from 1b3fe00 to 8dcdbdb Jun 22, 2018

@rgacogne rgacogne referenced this pull request Jun 25, 2018

Merged

dnsdist: Detect ECS collisions in the packet cache #6754

7 of 7 tasks complete

@rgacogne rgacogne merged commit fc6e4aa into PowerDNS:master Jun 28, 2018

4 checks passed

LGTM analysis: C/C++ No alert changes
Details
LGTM analysis: JavaScript No alert changes
Details
LGTM analysis: Python No alert changes
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details

@rgacogne rgacogne deleted the rgacogne:dnsdist-flags-collision branch Jun 28, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment