CVE-2023-34091: Github.com/kyverno/kyverno Remote Code Execution Vulnerability
MODERATECVE-2023-34091 is a MODERATE (CVSS 6.5) remote code execution vulnerability (CWE-285: Improper Authorization) affecting Github.com/kyverno/kyverno libraries in the Go ecosystem. The issue involves kyverno resource with a deletiontimestamp may allow policy circumvention. Remediation is available by upgrading affected packages to version 1.10.0.
CVE-2023-34091 at a Glance
Security Impact
CVSS: 6.5
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N).
How to Fix CVE-2023-34091
To remediate this vulnerability, upgrade all affected Github.com/kyverno/kyverno dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade github.com/kyverno/kyverno to 1.10.0
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for github.com/kyverno/kyverno
How to Check if You Are Affected
To determine whether your application is affected by CVE-2023-34091, inspect your project dependencies for Github.com/kyverno/kyverno:
inspect dependencies for github.com/kyverno/kyverno
Analyze the terminal output to locate any version of Github.com/kyverno/kyverno in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.10.0), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-285: Improper Authorization, where the product does not perform or incorrectly performs an authorization check when an actor attempts to access a resource or perform an action. In Github.com/kyverno/kyverno, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2023-34091 Affected Github.com/kyverno/kyverno Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
github.com/kyverno/kyverno
|
Go |
< 1.10.0
|
1.10.0
|
References
Frequently Asked Questions
What is CVE-2023-34091?
Which Github.com/kyverno/kyverno versions are affected?
What version fixes CVE-2023-34091?
Is github.com/kyverno/kyverno affected?
What is the CVSS score of CVE-2023-34091?
What CWE is associated with CVE-2023-34091?
How can I check Go dependencies for CVE-2023-34091?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-hq4m-4948-64cc",
"modified" : "2023-06-05T17:10:13Z",
"published" : "2023-06-05T17:10:13Z",
"aliases" : [ "CVE-2023-34091" ],
"summary" : "Kyverno resource with a deletionTimestamp may allow policy circumvention",
"details" : "### Impact\n\nIn 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`. \n\nThis 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. \n\nHowever, this could potentially result in allowing a malicious user to leverage the [Kubernetes finalizers feature](https://kubernetes.io/docs/concepts/overview/working-with-objects/finalizers/) 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. \n\nNote 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.\n\n\n### Patches\nThis is resolved in Kyverno 1.10.0.\n\n### Workarounds\nThere is no known workaround.\n\n### References\n_Are there any links users can visit to find out more?_\n",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Go",
"name" : "github.com/kyverno/kyverno"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "1.10.0"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/kyverno/kyverno/security/advisories/GHSA-hq4m-4948-64cc"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2023-34091"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/kyverno/kyverno"
}, {
"type" : "WEB",
"url" : "https://github.com/kyverno/kyverno/releases/tag/v1.10.0"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-285" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2023-06-05T17:10:13Z",
"nvd_published_at" : "2023-06-01T17:15:10Z"
}
}