mirror of
https://github.com/grafana/grafana.git
synced 2025-02-11 16:15:42 -06:00
parent
5050822b9a
commit
284ca4eab4
@ -71,7 +71,7 @@ func (s *JWT) Authenticate(ctx context.Context, r *authn.Request) (*authn.Identi
|
|||||||
ClientParams: authn.ClientParams{
|
ClientParams: authn.ClientParams{
|
||||||
SyncUser: true,
|
SyncUser: true,
|
||||||
SyncTeamMembers: true,
|
SyncTeamMembers: true,
|
||||||
AllowSignUp: false,
|
AllowSignUp: s.cfg.JWTAuthAutoSignUp,
|
||||||
EnableDisabledUsers: false,
|
EnableDisabledUsers: false,
|
||||||
}}
|
}}
|
||||||
|
|
||||||
@ -125,10 +125,6 @@ func (s *JWT) Authenticate(ctx context.Context, r *authn.Request) (*authn.Identi
|
|||||||
return nil, ErrJWTMissingClaim.Errorf("missing login and email claim in JWT")
|
return nil, ErrJWTMissingClaim.Errorf("missing login and email claim in JWT")
|
||||||
}
|
}
|
||||||
|
|
||||||
if s.cfg.JWTAuthAutoSignUp {
|
|
||||||
id.ClientParams.AllowSignUp = true
|
|
||||||
}
|
|
||||||
|
|
||||||
return id, nil
|
return id, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user