我有以下客戶:
new Client
{
RequirePkce = false,
AllowAccessTokensViaBrowser = true,
ClientId = "client_id_mobile",
ClientSecrets =
{
new Secret("client_secret_mobile".Sha256())
},
AllowedGrantTypes = GrantTypes.ResourceOwnerPassword,
AllowedScopes =
{
IdentityServerConstants.StandardScopes.OpenId,
},
RedirectUris = new []
{
"https://www.getpostman.com/oauth2/callback"
},
}
我正在嘗試通過在郵遞員中執行以下操作來驗證用戶:

但正如你所看到的unsupported_grant_type,我已經嘗試將授權型別更改為codeI then getunauthorized_client
誰能指出我在這里做錯了什么?
uj5u.com熱心網友回復:
對于新開發,您應該只考慮使用授權代碼流或客戶端憑據流。自 OAuth2.1 起,所有其他流程均已棄用。
如果您想使用用戶名/密碼登錄并且不涉及任何用戶,請改用客戶端憑據流。
轉載請註明出處,本文鏈接:https://www.uj5u.com/qita/408723.html
標籤:
