Exemple #1
0
 /// <summary>Extension method which initializes an RSACryptoServiceProvider from a DER public key blob.</summary>
 public static void LoadPublicKeyDER(RSACryptoServiceProvider provider, byte[] DERData)
 {
     byte[] RSAData       = RSACryptoServiceProviderExtension.GetRSAFromDER(DERData);
     byte[] publicKeyBlob = RSACryptoServiceProviderExtension.GetPublicKeyBlobFromRSA(RSAData);
     provider.ImportCspBlob(publicKeyBlob);
 }