Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mkcert is slow on darwin (due to nss support) #135

Closed
crawshaw opened this issue Feb 15, 2019 · 1 comment
Closed

mkcert is slow on darwin (due to nss support) #135

crawshaw opened this issue Feb 15, 2019 · 1 comment

Comments

@crawshaw
Copy link
Contributor

On a MacBook Air 2018:

$ time (./mkcert -help &> /dev/null)

real	0m1.010s
user	0m0.657s
sys	0m0.309s

This is caused by the init function in truststore_nss.go, which invokes the brew command. If I comment out the init function:

$ time (./mkcert -help &> /dev/null)

real	0m0.025s
user	0m0.013s
sys	0m0.010s
@crawshaw
Copy link
Contributor Author

When actually generating a key, there are other sources of slowness. Total generation time with nss removed is 1s. About 100ms of that is spent in generateKey.

It seems to take mkcert 200ms to reach the beginning of the makeCert method.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant