简体   繁体   中英

Intermittent SSL/TLS error using Azure SDK in Azure Website

I have an ASP.NET MVC website running .NET 4.5 in an Azure Website and I keep getting this error trying to retrieve or upload assets into Azure Blob Storage using the Azure SDK (version 4.3.0).

The request was aborted: Could not create SSL/TLS secure channel.

Microsoft.WindowsAzure.Storage.StorageException: The request was
aborted: Could not create SSL/TLS secure channel. --->
System.Net.WebException: The request was aborted: Could not create
SSL/TLS secure channel. at System.Net.HttpWebRequest.GetResponse()
at
Microsoft.WindowsAzure.Storage.Core.Executor.Executor.ExecuteSync[T] (RESTCommand`1 cmd, IRetryPolicy policy, OperationContext operationContext) ---
End of inner exception stack trace --- at
Microsoft.WindowsAzure.Storage.Core.Executor.Executor.ExecuteSync[T](RESTCommand`1
cmd, IRetryPolicy policy, OperationContext operationContext) at
Microsoft.WindowsAzure.Storage.Blob.CloudBlobClient.GetBlobReferenceFromServer(StorageUri
blobUri, AccessCondition accessCondition, BlobRequestOptions options,
OperationContext operationContext) at
Microsoft.WindowsAzure.Storage.Blob.CloudBlobClient.GetBlobReferenceFromServer(Uri
blobUri, AccessCondition accessCondition, BlobRequestOptions options,
OperationContext operationContext)

The error doesn't occur every time, but once it starts happening it happens continuously. Only when I scale the Azure website up or down to reset the site does the error stop. It will go a few hours or a few days and then it will come back again.

It seems like this started happening around the time of the Poodle vulnerability and sites shut down their support for SSL3. It seems like from the research I've done that this error could be if the Azure SDK is trying to connect to Azure Blob storage over SSL3. Since it works fine for a time, I wonder if some library in my app is setting the ServicePointManager.SecurityProtocol to SSL3, which is a global setting which Azure is then using from that point on causing the error. Any idea to determine if that is what is happening or how to find that code that is setting the fallback to SSL3?

重新启动后,删除并重新安装证书为我解决了这个问题。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM