mkcert icon indicating copy to clipboard operation
mkcert copied to clipboard

Firefox Developer Edition doesn't recognise Mkcert issuing authority

Open aindriu80 opened this issue 3 years ago • 19 comments

Hi,

I have been using Mkcert for a while now to provide HTTPS on a local machine (Ubuntu 21.04) and Firefox (89.0 (64-bit)) it was working ok but I started using Firefox Developer Edition (90.0b3 (64-bit)) and I get the error below (Mkcert is not a recognized authority).

2021-06-07_15-20

Someone could be trying to impersonate the site and you should not continue. Websites prove their identity via certificates. Firefox Developer Edition does not trust localhost:3000 because its certificate issuer is unknown, the certificate is self-signed, or the server is not sending the correct intermediate certificates. Error code: SEC_ERROR_UNKNOWN_ISSUER

Is there some way around this? It works perfectly in regular Firefox but not in the developer edition for some reason.

aindriu80 avatar Jun 07 '21 14:06 aindriu80

Not a Linux user but have you tried installing the Root CA manually in the Firefox settings?

Instructions should be similar to here: https://ddev.readthedocs.io/en/stable/#windows-and-firefox-mkcert-install-additional-instructions

ashleyconnor avatar Jun 07 '21 20:06 ashleyconnor

I'm using Firefox v96.0.3 and getting this SEC_ERROR_UNKNOWN_ISSUER error myself. No such errors in Chrome or Safari. mkcert shows no error installing the cert in Firefox and manually installing the root CA says it's already installed. Any other people having this issue?

benjibee avatar Feb 02 '22 15:02 benjibee

Had the same issue. I'm in Fedora 36 Workstation and it worked on Firefox and Chromium but newly installed Firefox Developer Edition (102.0) doesn't recognize CA. In my case, running mkcert -install again and restarting Firefox Dev solved it.

akositey avatar Jul 22 '22 17:07 akositey

I had the same issue on macOS and Firefox Developer Edition, enabling the preference security.enterprise_roots.enabled to true solved this for me:

  1. Enter “about:config” in the address bar and continue to the list of preferences.
  2. Set the preference "security.enterprise_roots.enabled" to true.
  3. Restart Firefox.

DenisLanz avatar Jul 25 '22 11:07 DenisLanz

Having the same issue in Ubuntu 22.04.01 LTS using DDEV: it works in Chromium but not in regular Firefox 104.0.2 (the security.enterprise_roots.enabled=true solution didn't work for me). First thought was, that the Snap package of Firefox might be the problem, because Snap makes often trouble with external files and folders. But strangely the Chromium Browser comes also as Snap package, so probably that's not the troublemaker here.

Moongazer avatar Sep 16 '22 10:09 Moongazer

Having same issue as @Moongazer. Please let me know if you will fix this issue. Ubuntu 22.04.1 ddev, Firerfox 104.0.2 (64-bit)

nikolay-jobiqo avatar Sep 19 '22 06:09 nikolay-jobiqo

Same problem here since upgrading to Ubuntu 22.04. Solution:

  • Open the Firefox Preferences
  • Enter certificates into the search box on the top
  • Click View Certificates...
  • Select the tab Authorities
  • Click to Import...
  • Go to the folder where your root certificate authority was stored (~/.local/share/mkcert)
  • Select the file rootCA.pem
  • Click to Open

Gernott avatar Oct 17 '22 06:10 Gernott

@Gernott thanks a lot, works for me.

nikolay-jobiqo avatar Oct 17 '22 08:10 nikolay-jobiqo

@Gernott This manual way works for me as well, thank you!

Edit: MacOS users will find the file in ~/Library/Application Support/mkcert

Moongazer avatar Oct 17 '22 09:10 Moongazer

Hello ! Can't do "Go to the folder where your root certificate authority was stored (~/.local/share/mkcert)" because my share/mkcert is in /root/ folder and Firefox can't access it. Is it normal to have it in /root folder ?

quentinDupont avatar Oct 28 '22 12:10 quentinDupont

@quentinDupont run mkcert -install without sudo

meshuamam avatar Feb 17 '23 15:02 meshuamam

Same problem here since upgrading to Ubuntu 22.04. Solution:

  • Open the Firefox Preferences
  • Enter certificates into the search box on the top
  • Click View Certificates...
  • Select the tab Authorities
  • Click to Import...
  • Go to the folder where your root certificate authority was stored (~/.local/share/mkcert)
  • Select the file rootCA.pem
  • Click to Open

Is it possible to do this via shell script?

meshuamam avatar Feb 17 '23 15:02 meshuamam

@meshuamam

The install script scripts/install_ddev.sh does it with the regular FF, so maybe look there, how it's done.

owzim avatar Mar 01 '23 16:03 owzim

Same problem here since upgrading to Ubuntu 22.04. Solution:

* Open the Firefox Preferences

* Enter certificates into the search box on the top

* Click View Certificates...

* Select the tab Authorities

* Click to Import...

* Go to the folder where your root certificate authority was stored (~/.local/share/mkcert)

* Select the file rootCA.pem

* Click to Open

This worked for me, can it be added to the install instructions for firefox?

shdblowers avatar Mar 27 '23 12:03 shdblowers

@Gernott thanks. This worked for also, However I have to click "Edit Trust" and then check mark the "This certificate can identify websites."

sanjayojha avatar Apr 25 '23 13:04 sanjayojha

I had the same issue on macOS and Firefox Developer Edition, enabling the preference security.enterprise_roots.enabled to true solved this for me:

  1. Enter “about:config” in the address bar and continue to the list of preferences.
  2. Set the preference "security.enterprise_roots.enabled" to true.
  3. Restart Firefox.

~~For a local development environment using the specific Firefox version, I found DenisLanz's solution to be effective."~~

DenisLanz's solution is totally secure, thank! https://support.mozilla.org/en-US/kb/setting-certificate-authorities-firefox

arnofly avatar Sep 09 '23 16:09 arnofly

I just ran into this with Firefox installed via Flatpak, maybe the reason? @Gernott's tip worked perfectly, thanks!

gitressa avatar Oct 10 '23 19:10 gitressa

mkcert -install
The local CA is already installed in the system trust store! 👍
Warning: "certutil" is not available, so the CA can't be automatically installed in Firefox and/or Chrome/Chromium! ⚠️
Install "certutil" with "apt install libnss3-tools" and re-run "mkcert -install" 👈

Therefore

apt install libnss3-tools
mkcert -install

ajpgtech avatar Dec 20 '23 16:12 ajpgtech