I'm trying to create X509Certificate2 with private_key
string using the following code:
byte[] key = Convert.FromBase64String(private_key);
X509Certificate2 certificate = new X509Certificate2(key);
When the last line executes the following exception is thrown:
System.Security.Cryptography.CryptographicException Cannot find the requested object
Does anybody know how to resolve this?