-
Notifications
You must be signed in to change notification settings - Fork 3
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
x509: certificate relies on legacy Common Name field, use SANs instead #276
Comments
One potential workaround is to conditionally disable hostname verification (if requested) when the SANs list is empty. Perhaps something like, |
Going with this option. It's not ideal, but it will work for now. |
- update README coverage - add new (intentionally verbose) flag to disable hostname verification is a certificate's SANs list is empty - update hostname verification handling to skip verification if the SANs list is empty AND the new flag is specified - append "trailer" text noting use of the flag WHEN the SANs list is empty (skipped otherwise) refs GH-276
While What may not be desirable is how/when the error is emitted. Will rely on further use of the tool and potential user feedback before making changes to that tool related to this GH issue. |
- update README coverage - add new (intentionally verbose) flag to disable hostname verification is a certificate's SANs list is empty - update hostname verification handling to skip verification if the SANs list is empty AND the new flag is specified - append "trailer" text noting use of the flag WHEN the SANs list is empty (skipped otherwise) refs GH-276
- update README coverage - add new (intentionally verbose) flag to disable hostname verification is a certificate's SANs list is empty - update hostname verification handling to skip verification if the SANs list is empty AND the new flag is specified - append "trailer" text noting use of the flag WHEN the SANs list is empty (skipped otherwise) refs GH-276
Fixed per #277. |
Note that the flag is used to skip hostname verification if the SANs list is found to be empty, not ignore errors that occur. This text is a holdover from an earlier iteration that I abandoned. refs GH-276
Overview
Recent versions of
check_cert
andlscert
emit this error message when encountering certificates missing Subject Alternate Names (SANs) entries:As detailed by GH-70, Go deprecated support for using the Common Name field to verify hostnames when encountering an empty SANs list. Go 1.16 reiterated this deprecation and Go 1.17 removed the support.
This project switched to Go 1.17 for the v0.5.4 release in preparation for Go 1.16 going EOL in Q1 2022.
While restoring Common Name verification is technically possible, it's not a viable direction for this project. Instead, we should attempt to gracefully handle this scenario when encountered and provide useful feedback to the user so that they can best decide next steps to resolve the issue.
Workarounds:
References
The text was updated successfully, but these errors were encountered: