3
0

Remap state param on def. client authorization

This commit is contained in:
Denis Arh
2021-04-13 09:57:49 +02:00
parent 3f4f7974c1
commit 315596c603

View File

@@ -234,6 +234,10 @@ func (h AuthHandlers) oauth2authorizeDefaultClient(req *request.AuthReq) (err er
params.Set("scope", scope[0])
}
if state, has := req.Request.Form["state"]; has && len(state) > 0 {
params.Set("state", state[0])
}
req.RedirectTo = GetLinks().OAuth2Authorize + "?" + params.Encode()
return
}