Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

钉钉oauth2 sso登录 有没有配置案例 #2442

Open
l19891223j opened this issue Jan 17, 2025 · 0 comments
Open

钉钉oauth2 sso登录 有没有配置案例 #2442

l19891223j opened this issue Jan 17, 2025 · 0 comments

Comments

@l19891223j
Copy link

l19891223j commented Jan 17, 2025

What would you like to be added:

Why is this needed:
想实现钉钉企业账号单点登录

以下是我的配置:

Enable = true
DisplayName = '钉钉sso登录'
RedirectURL = 'https://devops-n9e.xxx.com/callback/oauth'
SsoAddr = 'https://login.dingtalk.com/oauth2/auth'
SsoLogoutAddr = 'https://login.dingtalk.com/oauth2/logout'
TokenAddr = 'https://api.dingtalk.com/v1.0/oauth2/userAccessToken'
UserInfoAddr = 'https://api.dingtalk.com/v1.0/contact/users/me'
TranTokenMethod = 'header'
ClientId = 'xxxx'
ClientSecret = 'xxxx'
CoverAttributes = true
DefaultRoles = ['Standard']
UserinfoIsArray = false
UserinfoPrefix = ''
Scopes = ['openid', 'profile']

[Attributes]
Username = 'userid'
Nickname = 'name'
Phone = 'mobile'
Email = 'email'

报错:
ilegal user:failed to exchange token: oauth2: cannot fetch token: 400 Bad Request Response: {"code":"Missingbody","requestid":"8E7B0ED6-B16F-7042-B6D8-6DF5DCC5B7E9","message":"body is mandatory for this action."}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant