FiloSottile/mkcert

Invalid CA in arch linux

lemonnuggets opened this issue · 5 comments

Environment

  • Operating system (including version): Linux archlinux 5.18.1-arch1-1 #1 SMP PREEMPT_DYNAMIC Mon, 30 May 2022 17:53:11 +0000 x86_64 GNU/Linux
  • mkcert version (from mkcert -version): (devel)
  • Server (where the certificate is loaded): webpack-dev-server
  • Client (e.g. browser, CLI tool, or script):
    • Brave 1.39.111 Chromium: 102.0.5005.61 (Official Build) (64-bit)
    • Google Chrome 102.0.5005.61 (Official Build) (64-bit)
    • Firefox 101.0

What you did

Ran mkcert -install and mkcert localhost as instructed to generate valid certificate.
image

Verified that certificate authority was added to all browsers.

Brave
image

Chrome
image

Firefox
image

Added the following lines to my .env file within my create-react-app project to make the dev server aware of the certificates.

HTTPS=true
SSL_CERT_FILE=.cert/localhost.pem
SSL_KEY_FILE=.cert/localhost-key.pem

What went wrong

NET::ERR_CERT_AUTHORITY_INVALID in brave and chrome
image
image

MOZILLA_PKIX_ERROR_SELF_SIGNED_CERT in firefox
image

@FiloSottile

I have the same issue, but I think I've used correct commands:

mkcert -key-file server-key.pem -cert-file server-cert.pem "home" "*.home" 

image

mkcert --install

image

And I still get not trusted certificate:
image

image

image

66RING commented

same issue and issuer starts with “mkcert”
image

image

I guess I had a similar issue. Spend few hours debugging it.

It seems the problem is with Brave Browser.
My assumption is the store/location for CA is in different location for Brave than mkcert uses, for other browsers.
Eg. mkcert doesn't support it yet.

What I did to get to this conclusion

  • install Chromium
  • check if site/cert is loaded properly. (for me it was ok)
  • check in Brave -> doesn't work
  • compare Chromium vs Brave authorities - setting -> privacy -> manage certificates -> authorities
  • For me chromium had mkcert authority, Brave didnt'
  • Add the auhtority manualy to Brave - test if it work -> yes.

Maybe it will help someone.

  • compare Chromium vs Brave authorities - setting -> privacy -> manage certificates -> authorities

My problem was fixed by clicking on the 3 dots for extra options and then trusting the cert.

Screenshot from 2024-06-30 22-30-59