0

我可以通过以下语句使用 c# 将 .p12 证书导入 Windows 个人商店:

X509Certificate2 cert2 = new X509Certificate2("certificate.p12" ,"p@ssword");
X509Store store2 = new X509Store(StoreName.My, StoreLocation.CurrentUser);
store2.Open(OpenFlags.MaxAllowed);
store2.Add(cert2);
store2.Close();

我需要用 JAVA 重写我的代码。如何将这些代码移植到Java?谢谢

4

0 回答 0