首页 文章

Windows Azure存储证书已过期

提问于
浏览
45

我们的Azure blob存储证书今天已过期 . 这不是我们提供的证书,而是Microsoft提供的证书,如下图所示 . 如何解决这个问题呢?我试过寻找解决方案,但一无所获 . 我们的应用程序无法连接到存储,因为证书已过期,我们收到错误消息,指出:无法 Build SSL / TLS安全通道的信任关系

enter image description here

4 回答

  • 26

    作为临时措施,我能够登录azure门户并将连接字符串的协议部分从https更改为http .

  • 1

    如果您可以RDP进入您的角色,还有两种可能的解决方案 .

    • 在c:\ Config目录中手动更改配置 .

    • 构建一个修补的DLL来解决问题,并通过RDP手动上传它 . 解决方法可以是硬编码连接字符串,也可以放入代码以接受过期的证书 . 例如: ServicePointManager.ServerCertificateValidationCallback = delegate { return true; };

    (帽子提示AlexNS on MSDN forums为想法#2和Jason Vallery提供证书验证回调代码)

    As noted in the comments, disabling HTTPS and/or ignoring certificate validation errors can compromise the security of your communications. So think hard before you do this, and change it back as soon as Microsoft fixes this problem.

  • 5

    我们首先通过显式使用HTTP endpoints 进行存储来避开大部分内容(我们不存储任何过于敏感的内容) .

    如果您处于类似情况并且可以使用HTTP endpoints ,则可以使用一种解决方法来升级您的角色permanently . 它涉及使用本地软件包进行Azure Powershell部署,并且即使通过两个门户网站的升级仍然失败,它们似乎也能正常工作 .

  • 0

    就像一个注释 - 如果你从https切换到http,那么传输机制不再确保数据传输正确,你可能需要检查blob的MD5 .

    StorageClient <2.0有时会通过上传来管理它,但是从下载中读取this article .

    对于StorageClient 2.0,您可能需要将BlobRequestOptions更改为UseTransactionalMD5(as detailed here

相关问题