feat(server): allow using client_id & secret from basic auth header in token endpoint
This commit is contained in:
parent
f9d2130c65
commit
67be8ae285
|
@ -64,6 +64,12 @@ func TokenHandler() gin.HandlerFunc {
|
|||
})
|
||||
}
|
||||
|
||||
// check if clientID & clientSecret are present as part of
|
||||
// authorization header with basic auth
|
||||
if clientID == "" && clientSecret == "" && codeVerifier == "" {
|
||||
clientID, clientSecret, _ = gc.Request.BasicAuth()
|
||||
}
|
||||
|
||||
if clientID == "" {
|
||||
log.Debug("Client ID is empty")
|
||||
gc.JSON(http.StatusBadRequest, gin.H{
|
||||
|
|
Loading…
Reference in New Issue
Block a user