Last active
November 6, 2023 10:24
-
-
Save lawrence-laz/30ee21dc8f886364a990028eb1b936d8 to your computer and use it in GitHub Desktop.
Generate public/private keys and self signed pfx using opensll
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
# If .pem | |
openssl genrsa -out private-key.pem 3072 | |
openssl rsa -in private-key.pem -pubout -out public-key.pem | |
# If .pfx | |
openssl genrsa -out private.key 1024 | |
openssl req -new -x509 -key private.key -out publickey.cer -days 365 | |
winpty openssl pkcs12 -export -out public-private-key.pfx -inkey private.key -in publickey.cer | |
# For signing .dll | |
signtool.exe sign /tr http://timestamp.digicert.com /fd sha256 /td sha256 /sm /f "public-private-key.pfx" /p verygoodpassword /d "Descriptions of the software" YourCompany.*.dll |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment