You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
.der enocded RSA public key in test does not appear to be a valid key #470
changed the title [-].der enocded RSA public key in test does not appear to a valid key[/-][+].der enocded RSA public key in test does not appear to be a valid key[/+]on Mar 1, 2017
Thanks to both of you for pointing this out. I'm going to close this in favor of landing #472, which will hopefully clear things up. I suspect #384 will also help people learn the right format to use. Also #378 will add support for parsing the RSAPublicKey format out of SubjectPublicKeyInfo format keys.
Activity
[-].der enocded RSA public key in test does not appear to a valid key[/-][+].der enocded RSA public key in test does not appear to be a valid key[/+]lawliet89 commentedon Mar 3, 2017
Try it with
openssl rsa -RSAPublicKey_in -in ./src/rsa/signature_rsa_example_public_key.der -inform DER -RSAPublicKey_out -outform PEMinstead.The
RSAPublicKey_inis different.Wrote the following documentation for my library after trying for an hour to figure out why my signature verification was not working:
To generate the public key from your DER-encoded private key
openssl rsa -in private_key.der \ -inform DER -RSAPublicKey_out \ -outform DER \ -out public_key.derTo convert a PEM formatted public key
openssl rsa -RSAPublicKey_in \ -in public_key.pem \ -inform PEM \ -outform DER \ -RSAPublicKey_out \ -out public_key.derbriansmith commentedon Mar 6, 2017
Thanks to both of you for pointing this out. I'm going to close this in favor of landing #472, which will hopefully clear things up. I suspect #384 will also help people learn the right format to use. Also #378 will add support for parsing the RSAPublicKey format out of SubjectPublicKeyInfo format keys.