我正在尝试运行QuickStart2_ResourceOwnerPasswords示例。我可以毫无问题地查看http://localhost:5000/.well-known/openid-configuration
。但是,当我从控制台运行Client.dll
时,出现以下错误:
Unhandled Exception: System.Net.Http.HttpRequestException: An error occurred while sending the request. ---> System.Net.Http.WinHttpException: A connection with the server could not be established
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Threading.Tasks.RendezvousAwaitable`1.GetResult()
at System.Net.Http.WinHttpHandler.<StartRequest>d__105.MoveNext()
感谢您的帮助!
注意:我正在运行QuickStartIdentityServer
作为启动项目(这将在后台运行Identity Server实施,并在命令窗口中显示日志)。我目前正在使用以下命令从单独的窗口运行Client.dll
:
dotnet Client.dll
不确定这是否是正确的测试方法...