为提升您的使用体验,本站正在维护,部分功能暂时无法使用。如果本站文章无法解决您的问题,您想要向社区提问的话,请到 Twitter 上的 @FirefoxSupport 或 Reddit 上的 /r/firefox 提问,我们的支持社区将会很快回复您的疑问。

搜索 | 用户支持

防范以用户支持为名的诈骗。我们绝对不会要求您拨打电话或发送短信,及提供任何个人信息。请使用“举报滥用”选项报告涉及违规的行为。

详细了解

How do I automate the import of a certificate (.cer) file within a silent install of FireFox 62.0.2?

  • 3 个回答
  • 2 人有此问题
  • 34 次查看
  • 最后回复者为 Krishna234

more options

We are migrating from firefox Version 61 to Version 62. after sucessfull installation i am seeing an error your connection is not secure. If i import the certification manually and if the launch the firefox it works as expected and i am able to launch all the websites.

I have tried to copy the files(cert9.db and key4.db) from my profile to others. It is not working for others.

But if i manually import it works for them.

Is there any way i can silently automate them to import?

Thanks

We are migrating from firefox Version 61 to Version 62. after sucessfull installation i am seeing an error your connection is not secure. If i import the certification manually and if the launch the firefox it works as expected and i am able to launch all the websites. I have tried to copy the files(cert9.db and key4.db) from my profile to others. It is not working for others. But if i manually import it works for them. Is there any way i can silently automate them to import? Thanks

所有回复 (3)

more options

Please only answer in this question as you created a duplicate.

more options

You can set this pref to true on the about:config page in cases where root certificates were added to the Windows certificate store.

  • security.enterprise_roots.enabled = true
more options

I have changed this configuration security.enterprise_roots.enabled = true

Still i am seeing the error. But one thing i have once if Preload the certificate databases to user profile it is working..

Is there any method to auto copy these Preload the certificate databases to users profile after profile creating..

I am using the below script. But still it is not copying the files.

// If cert9.db isn't there, it's a new profile if (!certDBFile.exists()) {

   var defaultProfileDir = Services.dirsvc.get("GreD", Ci.nsIFile);
   defaultProfileDir.append("defaults");
   defaultProfileDir.append("profile");
   try {
       copyDir(defaultProfileDir, profileDir);
   } catch (e) {
       Components.utils.reportError(e);
   }

}else { //if cert9.db is less than 140kb, its a new one without the

bank cert copy this one over if(certDBFile.fileSize<140000 ){ var defaultProfileDir = Services.dirsvc.get("GreD",

Ci.nsIFile); defaultProfileDir.append("defaults"); defaultProfileDir.append("profile"); try {

       copyDir(defaultProfileDir, profileDir);

} catch (e) {

       Components.utils.reportError(e);

} }

}

function copyDir(aOriginal, aDestination) {

   var enumerator = aOriginal.directoryEntries;
   while (enumerator.hasMoreElements()) {
       var file = enumerator.getNext().QueryInterface

(Components.interfaces.nsIFile);

       if (file.isDirectory()) {
           var subdir = aDestination.clone();
           subdir.append(file.leafName);
           try {
               subdir.create(Ci.nsIFile.DIRECTORY_TYPE, 

FileUtils.PERMS_DIRECTORY);

               copyDir(file, subdir);
           } catch (e) {
               Components.utils.reportError(e);
           }
       } else {
           try {
               file.copyTo(aDestination, null);
           } catch (e) {
               Components.utils.reportError(e);
           }
       }
   }

}