Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
GENERATE PUBLIC/PRIVATE KEY PAIR:
GENERATE PUBLIC/PRIVATE KEY PAIR:
For PHP:
openssl genrsa > drmsign.pem
openssl rsa -in drmsign.pem -pubout > drmsign.pub
Then convert to DER (required by Java):
http://codeartisan.blogspot.sg/2009/05/public-key-cryptography-in-java.html
openssl pkcs8 -topk8 -inform PEM -outform DER -in drmsign.pem -out drmsign.der -nocrypt
openssl rsa -in drmsign.pem -pubout -outform DER -out drmsign_pub.der
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.