https://github.com/valicm/testssl
testssl generate self signed certificates for local development purposes.
https://github.com/valicm/testssl
certificate-authority certificates golang https local-development pem pem-key self-signed-certificate ssl-certificates testssl
Last synced: 4 months ago
JSON representation
testssl generate self signed certificates for local development purposes.
- Host: GitHub
- URL: https://github.com/valicm/testssl
- Owner: valicm
- License: mit
- Created: 2020-05-24T11:08:41.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2020-10-02T19:01:15.000Z (over 5 years ago)
- Last Synced: 2025-02-05T20:10:46.750Z (about 1 year ago)
- Topics: certificate-authority, certificates, golang, https, local-development, pem, pem-key, self-signed-certificate, ssl-certificates, testssl
- Language: Go
- Homepage: http://www.vallic.com
- Size: 26.4 KB
- Stars: 5
- Watchers: 1
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# testssl
testssl generate self signed certificates for local development purposes.
# Features
- generates wildcard x509 certificates which covers *.domain.tld and domain.tld.
- outputs root authority and domain/server CA
- 10 years validity
- fallback to use `.test` as TLD if you don't input any specific TLD (https://tools.ietf.org/html/rfc6761)
# Usage
- `testssl --domain=example` - generates CA for example.test in ssl subfolder
- `testssl --domain=mylocal.loc --dir=site` - generates CA for mylocal.loc in folder site
- `testssl --domain=mydoman.test --dir=` - does not output any files
- `ssl.GenerateCert("mydomain_name", "")` - if you use from other package but don't want to generate files
# How to use root CA
- import root CA in your browser
- Firefox -> open in browser tab about:preferences#privacy, click View Certificates and click Import -> select rootCA.pem
- Chrome -> open in browser tab chrome://settings/certificates?search=authorities and click Import -> select rootCA.pem
or
- MacOS - import PEM trough keychain on MacOS and mark as trusted
- Ubuntu - as root CA on Ubuntu (you need to convert PEM to CRT).
`openssl x509 -in rootCA.pem -inform PEM -out rootCA.crt`