无法从 Keycloak 获取 oauth 令牌 [英] unable to get oauth token from Keycloak

查看:22
本文介绍了无法从 Keycloak 获取 oauth 令牌的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个从 Keycloak 获取身份验证的应用程序.

我的访问类型是公开的,所以我没有任何客户端密码.

我已将Direct Access Grants Enabled"设置为ON

参考以下:

我从邮递员那里收到如下错误:

<代码>{错误":invalid_grant","error_description": "无效的用户凭证"}

注意:我的凭据是正确的,因为我使用相同的方式登录 keycloak

我还检查了密钥,根据以下参考,它们似乎是正确的:

如果我遗漏了什么或者您需要更多详细信息,请告诉我.

任何解决方法将不胜感激!!!!

解决方案

"Invalid user credentials" 的错误信息是可靠的.也就是说,您指定了错误的用户名或密码.
检查用户是否确实存在于您使用 URL 寻址的领域中.特别是如果它不是通常用于登录 keycloak 管理控制台的 master 领域.

I have an application which is getting Auth from Keycloak.

My Access Type is public so I do not have any client secret.

I have given access to "Direct Access Grants Enabled" as ON

Refer below:

I am getting error from postman as below:

{
    "error": "invalid_grant",
    "error_description": "Invalid user credentials"
}

Note : My credentials is right as I am using same to login on keycloak

I have also check the key and they seems correct as per below reference:

https://gist.github.com/rac021/623e4f4c87069acd0c38d952568f8a3d

while I have setup as per my understanding.

References:

Please let me know if I missing anything or you need any more details.

Any workaround will be appreciated !!!!

解决方案

The error message "Invalid user credentials" is reliable. That is, you either specified a wrong username or password.
Check that the user really exists in the realm you are addressing with the URL. Particularly if it is not the master realm which usually will be used to login to keycloak admin console.

这篇关于无法从 Keycloak 获取 oauth 令牌的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆