CVE-2026-42876

Description

A flaw was found in External Secrets Operator. A user with permissions to create ExternalSecret resources can trick the operator into creating a Kubernetes Secret that automatically contains a long-lived token for a specified service account. This allows the user to impersonate any service account within the same namespace, bypassing direct permissions for token or secret creation. This vulnerability leads to privilege escalation.

Statement

Red Hat rates this as MODERATE severity (CVSS 4.9). The External Secrets Operator vulnerability allows users with permission to create ExternalSecret resources to generate service account tokens within their namespace. Exploitation requires specific preconditions: the target namespace must contain misconfigured Service Accounts, and the attacker must already have permissions at nearly the same level as the escalation provides. Impact is limited to the namespace boundary. This rating aligns with upstream GHSA-fq7h-9x26-6j22.

Mitigation

Update to External Secrets Operator version 2.4.1 or later. Workarounds include: (1) Add admission control logic to prevent ExternalSecret Templates targeting undesired secret Types; (2) Remove Service Account Token generation via kube-controller-manager flags; (3) Restrict User RBAC on production clusters and sensitive namespaces to limit who can create ExternalSecret resources.

Understanding the Weakness (CWE)

Access Control

Technical Impact: Gain Privileges or Assume Identity

A user can access restricted functionality and/or sensitive information that may include administrative functionality and user accounts.

Frequently Asked Questions

Want to get errata notifications? Sign up here.