1
votes

The below generates when executing dotnet restore command

D:\NewDotNetApp2>dotnet new xunit Content generation time: 118.1211 ms The template "xUnit Test Project" created successfully.

D:\NewDotNetApp2>dotnet restore Restoring packages for D:\NewDotNetApp2\NewDotNetApp2.csproj... C:\Program Files\dotnet\sdk\1.0.4\NuGet.targets(97,5): error : Unable to load the service index for source https:// api.nuget.org/v3/index.json.\r [D:\NewDotNetApp2\NewDotNetApp2.csproj] C:\Program Files\dotnet\sdk\1.0.4\NuGet.targets(97,5): error : Response status code does not indicate success: 40 7 (Proxy Authentication Required ( The ISA Server requires authorization to fulfill the request. Access to the Web Proxy filter is denied. )). [D:\NewDotNetApp2\NewDotNetApp2.csproj]

This just happening in XUnit Project all other projects like mvc,webapi etc are working file.

Please suggest what to do.

1
Do you maybe use a corporate NuGet proxy that only whitelists some packages? - Martin Ullrich
but other projects successfully restore using dotnet restore command then what's wrong with XUnit? - Syed Mustafa Hussain Zaidi
Any NuGet.Config file in the project or on your machine that specifies a custom NuGet feed? The ISA Server requires authorization sounds like an infrastructure problem - Martin Ullrich
No custom NuGet feed nor created NuGet.config in the project.....if I create NuGet.config file in the project what feed should I use to avoid error? - Syed Mustafa Hussain Zaidi

1 Answers

1
votes

The Problem is resolved after installing Microsoft Firewall Client for ISA Server

Thanks Matin :)