62,041
社区成员
发帖
与我相关
我的任务
分享
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;
}
}