【问题标题】:How to specify a certificate in the cert store for gRPC .NET Core?如何在 gRPC .NET Core 的证书存储中指定证书?
【发布时间】:2020-09-23 20:38:42
【问题描述】:

我正在尝试在证书存储中为 gRPC .NET Core 3.1 指定一个证书。

我找到了一种通过设置路径来指定证书的方法。

https://medium.com/@mcilis/how-to-publish-net-core-grpc-server-as-a-windows-service-dd562a1e263d

    "Certificates": {
        "Default": {
            "Path": "Your_Path_To_Certificate_Pfx",
            "Password": "Pfx_File_Password"
        }
    }

但是是否可以使用 appsettings.json 在 Windows 证书存储中指定一个? 还是只能通过代码实现?

【问题讨论】:

    标签: asp.net-core grpc-dotnet


    【解决方案1】:

    当我看到堆栈跟踪时,我找到了答案。

    证书配置

    https://github.com/dotnet/aspnetcore/blob/a190fd34854542266956b1af980c19afacb95feb/src/Servers/Kestrel/Core/src/Internal/ConfigurationReader.cs

    这些是 Windows 证书存储的参数。

    • 主题
    • 商店
    • 位置
    • 允许无效

    【讨论】:

      猜你喜欢
      • 2020-04-01
      • 1970-01-01
      • 2023-02-13
      • 2020-03-11
      • 1970-01-01
      • 2011-01-01
      • 2019-10-08
      • 2011-11-09
      • 2012-04-18
      相关资源
      最近更新 更多