gpt4 book ai didi

ssl - 在 Ubuntu 上使用 Firefox 59 不受信任的自签名 *.dev 证书

转载 作者:太空宇宙 更新时间:2023-11-03 12:57:51 27 4
gpt4 key购买 nike

我在 Ubuntu 上使用 Firefox 59.0.1,在访问我的开发环境时看到以下错误,该环境位于自签名 SSL 证书之后。

Your connection is not secure

The owner of crmpicco.dev has configured their website improperly. To protect your information from being stolen, Firefox has not connected to this website.

This site uses HTTP Strict Transport Security (HSTS) to specify that Firefox may only connect to it securely. As a result, it is not possible to add an exception for this certificate.

Learn more…

Report errors like this to help Mozilla identify and block malicious sites

crmpicco.dev uses an invalid security certificate.

The certificate is not trusted because it is self-signed.

Error code: SEC_ERROR_UNKNOWN_ISSUER

我已将“crmpicco.dev”添加到 security.tls.insecure_fallback_hosts 并将 security.enterprise_roots.enabled 设置为 true,重新启动 Firefox,但这没有任何效果。

我知道 Chrome 有他们的“badidea”/“thisisnotsafe”解决方法,我知道这不是理想的但它至少有效 - 而我还没有找到 Firefox 的等效方法。

解决这个问题的方法是什么?即使我拥有的证书来自 2018 年 2 月,我是否需要生成新的自签名证书。

我已经尝试了这里的许多问题和 Mozilla 支持都没有效果。

最佳答案

顶级域*.dev 是owned by Google .对于 some time already Chrome 中有一个预配置的 HSTS 策略,这使得无法为此域使用自签名证书。 Firefox 最近也添加了此类策略,因此您现在可以得到相同的行为。

有几种方法可以解决这个问题。最好的方法是不要将任何当前公开或 future 公开的顶级域用于您的私有(private)目的。通过使用此类域,您可能会与域所有者强制执行的使用策略发生冲突,例如在 *.dev 的情况下强制执行 HSTS。此外,它甚至可能导致 security problems .而是使用您实际拥有的域或使用保留供内部和测试使用的顶级域,例如 *.test、*.invalid 或 *.example。

如果你真的想在内部使用 *.dev(同样,坏主意),你可以按照这个域的策略来做到这一点:不要使用自签名证书,而是使用由受信任的 CA 颁发的证书你的浏览器。这意味着创建您自己的 CA,将其添加为受信任的浏览器,然后由该 CA 颁发您想要的证书。但同样,使用不属于您的公共(public)域(无论是否是顶级域)都是麻烦的收据。

关于ssl - 在 Ubuntu 上使用 Firefox 59 不受信任的自签名 *.dev 证书,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49503337/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com