# CVE-2023-34091: Kyverno resource with a deletionTimestamp may allow policy circumvention

> Attackers can bypass Kyverno policies by using finalizers to set a deletionTimestamp, allowing unauthorized resource modifications in Kubernetes clusters.

- **Severity:** Medium 6.5 (`CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N`)
- **Exploited in the wild:** Not known
- **Login needed:** Any signed-in user
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 1 Jun 2023
- **Updated:** 8 Jan 2025
- **Also known as:** CLEANSTART-2025-XQ01253, CLEANSTART-2026-FU09912, GHSA-hq4m-4948-64cc, GO-2023-1819

## What is CVE-2023-34091?

CVE-2023-34091 is a medium-severity missing authorization vulnerability in kyverno, published on 1 Jun 2023. Any signed-in user can exploit it over the network, with no action from the victim.

### Official description

Kyverno is a policy engine designed for Kubernetes. In versions of Kyverno prior to 1.10.0, resources which have the `deletionTimestamp` field defined can bypass validate, generate, or mutate-existing policies, even in cases where the `validationFailureAction` field is set to `Enforce`. This situation occurs as resources pending deletion were being consciously exempted by Kyverno, as a way to reduce processing load as policies are typically not applied to objects which are being deleted. However, this could potentially result in allowing a malicious user to leverage the Kubernetes finalizers feature by setting a finalizer which causes the Kubernetes API server to set the `deletionTimestamp` and then not completing the delete operation as a way to explicitly to bypass a Kyverno policy. Note that this is not applicable to Kubernetes Pods but, as an example, a Kubernetes Service resource can be manipulated using an indefinite finalizer to bypass policies. This is resolved in Kyverno 1.10.0. There is no known workaround.

Weakness: CWE-285 (Improper Authorization)

## Which versions are affected by CVE-2023-34091?

3 open source packages ship an affected version, including github.com/kyverno/kyverno. It affects 1 product.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `github.com/kyverno/kyverno` | Go | All versions | 1.10.0 |
| `github.com/kyverno/kyverno` | Go | All versions | 1.10.0 |
| `github.com/kyverno/kyverno` | Go | All versions | 1.10.0 |

Products: Nirmata Kyverno.

## How do I fix CVE-2023-34091?

Upgrade github.com/kyverno/kyverno to 1.10.0 or later.

## Is CVE-2023-34091 being exploited?

There is no known exploitation of CVE-2023-34091 in the wild and no public exploit code.

## Other vulnerabilities in kyverno

- [CVE-2024-48921](https://insights.sbomify.com/CVE-2024-48921/): Kyverno's PolicyException objects can be created in any namespace by default (high 8.7)
- [CVE-2023-42813](https://insights.sbomify.com/CVE-2023-42813/): Denial of service from malicious manifest in kyverno (medium 6.1)
- [CVE-2023-42816](https://insights.sbomify.com/CVE-2023-42816/): Denial of service from malicious signature in kyverno (medium 6.1)
- [CVE-2023-33191](https://insights.sbomify.com/CVE-2023-33191/): kyverno seccomp control can be circumvented (medium 4.6)
- [CVE-2023-42814](https://insights.sbomify.com/CVE-2023-42814/): Denial of service from malicious image manifest in kyverno (low 3.1)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2023-34091 and fix it if it is affected.

What it is: CVE-2023-34091 is a medium-severity missing authorization vulnerability in kyverno, published on 1 Jun 2023. Any signed-in user can exploit it over the network, with no action from the victim.
Exploitation: There is no known exploitation of CVE-2023-34091 in the wild and no public exploit code.

Affected packages and fixed versions:
- github.com/kyverno/kyverno (Go): affected all versions; fixed in 1.10.0
- github.com/kyverno/kyverno (Go): affected all versions; fixed in 1.10.0
- github.com/kyverno/kyverno (Go): affected all versions; fixed in 1.10.0

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2023-34091/ (Markdown: https://insights.sbomify.com/CVE-2023-34091/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2023-34091
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2023-34091
- OSV: https://osv.dev/vulnerability/CVE-2023-34091

---
From sbomify Insights: https://insights.sbomify.com/CVE-2023-34091/
Summaries are generated and may contain mistakes; the official description above is the record.
