Skip to content

Instantly share code, notes, and snippets.

@MOZGIII
Last active August 19, 2024 20:03
Show Gist options
  • Save MOZGIII/05737fc07b82029c42b158db5627825d to your computer and use it in GitHub Desktop.
Save MOZGIII/05737fc07b82029c42b158db5627825d to your computer and use it in GitHub Desktop.
TLS cert gen from existing key and with SANs
openssl req -x509 -new -key server.key -sha256 -days 3650 -nodes \
-out server.crt -subj "/CN=server" \
-addext "subjectAltName=DNS:server.local,DNS:server,DNS:localhost,IP:127.0.0.1"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment