Topic: Decode RSA key from DER format
Hi All,
I have got a RSA private key in PKCS#8 DER format as output from Java (privateKey.getEncoded()), and would like to convert the DER binary into a RsaKey with the method:
RsaPrivateKeyDecode(keyDer, &idx, privateKey, sizeKeyDer);
It failed in GetInt(), since (b != ASN_INTEGER). Instead of (b = 2), in my case (b = 48, or b = 0x30). I have attached the key.
Decoding a private key in DER format generated with openSSL was successful. Could you please tell me, which format wolfSSL embedded SSL supports for the DER - RsaKey conversion?
Thanks,
Yun