-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Trust-ad directive causes index is out of range #1230
Comments
[ Quoting <notifications@github.com> in "[miekg/dns] Trust-ad directive caus..." ]
nameserver 127.0.0.11
options edns0 trust-ad ndots:0
I get this error:
I can't replicate. Do you have an example where this library crashes?
It has problems with the trust-ad directive, which is a standard directive, if
I remove it, then it works fine.
Those options healivy depend on your libc. My system doesn't have it.
/Miek
…--
Miek Gieben
|
Well lego is an acme client, it would be a bit complicated to share an example with you. But I can tell you what happens: When I remove the trust-ad from the file, it works just fine. If you still need a proper example, then I will figure something out. |
Doesn't look like something we can fix here
/close
…On Fri, 26 Feb 2021, 22:03 vectomon, ***@***.***> wrote:
Well lego <https://github.com/go-acme/lego> is an acme client, it would
be a bit complicated to share an example with you.
Sadly, I don't know go, so I'm not able to try call
miekg/dns.ClientConfigFromFile myself to try out.
But I can tell you what happens:
Lego passes /etc/resolv.conf to miekg/dns.ClientConfigFromFile (see
<https://github.com/go-acme/lego/blob/7cfcc155ee3c88c9689d5ef5fc76692e2a4867b0/challenge/dns01/nameserver.go#L30>)
and our file contains the text you can see in the OP.
When I remove the trust-ad
<https://man7.org/linux/man-pages/man5/resolv.conf.5.html> from the file,
it works just fine.
If you still need a proper example, then I will figure something out.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#1230 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AACWIW2F525EZS6535LLJLTTBAEDBANCNFSM4YISBBEQ>
.
|
I just dug into this a little, but you must have a really old version of miekg/dns somehow. There was a panic in It was definitely fixed in miekg/dns@v1.1.15 though which is the earliest ever listed in lego's go.mod file. I have no idea how you'd have ended up with an older version than that, but that's the only way it could panic there. You're definitely not using v1.1.15 though because line 94 is, well, this: Line 94 in b136750
Anyhow, you've somehow come to depend on a very old version and there's nothing we can do here because it's already been fixed. Bumping your dependency with |
I'm trying to use lego, which uses this library.
When this library tries to parse our system's
/etc/resolv.conf
, which contains the following content:I get this error:
The problem is that it is indexing out of array, but I don't have the exact text of it. :(
I couldn't try it with the newest version of library, but the functionality of the code should be the same as the v1.1.15 which I have.
It has problems with the trust-ad directive, which is a standard directive, if I remove it, then it works fine.
Could you take a look at it?
Thanks! :)
The text was updated successfully, but these errors were encountered: