Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

fix: panicing on options parsing. #642

Merged
merged 1 commit into from
Mar 1, 2018
Merged

fix: panicing on options parsing. #642

merged 1 commit into from
Mar 1, 2018

Conversation

ldez
Copy link
Contributor

@ldez ldez commented Mar 1, 2018

Fix panic when option have a len of 8 on attempts parsing.

panic: runtime error: slice bounds out of range

goroutine 1 [running]:
github.com/containous/traefik/vendor/github.com/miekg/dns.ClientConfigFromFile(0x211b1eb, 0x10, 0x0, 0x0, 0x0)
      /go/src/github.com/containous/traefik/vendor/github.com/miekg/dns/clientconfig.go:86 +0xad6
github.com/containous/traefik/vendor/github.com/xenolf/lego/acme.getNameservers(0x211b1eb, 0x10, 0x32e9920, 0x2, 0x2, 0x92d9bc, 0xc4202240e0, 0x1)
      /go/src/github.com/containous/traefik/vendor/github.com/xenolf/lego/acme/dns_challenge.go:40 +0x4d
github.com/containous/traefik/vendor/github.com/xenolf/lego/acme.init()
      /go/src/github.com/containous/traefik/vendor/github.com/xenolf/lego/acme/dns_challenge.go:33 +0x12d
github.com/containous/traefik/acme.init()
      <autogenerated>:1 +0x84
main.init()
      <autogenerated>:1 +0x7f

@codecov-io
Copy link

codecov-io commented Mar 1, 2018

Codecov Report

Merging #642 into master will increase coverage by 0.05%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #642      +/-   ##
==========================================
+ Coverage   57.89%   57.94%   +0.05%     
==========================================
  Files          37       37              
  Lines        9989     9989              
==========================================
+ Hits         5783     5788       +5     
+ Misses       3157     3152       -5     
  Partials     1049     1049
Impacted Files Coverage Δ
clientconfig.go 78.08% <100%> (+6.84%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4d25966...0079071. Read the comment docs.

@miekg miekg merged commit 906238e into miekg:master Mar 1, 2018
@ldez ldez deleted the fix/panic branch March 1, 2018 14:53
timbyr added a commit to timbyr/dns that referenced this pull request Mar 9, 2018
Skydns is failing with out of index error when parsing the below.

nameserver 10.0.0.2
search us-west-2.compute.internal
options rotate timeout:2 retries: single-request-reopen

miekg/dns#642
fturib pushed a commit to fturib/dns that referenced this pull request Jun 4, 2018
cbaines pushed a commit to alphagov/tech-ops that referenced this pull request Nov 18, 2020
This uses the same approach as taken for the Observe Prometheus [1].

The issue has been fixed in the upstream library [2] and the fix was
released in version 1.0.5, but the current Ubuntu package is built
with 1.0.4.

1: alphagov/prometheus-aws-configuration-beta#440
2: miekg/dns#642
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants