[英]Identity Server4 Unauthorized error
I am following Scot Brad's tutorial on connecting a client to a Identity Server. 我正在关注Scot Brad的有关将客户端连接到Identity Server的教程 。
However, when I call a recourse that is secured, I get an error 401, rather than redirect to Login page. 但是,当我调用安全的资源时,会收到错误401,而不是重定向到“登录”页面。 When I look into the network tab within the browser, I can see that it calls the identity server 'connect/authorize' endpoint with the parameters. 当我在浏览器中查看“网络”选项卡时,可以看到它使用参数调用身份服务器的“连接/授权”端点。
URL 网址
https://localhost:44357/connect/authorize?client_id=TestClient&redirect_uri=https%3A%2F%2Flocalhost%3A44322%2Fsignin-oidc&response_type=id_token&scope=openid%20profile&response_mode=form_post&nonce=636153820178127063.N2QzZGVkYWEtYjVlYS00OGJlLWEwNmUtMjg3NmFiMTkxMzlmYjdjMWUyZTMtNmU4MC00YjFjLWI0NzQtNWY2OGViM2E5NTU0&state=CfDJ8MVlFDRNc9pPh04-DLkjH8nHybAKye3NJvq8XeUgNyfpXA3VWXn7UrnwgElO2M_yQ4u1xDKnnZVfkMlC4XCdlslGNf3KL1x2Wy_ZzabG0_Y_Hw9ZiBvh0D2WFojJx-rC_2iTL9RJErxBxZWwDJix_0jPpjocG4qkRBWCL5W2ZLLBM_d6fWMLx4scD2foLzWw461KedmCFw6AGPoJv8fuU5zHEbjA1kIxCoj0EF0GTHFZKshoQmczsdKxp4Kl7LDYwhBEJJ9KNnkYiamdj8ssk2Aa1bvhMGYDZx8ukunasjDzjUXAQBFrcLI94PU221Em4V8meaFkfC_mtMKGnm6tZSs
And when i copy and paste the URL into the browser, i see an error: 当我将URL复制并粘贴到浏览器中时,我看到一个错误:
SqlException: Invalid column name 'AllowPlainTextPkce'. SqlException:无效的列名称'AllowPlainTextPkce'。 Invalid column name 'ProtocolType'. 无效的列名“ ProtocolType”。
Looks like you did not run the EF migrations for that project. 您似乎没有为该项目运行EF迁移。 The DbContext is assuming that those columns exist in the database. DbContext假定这些列存在于数据库中。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.