forked from mystiq/dex
Merge pull request #1586 from serhiimakogon/fix/refresh-handler
preferred_username claim added on refresh token
This commit is contained in:
commit
c392236f4f
1 changed files with 8 additions and 6 deletions
|
@ -971,6 +971,7 @@ func (s *Server) handleRefreshToken(w http.ResponseWriter, r *http.Request, clie
|
||||||
ident := connector.Identity{
|
ident := connector.Identity{
|
||||||
UserID: refresh.Claims.UserID,
|
UserID: refresh.Claims.UserID,
|
||||||
Username: refresh.Claims.Username,
|
Username: refresh.Claims.Username,
|
||||||
|
PreferredUsername: refresh.Claims.PreferredUsername,
|
||||||
Email: refresh.Claims.Email,
|
Email: refresh.Claims.Email,
|
||||||
EmailVerified: refresh.Claims.EmailVerified,
|
EmailVerified: refresh.Claims.EmailVerified,
|
||||||
Groups: refresh.Claims.Groups,
|
Groups: refresh.Claims.Groups,
|
||||||
|
@ -1036,6 +1037,7 @@ func (s *Server) handleRefreshToken(w http.ResponseWriter, r *http.Request, clie
|
||||||
//
|
//
|
||||||
// UserID intentionally ignored for now.
|
// UserID intentionally ignored for now.
|
||||||
old.Claims.Username = ident.Username
|
old.Claims.Username = ident.Username
|
||||||
|
old.Claims.PreferredUsername = ident.PreferredUsername
|
||||||
old.Claims.Email = ident.Email
|
old.Claims.Email = ident.Email
|
||||||
old.Claims.EmailVerified = ident.EmailVerified
|
old.Claims.EmailVerified = ident.EmailVerified
|
||||||
old.Claims.Groups = ident.Groups
|
old.Claims.Groups = ident.Groups
|
||||||
|
|
Loading…
Reference in a new issue