日期:2014-05-18  浏览次数:20464 次

如何获取数字证书中的"颁发机构密钥标标识符"
如题:如何获取数字证书中的"颁发机构密钥标标识符"

------解决方案--------------------
关注
------解决方案--------------------
C# code

using System.Security.Cryptography;
using System.Security.Cryptography.X509Certificates;

   protected void Page_Load(object sender, EventArgs e)
    {
        X509Store store = new X509Store(StoreLocation.CurrentUser);
        store.Open(OpenFlags.ReadOnly);

        X509Certificate2Collection certCollection = store.Certificates;

        foreach (X509Certificate2 c in certCollection)
        {
            RSACryptoServiceProvider privatekey = (RSACryptoServiceProvider)c.PrivateKey;
        }
    }