我在管理我的代码中的Azure证书时遇到了一些困难。 事实上,我试图使用Azure REST Services API(例如创建HTTP请求)来从我的Azure网站了解我的服务状态。无法在本地Azure Web角色中添加证书VM
它在本地调试中运行良好,但我的web角色接口对证书管理器有一些限制。贝娄是我做的:
// this method stores a certificate from the resources
// to the local certificates manager
private X509Certificate2 StoreCertificate(Certificates certName)
{
X509Certificate2 newCert = null;
// get certificate from resources
newCert = this.GetCertificateFromResources(certName);
// store it into the local certificate manager
if (newCert != null)
{
var store = new X509Store(
StoreName.TrustedPeople,
StoreLocation.LocalMachine
);
store.Open(OpenFlags.ReadWrite);
store.Add(newCert);
}
// reset ref and try to load it from manager
newCert = null;
newCert = this.GetCertificate(certName);
return newCert;
}
当我尝试添加证书时,Access被拒绝错误附加。
有什么想法?我可以将证书存储到Azure VM吗? 我应该使用特殊位置来存储这些吗?
关于_“提升的权限”_这点是我需要的 - 谢谢。你提到你已经看到一些关于需要提升的权限的报告 - 你有没有提及这个? – 2014-06-07 16:49:52