My docker container in windows is about 9 hours in the future and is preventing https from working.
I’m trying to make a SOAP call using C#. It all works perfectly on my Win10 WS, but if I put it into a docker container on the same host it fails with
mscorlib.dll An exception of type
‘System.ServiceModel.Security.MessageSecurityException’ occurred in
mscorlib.dll but was not handled in user code An unsecured or
incorrectly secured fault was received from the other party. See the
inner FaultException for the fault code and detail.
This is on a windows 10 machine (Ver 1803)
I have confirmed that both my host and the container have the same time zones (UTC+8) and if I alter my host time to try to compensate, then the host has the same error but the container doesnt seem to want to take the new time and remains about 9 hours in the future.
I found some similar issues from about a year ago, but none seem to have resolved the problem. Without a fix, I cant see how I can have this working inside a container.
I have tried it on the following images
FROM microsoft/aspnet FROM mcr.microsoft.com/dotnet/framework/aspnet:20181113-4.7.2-windowsservercore-1803 FROM microsoft/iis
Running with Docker Desktop 18.104.22.168 (37199)
I also tried using curl on windows to access a bank site (https) which also fails in the container but works fine on my workstation. The curl error is as follows
PS C:> curl https://www.anz.com.au/personal/ curl : The request was aborted: Could not create SSL/TLS secure channel. At line:1 char:1 + curl https://www.anz.com.au/personal/ + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : InvalidOperation: (System.Net.HttpWebRequest:Htt pWebRequest) [Invoke-WebRequest], WebException + FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShe ll.Commands.InvokeWebRequestCommand