#14397 closed enhancement (duplicate)
Add https certificate to macOS keychain more easily
Reported by: | Stereo | Owned by: | team |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | Core | Version: | |
Keywords: | macosx | Cc: |
Description
It's super useful how JOSM automatically adds its certificate to the Windows keystore, and it would be great if it could do the same for macOS.
This method modified for port 8112 works for me: https://gist.github.com/WoLpH/f959c2beccdd0fae925c
The only parts that really needs a shell is sudo security add-trusted-cert -d -r trustRoot -k "/Library/Keychains/System.keychain" "/tmp/$HOST.cert"
Note that this script has a race condition. JOSM should write its certificate to an unpredictable filename, then call security add-trusted-cert on that filename before deleting it.
http://stackoverflow.com/a/40775875 describes how to sudo shell commands from java on macOS without exposing the user password.
security find-certificate -c localhost
can find the certificates installed locally. security find-certificate -c localhost -p
outputs it in pem format.
The interface in Preferences > Remote could look roughly like this:
[X] Enable HTTPS support
Your password is required to add JOSM's certificate to your browser's trusted certificates.
[Password field ] [Add certificate to browser button]
Current status: (Certificate trusted|Certificate missing)
Attachments (0)
Change History (9)
comment:1 by , 8 years ago
Keywords: | macosx added |
---|
comment:2 by , 8 years ago
Resolution: | → duplicate |
---|---|
Status: | new → closed |
comment:4 by , 8 years ago
Closed as Selfduplicate? This raises philosophical questions, but kudos to the trac programmers that this didn't mess up the database. :)
comment:6 by , 8 years ago
Resolution: | duplicate |
---|---|
Status: | closed → reopened |
Oh great. What have I done?
comment:7 by , 8 years ago
Resolution: | → duplicate |
---|---|
Status: | reopened → closed |
Closed as duplicate of #10033.
comment:9 by , 8 years ago
Well, the duplicate action is part of the advanced ticket workflow plugin, not of trac core. So you reported in wrong trac.
Closed as duplicate of #14397.