Automated Threat Modeling

Overview of CVE-2026-140094: OpenShift TemplateInstance Group Forgery Leads to Cluster Privilege Escalation

A brief summary of CVE-2026-140094, an authorization flaw in openshift-apiserver where unvalidated TemplateInstance requester groups let a user with template creation rights escalate to cluster administrator. The post covers the root cause, attack flow, audit-log-based detection, and affected product lines.

CVE Analysis

10 min read

Gaurav Sarraf
Gaurav Sarraf

2026-11-30

Overview of CVE-2026-140094: OpenShift TemplateInstance Group Forgery Leads to Cluster Privilege Escalation

Introduction

According to Red Hat, an authenticated OpenShift user whose only notable permission is the default ability to instantiate templates can claim membership in system:cluster-admins, and a privileged controller will act on that claim. The controller then creates RBAC objects in system namespaces for that user. The documented outcome is administrative control over the whole cluster, which goes well beyond an escape from a single namespace.

The issue is tracked as CVE-2026-140094 in openshift-apiserver, with openshift-controller-manager involved in the processing path. Red Hat, the CNA, scores it CVSS 3.1 9.9 (Critical) and classifies it as Important in its own advisory. The two ratings come from different severity scales, so they do not conflict. NVD lists the entry as Awaiting Enrichment. The assigned weakness is CWE-842, Placement of User into Incorrect Group. As of December 1, 2026, the records we reviewed identify no fixed release and no confirmed exploitation in the wild.

Technical information

Root cause: requester identity accepted as input

The TemplateInstance API includes a TemplateInstanceRequester object. The API documentation describes it as the identity of the agent requesting template instantiation:

  • username identifies the user among active users
  • uid identifies the user across time
  • groups lists the user's group memberships
  • extra holds additional identity information

These are identity attributes, and the server should treat them as security relevant. Red Hat Bugzilla 2587603 describes the gap: openshift-apiserver validates spec.requester.username but does not authorize the supplied groups, uid or extra fields. A request can therefore carry the caller's real username and still pass validation while asserting group memberships the caller does not have.

Authentication alone does not prevent this. The caller is a real, authenticated user. What fails is the check that the identity claims inside the request body match that authenticated user.

Attack flow

Based on the Bugzilla account and the Red Hat advisory, the escalation proceeds as follows:

  1. The attacker holds valid credentials and API access with permission to create TemplateInstances. Red Hat states that standard users have this permission by default, including through the self-provisioner role.
  2. The attacker submits a TemplateInstance in which spec.requester.username is set to their own username and spec.requester.groups includes system:cluster-admins.
  3. The API server checks only the username and accepts the request.
  4. The template-instance-controller builds a user identity from the forged groups and creates the template's objects with its own privileged service account.
  5. Template parameters point those objects at a system namespace such as openshift-kube-apiserver. The TemplateInstance API reference notes that when a template object's namespace contains a parameter reference, the substituted value is used.
  6. The usual payload is a RoleBinding that grants the attacker administrative access in that namespace. Bugzilla describes this as a path to full cluster administrator privileges, and Red Hat states the escalation can completely circumvent RBAC across all namespaces.

The documented exploitation uses forged groups. Bugzilla says uid and extra are also not authorized, but the records do not describe a separate exploitation method for those fields.

Severity and classification

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H

The changed scope (S:C) fits the mechanism. A low-privileged requester causes a separate, privileged component to act with authority beyond the requester's own. MITRE's description of CWE-842 says incorrect placement in a more privileged group can permit unexpected resource access or actions, which is the group forgery described here.

Exploitation status

The sources we reviewed identify no exploitation in the wild, no named threat actor, and no public exploit code. Rapid7 reports the CVE as not in the CISA KEV catalog. That is a catalog status, and it does not prove that exploitation has never happened. Exploitation also requires valid credentials, and the records do not describe how an attacker would obtain them.

Detection methods

No public signature exists for this CVE. None of the sources we checked published a YARA, Sigma, Snort/Suricata or Nuclei rule, and OffSeq's tracker indexes no public Nuclei template. Network IDS is of little use here. The attack is a normal authenticated, TLS-encrypted call to the OpenShift API that differs only in the contents of one field. Detection depends on API server audit logs and on knowing what a forged request looks like.

The bug leaves two kinds of evidence:

  1. The forged request itself: a TemplateInstance create or update whose requester groups do not match the caller's authenticated identity.
  2. The side effects: privileged objects, usually RoleBindings, that the controller creates in namespaces the requester should never touch.

Step 1: Record request bodies in audit logs

This is the most common gap. OpenShift's Default audit profile records only metadata for read and write requests, so the forged groups array in the request body is never written to the log. Red Hat's audit policy documentation says WriteRequestBodies logs the body of every write request (create, update, patch, delete, deletecollection), and AllRequestBodies also logs reads. You set the profile on the cluster APIServer resource. Example from Red Hat's documentation:

apiVersion: config.openshift.io/v1 kind: APIServer metadata: ... spec: audit: profile: WriteRequestBodies

If logging every body costs too much, spec.audit.customRules can apply a body-logging profile to specific groups only. For example, you could apply it to system:authenticated, the group that regular self-provisioning users belong to. The documentation has two caveats:

  • Secrets are logged only at metadata level. A TemplateInstance can take its parameters from a Secret through spec.secret, so the parameter values that choose the target namespace may not appear in the log. The forged spec.requester.groups is part of the TemplateInstance body itself, so it will be logged.
  • Coverage starts after the change. Changing the profile triggers a new kube apiserver revision. Activity from before the rollout has no body data.

Step 2: Find TemplateInstance requests with forged group claims

TemplateInstances are created with POST to /apis/template.openshift.io/v1/namespaces/{namespace}/templateinstances and can be modified with PUT or PATCH on /templateinstances/{name}. For each such audit event, compare:

  • the identity the API server actually authenticated (the event's user and group information), and
  • the identity in the request body under spec.requester: username, groups, uid and extra.

In a legitimate request the two match. Flag events where the body's groups contains a privileged group, especially system:cluster-admins, that the authenticated user does not belong to. Also flag any mismatch in uid or extra, since Bugzilla says those fields are not validated either. Write-ups from Das Geld and Kripta give similar advice: alert on TemplateInstance requests that list admin groups the requester does not actually hold, and watch for unexpected controller behaviour.

Expect one false positive. A real cluster administrator who instantiates a template legitimately carries those groups. That is why the check compares the claim with the authenticated identity instead of matching the group name alone.

Step 3: Check what the controller created

Without request bodies, check the outcome instead. Because the controller creates objects with its own service account, look for:

  • RoleBinding, ClusterRole or ClusterRoleBinding create events in system namespaces with the openshift- prefix, especially openshift-kube-apiserver, made by the template instance controller's service account rather than by an operator or a human administrator
  • those events occurring shortly after an ordinary user created a TemplateInstance
  • new bindings whose subject is that same user

You can also inspect the cluster's current state, which helps when logs have already rotated. The TemplateInstance API reference says status.objects[] lists references to every object an instance created. Review existing TemplateInstances and flag any where:

  • status.objects points to RoleBindings or other RBAC objects, or to namespaces other than the instance's own
  • the stored spec.requester.groups includes privileged groups the named user does not actually have

Kripta also recommends checking for new privileged role bindings and for accounts with suspicious group memberships.

Step 4: Watch for post-escalation activity

After a successful escalation, the low-privileged user starts acting where they previously could not. Signs include:

  • reading Secrets or changing workloads in system namespaces
  • creating cluster-wide RBAC objects

A useful alert fires the first time an account whose only role is self-provisioner makes successful write calls in a system namespace with the openshift- prefix.

Exposure detection

Rapid7 has a vulnerability database entry for the CVE, so version-based scanners can flag exposed clusters. Red Hat backports fixes, so scanners that rely on version strings alone may report wrong results. Red Hat recommends scanners from its certified program. Exposure also depends on who can create TemplateInstances. Listing the holders of the self-provisioner role, which standard users receive by default, shows who could exploit the bug.

Affected systems and versions

  • Products: Red Hat OpenShift Container Platform 4 and OpenShift Container Platform 5. The CVE record marks all versions affected under both product entries, so no minor release should be assumed out of scope.
  • Affected container images: openshift-apiserver and cluster-openshift-apiserver-operator.
  • Fixed versions: none identified. The Red Hat advisory has no populated resolution entries, and Rapid7 and Cloudflare also do not list a fixed version.
  • Vulnerable configuration: any cluster where a user can create TemplateInstances. By default this includes standard users through the self-provisioner cluster role bound to system:authenticated:oauth.
  • Managed offerings: on ROSA and Azure Red Hat OpenShift, the provider manages the platform, while customers schedule upgrades and configure OpenShift RBAC. The responsibility documents do not establish CVE-specific impact or a fix for these services.

Red Hat documents a general procedure that narrows the default population of potential attackers: remove the self-provisioner cluster role from system:authenticated:oauth, then set rbac.authorization.kubernetes.io/autoupdate to false on that binding. A Red Hat support article warns that without the persistence setting, the restriction can be rolled back automatically. Red Hat does not present this procedure as a fix for CVE-2026-140094. It concerns project provisioning and does not show that every TemplateInstance creation path is blocked. Red Hat's lifecycle guidance says such mitigations reduce exposure but do not replace remediation, so confirm the actual fix for your environment with Red Hat Product Security.

Vendor security history

Red Hat's 2025 Product Security Risk Report lists the following OpenShift advisory counts, using Red Hat's own severity scale:

  • Critical: 0
  • Important: 259
  • Moderate and Low combined: 52

These are advisory counts, not unique vulnerability totals. Across all products, Red Hat reports average 2025 times from public disclosure to first fix of 12 days for Critical and 24 days for Important vulnerabilities. Red Hat notes that only 3 Critical vulnerabilities affected its products that year, so the Critical average rests on a very small sample. These historical figures are not a remediation commitment for this CVE.

On October 2, 2025, Red Hat disclosed unauthorized access to a GitLab instance used by its Consulting team. Red Hat stated that it had no reason to believe other products or its software supply chain were affected, and GitLab said the instance was a single Community Edition deployment operated by Red Hat. Neither account connects that incident to CVE-2026-140094.

References

Detect & fix
what others miss

Works with
  • GitHub
  • GitLab
  • Bitbucket
  • Azure DevOps Services
  • Gerrit
  • CVS
  • Jira
  • Linear
  • Slack
  • Security Compass
Explore integrations
Security magnifying glass visualization