Skip to content

Instantly share code, notes, and snippets.

@rquackenbush
Created July 24, 2023 18:34
Show Gist options
  • Save rquackenbush/53ff432567699b21c86f3360fb4ec7f0 to your computer and use it in GitHub Desktop.
Save rquackenbush/53ff432567699b21c86f3360fb4ec7f0 to your computer and use it in GitHub Desktop.
Generate PFX Cert
# Create a new key / certificate signing request
openssl req -new -newkey rsa:4096 -nodes -keyout snakeoil.key -out snakeoil.csr
# Set CN (common name) to "localhost"
openssl x509 -req -sha256 -days 365 -in snakeoil.csr -signkey snakeoil.key -out snakeoil.pem
# Export the pfx
openssl pkcs12 -export -in snakeoil.pem -inkey snakeoil.key -out snakeoil.pfx
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment