-
-
Notifications
You must be signed in to change notification settings - Fork 14.5k
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
No SSL certificates in nix-shell --pure #66716
Comments
Found #13744 Apparently this is intended behaviour? I still don't understand why there isn't a bundled cert file though. |
The reason that SSL certificates are not bundled with OpenSSL is to allow system-wide certificates to be usable. For instance NixOS has the security.pki module that can be used to add custom certificates. Unfortunately, macOS does not come with an equivalent .crt bundle for us to use. As a result we rely on NIX_SSL_CERT_FILE, SSL_CERT_FILE, or /nix/var/nix/profiles/default/etc/ssl/certs/ca-bundle.crt to exist. I think we can make this situation better by using the SecureTransport backend for curl by default (while still using the purer openssl and gnutls for fetchurl). This would use macOS's Security framework and still allow you to add custom certificates where needed. |
Thanks for the quick reply! I actually stumbled over this when using Currently, |
I marked this as stale due to inactivity. → More info |
I marked this as stale due to inactivity. → More info |
For others finding this: you can also add |
I'm seeing this same issue on NixOS nixos-20.09.3301.42809feaa9f and Ubuntu |
I marked this as stale due to inactivity. → More info |
I don't see any actionable way to fix this except by bundling Can @NixOS/darwin-maintainers chime in and suggest the forward way? |
This isn't macOS specific, as noted in #66716 (comment), and I can confirm we've seen this issue too when using nix as a package manager on ubuntu. How does NixOS handle this? Or are pure nix shells used much more rarely on NixOS, so this hasn't surfaced? |
I always thought it was working as intended, but I'm not sure, will edit the title to reflect it's not macOS specific though. |
Linux repro:
|
Still affects me, but I'm not on MacOS.
Note: the only unstable package on my system is Joplin. This does work:
|
Describe the bug
On macOS, SSL certificates work when using
nix-shell
, but are non-existing innix-shell --pure
.To Reproduce
But this doesn't seem limited to
curl
.Metadata
nix run nixpkgs.nix-info -c nix-info -m
output:Is this expected? If so, feel free to close this issue.
Maybe related to NixOS/nix#921?
The text was updated successfully, but these errors were encountered: