PKCS#1 to PKCS#8 convertion #592
-
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
|
Try this change: Probably the whole example could be reduced to: which will work for other algorithms besides RSA too. |
Beta Was this translation helpful? Give feedback.
-
|
I’ve noticed that the issue of RSA NULL parameters and general PKCS#8/X.509 export from .NET certificates comes up frequently. To simplify this for everyone, I have submitted Pull Request #670, which formalizes the workarounds discussed here into the library itself. Key improvements in the PR: Convenience API: Added GetSubjectPublicKeyInfo and GetSubjectPublicKeyInfoDer to DotNetUtilities. This allows exporting the public key from an X509Certificate2 in a single line of code. |
Beta Was this translation helpful? Give feedback.

Try this change:
Probably the whole example could be reduced to:
which will work for other algorithms besides RSA too.