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

Fix default retry policy for certificate verification errors and bad request headers #210

Merged
merged 3 commits into from May 9, 2024

Conversation

tomclegg
Copy link
Contributor

@tomclegg tomclegg commented Dec 1, 2023

Go 1.20 started returning *tls.CertificateVerificationError instead of x509.UnknownAuthorityError for the tested certificate problem. The new error type check doesn't compile in old versions of Go because the type didn't exist yet, so this PR puts the old and new type checks in separate files with appropriate build tags. Fixes #176

This also updates the default policy to disable retry after a "bad (outgoing) header" error from net/http.

@tomclegg tomclegg requested a review from a team as a code owner December 1, 2023 22:20
@hashicorp-cla
Copy link

hashicorp-cla commented Dec 1, 2023

CLA assistant check
All committers have signed the CLA.

@manicminer manicminer added the bug label May 9, 2024
@tomclegg tomclegg requested a review from a team as a code owner May 9, 2024 16:11
Copy link
Member

@manicminer manicminer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Many thanks @tomclegg for this fix, this LGTM 👍

@manicminer manicminer merged commit 1643719 into hashicorp:main May 9, 2024
4 checks passed
manicminer added a commit that referenced this pull request May 9, 2024
@manicminer manicminer added this to the v0.7.6 milestone May 9, 2024
manicminer added a commit that referenced this pull request May 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
3 participants