Skip to content
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

Buggy version of miekg/dns in dependencies #3977

Closed
pierresouchay opened this issue Mar 21, 2018 · 3 comments
Closed

Buggy version of miekg/dns in dependencies #3977

pierresouchay opened this issue Mar 21, 2018 · 3 comments

Comments

@pierresouchay
Copy link
Contributor

While trying to improve furthermore #3948 (This pull request is still valid since we are not using Compression to compute the result anyway).

I saw a strange behaviour of dns library.
Basically, msg.Len() and len(msg.Pack()) disagree on Message len.

Thus, calculation of DNS response is false consul relies on msg.Len() instead of the result of Pack()

This is linked to miekg/dns#453 and a fix has been provided with miekg/dns#454

Would it be possible to upgrade miekg/dns to a more recent function ?

Consul might for instance upgrade to a post 1.0 release such as https://github.com/miekg/dns/releases/tag/v1.0.4

I can do a PR if you want.

pierresouchay added a commit to pierresouchay/consul that referenced this issue Mar 21, 2018
See hashicorp#3977

While trying to improve furthermore hashicorp#3948 (This pull request is still valid since we are not using Compression to compute the result anyway).

I saw a strange behaviour of dns library.
Basically, msg.Len() and len(msg.Pack()) disagree on Message len.

Thus, calculation of DNS response is false consul relies on msg.Len() instead of the result of Pack()

This is linked to miekg/dns#453 and a fix has been provided with miekg/dns#454

Would it be possible to upgrade miekg/dns to a more recent function ?

Consul might for instance upgrade to a post 1.0 release such as https://github.com/miekg/dns/releases/tag/v1.0.4
@preetapan
Copy link
Contributor

@pierresouchay PR would be appreciated. We haven't updated that library in a while, and have monkey patched it inside our vendor directory recently. So, we will need to do some additional soak tests on the PR branch once you have it to make sure it doesn't cause regressions before we can merge it.

@pierresouchay
Copy link
Contributor Author

@preetapan Already DONE: #3978

preetapan pushed a commit that referenced this issue Mar 28, 2018
See #3977

While trying to improve furthermore #3948 (This pull request is still valid since we are not using Compression to compute the result anyway).

I saw a strange behaviour of dns library.
Basically, msg.Len() and len(msg.Pack()) disagree on Message len.

Thus, calculation of DNS response is false consul relies on msg.Len() instead of the result of Pack()

This is linked to miekg/dns#453 and a fix has been provided with miekg/dns#454

Would it be possible to upgrade miekg/dns to a more recent function ?

Consul might for instance upgrade to a post 1.0 release such as https://github.com/miekg/dns/releases/tag/v1.0.4
@pierresouchay
Copy link
Contributor Author

Unfortunately the bug is still present for us: miekg/dns#657 :(

@preetapan But thank you for the update of lib anyway

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants