I am having a .NET Core 2.1
application and can not run dotnet restore
anymore.
I am getting this error :
Restoring packages for D:\Work-2\Anubis\Core\AnubisServer.Server\AnubisServer.
Server.csproj... Restore completed in 22.22 ms for D:\Work-2\Anubis\Core\COM\SharedCOM\SharedCO
M.csproj. Restore completed in 26.09 ms for D:\Work-2\Anubis\Core\AnubisServer.Shared\An
ubisServer.Shared.csproj. Restore completed in 26.07 ms for D:\Work-2\Anubis\Core\Server\Extensions\Exte
nsions.csproj. Restore completed in 26.12 ms for D:\Work-2\Anubis\Core\AnubisServer.Client\An
ubisServer.Client.csproj. C:\Program Files\dotnet\sdk\3.0.100-preview-009812\NuGet.targets(114,5): error : Unable to load the service index for source https://api.nuget.org/v3/index.json
. [D:\Work-2\Anubis\Core\AnubisServer.Server\AnubisServer.Server.csproj] C:\Program Files\dotnet\sdk\3.0.100-preview-009812\NuGet.targets(114,5): error : The SSL connection could not be established, see inner exception. [D:\Work-2\
Anubis\Core\AnubisServer.Server\AnubisServer.Server.csproj] C:\Program Files\dotnet\sdk\3.0.100-preview-009812\NuGet.targets(114,5): error : Unable to read data from the transport connection: A connection attempt faile
d because the connected party did not properly respond after a period of time, o
r established connection failed because connected host has failed to respond.. [
D:\Work-2\Anubis\Core\AnubisServer.Server\AnubisServer.Server.csproj] C:\Program Files\dotnet\sdk\3.0.100-preview-009812\NuGet.targets(114,5): error : A connection attempt failed because the connected party did not properly resp
ond after a period of time, or established connection failed because connected h
ost has failed to respond. [D:\Work-2\Anubis\Core\AnubisServer.Server\AnubisServ
er.Server.csproj]
As you can see it all resolves around api.nuget.org/v3/index.json
but i do not know what is wrong.
I have looked upon previous answers and i tried:
-deleting the Nuget folder from C:/Users:/[username]/Nuget
-looking into C:\Users\[user]\AppData\Roaming\NuGet.config
file and see if all urls are ok
Nuget.config
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageSources>
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" protocolVersion="3" />
</packageSources>
</configuration>
What is curious for me is that it worked perfectly until today.I have not made any system changes.