FiloSottile / FiloSottile/mkcert

Recognize custom Firefox profile locations

Open
#521 4 comments 3 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
59.6k
Forks
3.1k
PR merge metrics
No merged PRs in 30d

Description

## 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)](https://github.com/FiloSottile/mkcert/blob/master/truststore_darwin.go) 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.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.