【问题标题】:ASP.NET Core fails to start in debug mode when SSL is enabled启用 SSL 时,ASP.NET Core 无法在调试模式下启动
【发布时间】:2016-06-29 08:35:10
【问题描述】:

在 Visual Studio 中启动调试器 (F5) 时出现以下错误:

试图确定托管您的应用程序的 WebApplication5.exe 的进程 ID 时发生错误。发生了一个或多个错误。

我注意到当我将 applicationUrl(在 launchSettings.json 中)设置为指向 https url 时会发生这种情况:

"iisSettings": {
  "windowsAuthentication": false,
  "anonymousAuthentication": true,
  "iisExpress": {
    "applicationUrl": "https://localhost:44399/",
    "sslPort": 44399
  }

}

它是在我将 .net 代码工具从 RC2 升级到 RTM 后开始发生的。 请帮忙

【问题讨论】:

标签: asp.net-core


【解决方案1】:

我收到了类似的消息。尝试从 CTRL+F5 开始(调试 > 不调试就开始),看看是否可以启动并运行。即使我添加了自签名证书,我仍然会收到证书错误。还不知道这是怎么回事。

编辑:为了完整起见,我能够使用这些说明重新安装自签名证书:

https://blogs.technet.microsoft.com/sbs/2008/05/08/installing-a-self-signed-certificate-as-a-trusted-root-ca-in-windows-vista/

基本上,一旦站点启动并运行,进入 Internet Explorer,单击证书错误,然后从那里安装。

【讨论】:

  • 以前试过。没有帮助。由于某种原因,它不喜欢 applicationUrl 中的 https
  • 您是否也尝试过创建新项目并复制配置文件?检查 global.json 可能吗?
  • 使用 Internet Explorer 安装证书解决了这个问题。 (Ctrl+F5 还不够)
猜你喜欢
  • 2014-09-12
  • 2022-06-19
  • 2014-03-05
  • 2014-01-20
  • 1970-01-01
  • 2019-01-16
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多