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

解决方案 »

  1.   


    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;
            }
        }
      

  2.   

    多谢关注,我的意思是想通过程序来识别数字证书是指定的颁发机构所颁发的数字证书,所以想通过数字证书中的"颁发机构密钥标标识符"(如:KeyID=4d fa 3b 71 89 f7 c3 4e 15 36 e8 9a 45 0b 29 7c d1 cc 9f 50)来进行识别,但通过.net只能读出"issue"的文字信息,不知有什么方法能读出"KeyID"的信息!
      

  3.   

    我现在也只能获得[主体密钥标识符][和微缩图]的信息,其实在X509Certificate2.RawData的证书原始数据中可以找到,
    是非加密的,还有但是我不熟悉X.509的具体格式,不知道如何提取,望老手指点一下.