mkcert
mkcert copied to clipboard
Recognize custom Firefox profile locations
Environment
- Operating system (including version): macOS Ventura 13.3.1
- mkcert version (from
mkcert -version
): v1.4.4 - Server (where the certificate is loaded): n/a
- Client (e.g. browser, CLI tool, or script): n/a
What you did
Ran mkcert -install
What went wrong
The above command was partially successful but returned an error regarding Firefox:
The local CA is already installed in the system trust store! 👍
ERROR: no Firefox security databases found
I believe this is due to how this script (line 19) assumes Firefox profiles are always located at ~/Library/Application Support/Firefox/Profiles
. However, Firefox supports custom profile locations. On my machine, the profiles are located elsewhere. Instead of assuming the above path, the script should check the file ~/Library/Application Support/Firefox/Profiles/profiles.ini
, which has the following pertinent sections:
[Profile1]
Name=Work
IsRelative=0
Path=/Users/philna/firefox_profiles/phil_work
[Profile0]
Name=Personal
IsRelative=0
Path=/Users/philna/firefox_profiles/personal
I would normally submit a pull request, but I have never used go
before so I am not sure it would be very elegant. I can attempt if desired.
+1 in linux environments, firefox-esr
uses ~/.mozilla/firefox-esr/
and currently mkcert checks ~/.mozilla/firefox/
FYI https://github.com/FiloSottile/mkcert/pull/566
in general it would be good to allow the developers to override data. being able to manually provide things like profile dir and name of the CA would really help.