Skip to content
8 changes: 5 additions & 3 deletions pkg/kubernetes/provider_acm_hub.go
Original file line number Diff line number Diff line change
Expand Up @@ -226,9 +226,11 @@ func (p *acmHubClusterProvider) IsOpenShift(ctx context.Context) bool {
}

func (p *acmHubClusterProvider) VerifyToken(ctx context.Context, target, token, audience string) (*authenticationv1api.UserInfo, []string, error) {
// use hub cluster for token verification regardless of target
// TODO(Cali0707): update this to work off the configured auth provider for the target
return p.hubManager.VerifyToken(ctx, token, audience)
manager, err := p.managerForCluster(target)
if err != nil {
return nil, nil, fmt.Errorf("failed to get manager for cluster '%s', unable to verify token", target)
}
return manager.VerifyToken(ctx, token, audience)
Comment on lines +229 to +233
Copy link
Member

@matzew matzew Oct 30, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now verifies tokens against the correct target cluster (should)

}

func (p *acmHubClusterProvider) GetDerivedKubernetes(ctx context.Context, target string) (*Kubernetes, error) {
Expand Down