假设我有一个Base64证书字符串和。
我知道如何在C#
代码
string base64CertificateString = "MIIxxxxxxxx....xxxx";
string password = "xxxxxxxx";
byte[] bytes = Convert.FromBase64String(base64CertificateString);
X509Certificate2 x509certificate = new X509Certificate2(bytes, password, X509KeyStorageFlags.DefaultKeySet);
我如何在Nodejs
中做同样的事情?