Use reva's Authenticate method instead of spawning token managers

This commit is contained in:
Ishank Arora
2021-09-21 15:33:58 +02:00
parent ed6ed61b87
commit 08c51ee8c8
15 changed files with 140 additions and 93 deletions

View File

@@ -48,7 +48,7 @@ func (m signedURLAuth) ServeHTTP(w http.ResponseWriter, req *http.Request) {
return
}
user, err := m.userProvider.GetUserByClaims(req.Context(), "username", req.URL.Query().Get("OC-Credential"), true)
user, _, err := m.userProvider.GetUserByClaims(req.Context(), "username", req.URL.Query().Get("OC-Credential"), true)
if err != nil {
m.logger.Error().Err(err).Msg("Could not get user by claim")
w.WriteHeader(http.StatusInternalServerError)