Ubuntu18 firefox将信任添加到现有证书中

问题描述 投票:0回答:1

我正在使用ubuntu18桌面,并且我添加了我需要使用Firefox 73.0的证书:

/usr/share/ca-certificates/mozilla

并且也将其添加到:

/etc/ca-certificates.conf

在文件末尾,如:

mozilla/caname.crt

并运行:

update-ca-certificate

现在,我可以通过浏览器看到证书在firefox证书列表中,但是没有标记任何信任框,因此它不起作用。

是否有从cli强制在此证书上使用信任标志的方法,也许使用certutil?

[我知道有很多方法可以使用cli命令将证书输入到firefox,但没有一种方法对我有用,现在我可以使用上述命令添加证书,但是我需要添加信任。

firefox certificate ubuntu-18.04 mozilla certutil
1个回答
0
投票

找到了此解决方案,以在ubuntu上向Firefox添加证书:

https://github.com/mozilla/policy-templates/#proxy

仅需将此文件添加到:

/usr/lib/firefox/distribution/

touch policies.json

在policy.json中添加:

{
"policies": {
"Certificates": {
    "ImportEnterpriseRoots": true,
    "Install" [
               "somecert1.crt",
               "usr/local/share/ca-certificates/somecert1.crt"
               ]
         }
    }
}

安装部分首先是证书的名称,然后是路径。并重新启动Firefox。如果某件东西不起作用,请尝试重置Firefox,就好像您已经设置了某件东西一样,然后再将其卡住。

此方法在没有certutil的情况下效果很好

© www.soinside.com 2019 - 2024. All rights reserved.