-
Notifications
You must be signed in to change notification settings - Fork 18k
crypto/x509: root_darwin.go does not include trusted root certificates from System/Login keychains #20990
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
Comments
I'm really glad to see the non-cgo version of certs getting some careful attention. |
@raszi Give 1.9rc2 a try, it should already have the fix for this. |
I recompiled golang
OSX: Any advice on how to get a workaround. |
@lmayorga1980 is that with, or without, cgo disabled? (try setting CGO_ENABLED=0 when building) |
I didn't 😢 . I will try again when building go. |
Set CGO_ENABLED=0 when building Packer (or whichever app/program you're testing) to get a pure-go version, no need to rebuild Go itself. |
Confirmed. It works for me 👍 🎉 🎈 . My steps:
Thanks. |
@mastercactapus Do you know when this will be available in the core go release? |
@lmayorga1980 I'm not sure whether anything was committed because of this issue, but the 1.10 Go release is scheduled for February 1. https://github.com/golang/go/wiki/Go-Release-Cycle |
Actually, as far as I can tell from the comments above, this is fixed in 1.9, so it is already in a core Go release. But to get a non-cgo version, you'll have to build it yourself, following the comments above, or as described at https://golang.org/doc/install/source setting I'm going to close this issue because I don't see anything to do. Please comment if you disagree. |
This is a bug for tracking the work on the certificate handling in the not cgo version of go.
Intentionally copied over the original bug description from here #14514.
On OS X Yosemite, this issue can be mitigated by installing the certificate into SystemRootCertificates.keychain via /usr/bin/security from the terminal:
However, on El Capitan this is no longer possible without turning off security protections enabled by Apple.
execSecurityRoots
should try to load additional certificates from the System keychain located at/Library/Keychains/System.keychain
, and the Login keychain (~/Library/Keychains/login.keychain
).This bug makes distributing Go clients (especially 3rd-party developed) difficult in organizations with an internal PKI.
The text was updated successfully, but these errors were encountered: