【问题标题】:IdentityServer4 endpoint skip port address attached to the URL附加到 URL 的 IdentityServer4 端点跳过端口地址
【发布时间】:2021-01-28 20:16:07
【问题描述】:

Identityserver4 端点未使用 .well-known/openid-configuration URL http://example.org:7000/.well-known/openid-configuration 的端口地址

"issuer": "http://example.org:7000",
"jwks_uri": "http://example.org/.well-known/openid-configuration/jwks",
"authorization_endpoint": "http://example.org/connect/authorize",
"token_endpoint": "http://example.org/connect/token",
"userinfo_endpoint": "http://example.org/connect/userinfo",
"end_session_endpoint": "http://example.org/connect/endsession",
"check_session_iframe": "http://example.org/connect/checksession",
"revocation_endpoint": "http://example.org/connect/revocation",
"introspection_endpoint": "http://example.org/connect/introspect",
"device_authorization_endpoint": "http://example.org/connect/deviceauthorization"

如何设置端点以附加端口地址,如下所示

"issuer": "http://example.org:7000",
"jwks_uri": "http://example.org:7000/.well-known/openid-configuration/jwks",
"authorization_endpoint": "http://example.org:7000/connect/authorize",
"token_endpoint": "http://example.org:7000/connect/token",
"userinfo_endpoint": "http://example.org:7000/connect/userinfo",
"end_session_endpoint": "http://example.org:7000/connect/endsession",
"check_session_iframe": "http://example.org:7000/connect/checksession",
"revocation_endpoint": "http://example.org:7000/connect/rev`enter code here`ocation"
"introspection_endpoint": "http://example.org:7000/connect/introspect",
"device_authorization_endpoint": "http://example.org:7000/connect/deviceauthorization"

【问题讨论】:

  • 我刚刚打开了 Quickstart 项目,您所要求的似乎是默认值。我的项目在 localhost:5001 运行,端口 5001 是我的发现端点输出中每个 URI 的一部分,以 localhost:5001 开头。也许检查 ConfigureServices 中 services.AddIdentityServer 语句的选项?另外-我猜您进行了搜索和替换。在您的“我想要的”示例中,颁发者 URI 重复了 :7000。
  • 它在本地主机上工作正常,但如果我使用 www.xxx.com:7000 部署到远程服务器。所有端点都没有端口地址。 :7000 的发行人在尝试撰写问题时出错。

标签: c# identityserver4


【解决方案1】:

我通过确保域没有端口地址而是端口 80 来解析域。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2020-09-29
    • 1970-01-01
    • 1970-01-01
    • 2015-09-15
    • 1970-01-01
    • 1970-01-01
    • 2011-09-30
    相关资源
    最近更新 更多