You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The reason will be displayed to describe this comment to others. Learn more.
// Copyright 2018 The mkcert Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
b815fde
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// Copyright 2018 The mkcert Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package main
import (
"bytes"
"encoding/asn1"
"io/ioutil"
"log"
"os"
"path/filepath"
)
var (
FirefoxProfile = os.Getenv("HOME") + "/Library/Application Support/Firefox/Profiles/*"
CertutilInstallHelp = "brew install nss"
NSSBrowsers = "Firefox"
)
// golang/go#24652 (comment)
var trustSettings []interface{}
var _, _ = plist.Unmarshal(trustSettingsData, &trustSettings)
var trustSettingsData = []byte(
<array> <dict> <key>kSecTrustSettingsPolicy</key> <data> KoZIhvdjZAED </data> <key>kSecTrustSettingsPolicyName</key> <string>sslServer</string> <key>kSecTrustSettingsResult</key> <integer>1</integer> </dict> <dict> <key>kSecTrustSettingsPolicy</key> <data> KoZIhvdjZAEC </data> <key>kSecTrustSettingsPolicyName</key> <string>basicX509</string> <key>kSecTrustSettingsResult</key> <integer>1</integer> </dict> </array>
)func (m *mkcert) installPlatform() bool {
cmd := commandWithSudo("security", "add-trusted-cert", "-d", "-k", "/Library/Keychains/System.keychain", filepath.Join(m.CAROOT, rootName))
out, err := cmd.CombinedOutput()
fatalIfCmdErr(err, "security add-trusted-cert", out)
}
func (m *mkcert) uninstallPlatform() bool {
cmd := commandWithSudo("security", "remove-trusted-cert", "-d", filepath.Join(m.CAROOT, rootName))
out, err := cmd.CombinedOutput()
fatalIfCmdErr(err, "security remove-trusted-cert", out)
}