From e33ee9aecc35d063eca41634fcc60b058b5ef1f1 Mon Sep 17 00:00:00 2001 From: Gianmaria Del Monte Date: Tue, 13 Feb 2024 13:36:17 +0100 Subject: [PATCH] fixes in auth provider --- internal/grpc/services/gateway/authprovider.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/internal/grpc/services/gateway/authprovider.go b/internal/grpc/services/gateway/authprovider.go index da485f93c6..5815c48370 100644 --- a/internal/grpc/services/gateway/authprovider.go +++ b/internal/grpc/services/gateway/authprovider.go @@ -92,7 +92,7 @@ func (s *svc) Authenticate(ctx context.Context, req *gateway.AuthenticateRequest }, nil } - u := *res.User + u := res.User if sharedconf.SkipUserGroupsInToken() { u.Groups = []string{} } @@ -102,7 +102,7 @@ func (s *svc) Authenticate(ctx context.Context, req *gateway.AuthenticateRequest // the resources referenced by these. Since the current scope can do that, // mint a temporary token based on that and expand the scope. Then set the // token obtained from the updated scope in the context. - token, err := s.tokenmgr.MintToken(ctx, &u, res.TokenScope) + token, err := s.tokenmgr.MintToken(ctx, u, res.TokenScope) if err != nil { err = errors.Wrap(err, "authsvc: error in MintToken") res := &gateway.AuthenticateResponse{ @@ -127,7 +127,7 @@ func (s *svc) Authenticate(ctx context.Context, req *gateway.AuthenticateRequest */ scope := res.TokenScope - token, err = s.tokenmgr.MintToken(ctx, &u, scope) + token, err = s.tokenmgr.MintToken(ctx, u, scope) if err != nil { err = errors.Wrap(err, "authsvc: error in MintToken") res := &gateway.AuthenticateResponse{