From 52e1e16cee983c7ac2041db8e3ab4174b95f6b67 Mon Sep 17 00:00:00 2001 From: Pawlicker <92184373+Pawlicker@users.noreply.github.com> Date: Sat, 24 Jun 2023 18:51:20 -0400 Subject: [PATCH] Add OmniOS (illumos) cacert directories Add in cacert directories for modern illumos distributions to fix no_cacerts_found error. --- lib/public_key/src/pubkey_os_cacerts.erl | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/lib/public_key/src/pubkey_os_cacerts.erl b/lib/public_key/src/pubkey_os_cacerts.erl index 93f0e48353ac..ee02e9040ea2 100644 --- a/lib/public_key/src/pubkey_os_cacerts.erl +++ b/lib/public_key/src/pubkey_os_cacerts.erl @@ -54,7 +54,7 @@ load() -> {unix, netbsd} -> load_from_file(bsd_paths()); {unix, sunos} -> - load_from_files(sunos_path()); + load_from_files(sunos_paths()); {win32, _} -> load_win32(); {unix, darwin} -> @@ -161,8 +161,10 @@ bsd_paths() -> "/etc/openssl/certs/ca-certificates.crt" ]. -sunos_path() -> - "/etc/certs/CA/". +sunos_paths() -> + ["/etc/certs/CA/", %% Oracle Solaris, some older illumos distros + "/etc/ssl/cacert.pem" %% OmniOS + ]. run_cmd(Cmd, Args) -> Opts = [binary, exit_status, stderr_to_stdout],