Browse Source

fix: app.importCertificate crash on Linux (#25536)

Co-authored-by: Shelley Vohr <[email protected]>
trop[bot] 4 years ago
parent
commit
24691a4e0f
1 changed files with 1 additions and 0 deletions
  1. 1 0
      chromium_src/chrome/browser/certificate_manager_model.cc

+ 1 - 0
chromium_src/chrome/browser/certificate_manager_model.cc

@@ -36,6 +36,7 @@ net::NSSCertDatabase* GetNSSCertDatabaseForResourceContext(
     // Linux has only a single persistent slot compared to ChromeOS's separate
     // public and private slot.
     // Redirect any slot usage to this persistent slot on Linux.
+    crypto::EnsureNSSInit();
     g_nss_cert_database = new net::NSSCertDatabase(
         crypto::ScopedPK11Slot(PK11_GetInternalKeySlot()) /* public slot */,
         crypto::ScopedPK11Slot(PK11_GetInternalKeySlot()) /* private slot */);