Skip to content

Commit

Permalink
fix(server): Ignore not-JWT server tokens. Fixes argoproj#3562
Browse files Browse the repository at this point in the history
  • Loading branch information
alexec committed Jul 23, 2020
1 parent 5afbc13 commit 22132e9
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions server/auth/gatekeeper.go
Expand Up @@ -138,10 +138,7 @@ func (s gatekeeper) getClients(ctx context.Context) (versioned.Interface, kubern
claimSet, _ := jwt.ClaimSetFor(restConfig)
return wfClient, kubeClient, claimSet, nil
case Server:
claimSet, err := jwt.ClaimSetFor(s.restConfig)
if err != nil {
return nil, nil, nil, status.Errorf(codes.Unauthenticated, "failure to parse token: %v", err)
}
claimSet, _ := jwt.ClaimSetFor(s.restConfig)
return s.wfClient, s.kubeClient, claimSet, nil
case SSO:
claimSet, err := s.ssoIf.Authorize(ctx, authorization)
Expand Down

0 comments on commit 22132e9

Please sign in to comment.