I am using Mac OS X. I have the following files
- key.rtf
- cert.rtf
These files are PEM encoded and contain the key and the certificate in text form (-----BEGIN RSA PRIVATE KEY-----
and -----END RSA PRIVATE KEY-----
).
How can I:
- decrypt the private key with the passphrase I used to encrypt it and get it back in text form?
- get both files in PEM format as text (!) back?
The PEM encoding makes problems - if the files are stored as .key, .cert or anything like this, it works properly. But I need the text.
Thanks!
It is possible with this command:
openssl rsa -in cert.pem -out server.key
(I converted the files to a cert.pem file before).