chore(deps): update module kubevirt.io/kubevirt to v1.8.2 [security] (release-v0.24)#837
Conversation
|
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: redhat-renovate-bot The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
Signed-off-by: null <redhat-internal-renovate@redhat.com>
cd94a0c to
8918e6b
Compare
|
@redhat-renovate-bot: The following tests failed, say
Full PR test history. Your PR dashboard. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
This PR contains the following updates:
v1.4.0→v1.8.2KubeVirt Affected by an Authentication Bypass in Kubernetes Aggregation Layer in kubevirt.io/kubevirt
CVE-2025-64432 / GHSA-38jw-g2qx-4286 / GO-2025-4103
More information
Details
KubeVirt Affected by an Authentication Bypass in Kubernetes Aggregation Layer in kubevirt.io/kubevirt
Severity
Unknown
References
This data is provided by OSV and the Go Vulnerability Database (CC-BY 4.0).
KubeVirt Isolation Detection Flaw Allows Arbitrary File Permission Changes
CVE-2025-64437 / GHSA-2r4r-5x78-mvqf / GO-2025-4102
More information
Details
Summary
_Short summary of the problem. Make the impact and severity as clear as possible.
It is possible to trick the
virt-handlercomponent into changing the ownership of arbitrary files on the host node to the unprivileged user with UID107due to mishandling of symlinks when determining the root mount of avirt-launcherpod.Details
Give all details on the vulnerability. Pointing to the incriminated source code is very helpful for the maintainer.
In the current implementation, the
virt-handlerdoes not verify whether thelauncher-sockis a symlink or a regular file. This oversight can be exploited, for example, to change the ownership of arbitrary files on the host node to the unprivileged user with UID107(the same user used byvirt-launcher) thus, compromising the CIA (Confidentiality, Integrity and Availability) of data on the host.To successfully exploit this vulnerability, an attacker should be in control of the file system of the
virt-launcherpod.PoC
Complete instructions, including specific configuration details, to reproduce the vulnerability.
In this demonstration, two additional vulnerabilities are combined with the primary issue to arbitrarily change the ownership of a file located on the host node:
launcher-sock) is used to manipulate the interpretation of the root mount within the affected container, effectively bypassing expected isolation boundaries.disk.img) is employed to alter the perceived location of data within a PVC, redirecting it to a file owned by root on the host filesystem.It is assumed that an attacker has access to a
virt-launcherpod's file system (for example, obtained using another vulnerability) and also has access to the host file system with the privileges of theqemuuser (UID=107). It is also assumed that they can create unprivileged user namespaces:admin@minikube:~$ sysctl -w kernel.unprivileged_userns_clone=1The below is inspired by an article, where the attacker constructs an isolated environment solely using Linux namespaces and an augmented Alpine container root file system.
After the environment is set, the
launcher-sockin thevirt-launchercontainer should be replaced with a symlink to../../../../../../../../../proc/2245509/root/tmp/bad.sock(2245509 is the PID of the above isolated shell process). This should be done, however, in a the right moment. For this demonstration, it was decided to trigger the bug while leveraging a race condition when creating or updating a VMI:The manifest of the #acr("vmi") which is going to trigger the bug is:
Just before the line is executed, the attacker should replace the
launcher-sockwith a symlink to thebad.sockcontrolled by the isolated process:Upon successful exploitation,
virt-launcherconnects to the attacker controlled socket, misinterprets the root mount and changes the permissions of the host's/etc/passwdfile:The attacker controlling an unprivileged user can now update the contents of the file.
Impact
What kind of vulnerability is it? Who is impacted?
This oversight can be exploited, for example, to change the ownership of arbitrary files on the host node to the unprivileged user with UID
107(the same user used byvirt-launcher) thus, compromising the CIA (Confidentiality, Integrity and Availability) of data on the host.Severity
CVSS:3.1/AV:L/AC:H/PR:H/UI:N/S:C/C:L/I:L/A:LReferences
This data is provided by OSV and the GitHub Advisory Database (CC-BY 4.0).
KubeVirt Isolation Detection Flaw Allows Arbitrary File Permission Changes in kubevirt.io/kubevirt
CVE-2025-64437 / GHSA-2r4r-5x78-mvqf / GO-2025-4102
More information
Details
KubeVirt Isolation Detection Flaw Allows Arbitrary File Permission Changes in kubevirt.io/kubevirt
Severity
Unknown
References
This data is provided by OSV and the Go Vulnerability Database (CC-BY 4.0).
KubeVirt Improper TLS Certificate Management Handling Allows API Identity Spoofing in kubevirt.io/kubevirt
CVE-2025-64434 / GHSA-ggp9-c99x-54gp / GO-2025-4107
More information
Details
KubeVirt Improper TLS Certificate Management Handling Allows API Identity Spoofing in kubevirt.io/kubevirt
Severity
Unknown
References
This data is provided by OSV and the Go Vulnerability Database (CC-BY 4.0).
KubeVirt's Improper TLS Certificate Management Handling Allows API Identity Spoofing
CVE-2025-64434 / GHSA-ggp9-c99x-54gp / GO-2025-4107
More information
Details
Summary
Due to improper TLS certificate management, a compromised
virt-handlercould impersonatevirt-apiby using its own TLS credentials, allowing it to initiate privileged operations against anothervirt-handler.Details
Give all details on the vulnerability. Pointing to the incriminated source code is very helpful for the maintainer.
Because of improper TLS certificate management, a compromised
virt-handlerinstance can reuse its TLS bundle to impersonatevirt-api, enabling unauthorized access to VM lifecycle operations on othervirt-handlernodes.The
virt-apicomponent acts as a sub-resource server, and it proxies API VM lifecycle requests tovirt-handlerinstances.The communication between
virt-apiandvirt-handlerinstances is secured using mTLS. The former acts as a client while the latter as the server. The client certificate used byvirt-apiis defined in the source code as follows and have the following properties:The
virt-handlercomponent verifies the signature of client certificates using a self-signed root CA. This latter is generated byvirt-operatorwhen the KubeVirt stack is deployed and it is stored within a ConfigMap in thekubevirtnamespace. This configmap is used as a trust anchor by allvirt-handlerinstances to verify client certificates.The
kubevirt-cais also used to sign the server certificate which is used by avirt-handlerinstance:In addition to the validity of the signature, the
virt-handlercomponent also verifies the CN field of the presented certificate:<code.sec.SetupTLSForVirtHandlerServer>
The above code illustrates that client certificates accepted be KubeVirt should have as CN
kubevirt.io:system:client:virt-handlerwhich is the same as the CN present in thevirt-api's certificate. However, the latter is not the only component in the KubeVirt stack which can communicate with avirt-handlerinstance.In addition to the extension API server, any other
virt-handlercan communicate with it. This happens in the context of VM migration operations. When a VM is migrated from one node to another, thevirt-handlers on both nodes are going to use structures calledProxyManagerto communicate back and forth on the state of the migration.This communication follows a classical client-server model, where the
virt-handleron the migration source node acts as a client and thevirt-handleron the migration destination node acts as a server. This communication is also secured using mTLS. The server certificate presented by thevirt-handleracting as a migration destination node is the same as the one which is used for the communication between the samevirt-handlerand thevirt-apiin the context of VM lifecycle operations (CN=kubevirt.io:system:node:virt-handler). However, the client certificate which is used by avirt-handlerinstance has the same CN as the client certificate used byvirt-api.Although the migration procedure, where two separate
virt-handlerinstances coordinate the transfer of a VM's state, is not directly tied to the communication betweenvirt-apiandvirt-handlerduring VM lifecycle management, there is a critical overlap in the TLS authentication mechanism. Specifically, the client certificate used by bothvirt-handlerandvirt-apishares the same CN field, despite the use of different, randomly allocated ports, for the two types of communication.PoC
Complete instructions, including specific configuration details, to reproduce the vulnerability.
To illustrate the vulnerability, a Minikube cluster has been deployed with two nodes (
minikubeandminikube-m02) thus, with twovirt-handlerinstances alongside a vmi running on one of the nodes. It is considered that an attacker has obtained access to the client certificate bundle used by thevirt-handlerinstance running on the compromised node (minikube) while the virtual machine is running on the other node (minikube-m02). Thus, they can interact with the sub-resource API exposed by the othervirt-handlerinstance and control the lifecycle of the VMs running on the other node:Impact
What kind of vulnerability is it? Who is impacted?
Due to the peer verification logic in
virt-handler(viaverifyPeerCert), an attacker who compromises avirt-handlerinstance, could exploit these shared credentials to impersonatevirt-apiand execute privileged operations against othervirt-handlerinstances potentially compromising the integrity and availability of the managed by it VM.Severity
CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:HReferences
This data is provided by OSV and the GitHub Advisory Database (CC-BY 4.0).
KubeVirt Affected by an Authentication Bypass in Kubernetes Aggregation Layer
CVE-2025-64432 / GHSA-38jw-g2qx-4286 / GO-2025-4103
More information
Details
Summary
_Short summary of the problem. Make the impact and severity as clear as possible.
A flawed implementation of the Kubernetes aggregation layer's authentication flow could enable bypassing RBAC controls.
Details
Give all details on the vulnerability. Pointing to the incriminated source code is very helpful for the maintainer.
It was discovered that the
virt-apicomponent fails to correctly authenticate the client when receiving API requests over mTLS. In particular, it fails to validate the CN (Common Name) field in the received client TLS certificates against the set of allowed values defined in theextension-apiserver-authenticationconfigmap.The Kubernetes API server proxies received client requests through a component called aggregator (part of K8S's API server), and authenticates to the
virt-apiserver using a certificate signed by the CA specified via the--requestheader-client-ca-fileCLI flag. This CA bundle is primarily used in the context of aggregated API servers, where the Kubernetes API server acts as a trusted front-end proxy forwarding requests.While this is the most common use case, the same CA bundle can also support less common scenarios, such as issuing certificates to authenticating front-end proxies. These proxies can be deployed by organizations to extend Kubernetes' native authentication mechanisms or to integrate with existing identity systems (e.g., LDAP, OAuth2, SSO platforms). In such cases, the Kubernetes API server can trust these external proxies as legitimate authenticators, provided their client certificates are signed by the same CA as the one defined via
--requestheader-client-ca-file.Nevertheless, these external authentication proxies are not supposed to directly communicate with aggregated API servers.
Thus, by failing to validate the CN field in the client TLS certificate, the
virt-apicomponent may allow an attacker to bypass existing RBAC controls by directly communicating with the aggregated API server, impersonating the Kubernetes API server and its aggregator component.However, two key prerequisites must be met for successful exploitation:
The attacker must possess a valid front-end proxy certificate signed by the trusted CA (
requestheader-client-ca-file). For example, they can steal the certificate material by compromising a front-end proxy or they could obtain a bundle by exploiting a poorly configured and managed PKI system.The attacker must have network access to the
virt-apiservice, such as via a compromised or controlled pod within the cluster.These conditions significantly reduce the likelihood of exploitation. In addition, the
virt-apicomponent acts as a sub-resource server, meaning it only handles requests for specific resources and sub-resources . The handled by it requests are mostly related to the lifecycle of already existing resources.Nonetheless, if met, the vulnerability could be exploited by a Pod-Level Attacker to escalate privileges, and manipulate existing virtual machine workloads potentially leading to violation of their CIA (Confidentiality, Integrity and Availability).
PoC
Complete instructions, including specific configuration details, to reproduce the vulnerability.
Bypassing authentication
In this section, it is demonstrated how an attacker could use a certificate with a different CN field to bypass the authentication of the aggregation layer and perform arbitrary API sub-resource requests to the
virt-apiserver.The
kube-apiserverhas been launched with the following CLI flags:By default, Minikube generates a self-signed CA certificate (
var/lib/minikube/certs/front-proxy-ca.crt) and use it to sign the certificate used by the aggregator (/var/lib/minikube/certs/front-proxy-client.crt):One can also inspect the contents of the
extension-apiserver-authenticationConfigMap which is used as a trust anchor by all extension API servers:It is assumed that an attacker has obtained access to a Kubernetes pod and could communicate with
virt-apireachable at10.244.0.6.The
virt-apiservice has two types of endpoints -- authenticated and non-authenticated:Each endpoint which is not in this list is considered an authenticated endpoint and requires a valid client certificate to be presented by the caller.
To illustrate the vulnerability and attack scenario, below is generated a certificate signed by the
front-proxy-cabut issued to an entity which is different thanfront-proxy-client(i.e the certificate has a different CN). Later on, it is assumed that the attacker has obtained access to the certificate bundle:The authentication will now succeed:
To fully exploit the vulnerability, the attacker must also provide valid authentication HTTP headers:
The
virt-apiis a sub-resource extension server - it handles only requests for specific resources and sub-resources (requests having URIs prefixed with/apis/subresources.kubevirt.io/v1/). In reality, most of the requests that it accepts are actually executed by thevirt-handlercomponent and are related to the lifecycle of a VM.Hence,
virt-handler's API can be seen as aggregated withinvirt-api's API which in turn transforms it into a proxy.The endpoints which are handled by
virt-apiare listed in the Swagger definitions available on GitHub @openapi-spec.Resetting a Virtual Machine Instance
Consider the following deployed
VirtualMachineInstance(VMI) within the default namespace:An attacker with a stolen external authentication proxy certificate could easily reset (hard reboot), freeze, or remove volumes from the virtual machine.
Impact
What kind of vulnerability is it? Who is impacted?
The
virt-apicomponent may allow an attacker to bypass existing RBAC controls by directly communicating with the aggregated API server, impersonating the Kubernetes API server and its aggregator component.Severity
CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:HReferences
This data is provided by OSV and the GitHub Advisory Database (CC-BY 4.0).
KubeVirt Arbitrary Container File Read in kubevirt.io/kubevirt
CVE-2025-64433 / GHSA-qw6q-3pgr-5cwq / GO-2025-4109
More information
Details
KubeVirt Arbitrary Container File Read in kubevirt.io/kubevirt
Severity
Unknown
References
This data is provided by OSV and the Go Vulnerability Database (CC-BY 4.0).
KubeVirt Arbitrary Container File Read
CVE-2025-64433 / GHSA-qw6q-3pgr-5cwq / GO-2025-4109
More information
Details
Summary
_Short summary of the problem. Make the impact and severity as clear as possible.
Mounting a user-controlled PVC disk within a VM allows an attacker to read any file present in the
virt-launcherpod. This is due to erroneous handling of symlinks defined within a PVC.Details
Give all details on the vulnerability. Pointing to the incriminated source code is very helpful for the maintainer.
A vulnerability was discovered that allows a VM to read arbitrary files from the
virt-launcherpod's file system. This issue stems from improper symlink handling when mounting PVC disks into a VM. Specifically, if a malicious user has full or partial control over the contents of a PVC, they can create a symbolic link that points to a file within thevirt-launcherpod's file system. Sincelibvirtcan treat regular files as block devices, any file on the pod's file system that is symlinked in this way can be mounted into the VM and subsequently read.Although a security mechanism exists where VMs are executed as an unprivileged user with UID
107inside thevirt-launchercontainer, limiting the scope of accessible resources, this restriction is bypassed due to a second vulnerability (TODO: put link here). The latter causes the ownership of any file intended for mounting to be changed to the unprivileged user with UID107prior to mounting. As a result, an attacker can gain access to and read arbitrary files located within thevirt-launcherpod's file system or on a mounted PVC from within the guest VM.PoC
Complete instructions, including specific configuration details, to reproduce the vulnerability.
Consider that an attacker has control over the contents of two PVC (e.g., from within a container) and creates the following symlinks:
By default, Minikube's storage controller (
hostpath-provisioner) will allocate the claim as a directory on the host node (HostPath). Once the above Kubernetes resources are created, the user can create the symlinks within the PVC as follows:Of course, these links could potentially be broken as the files, especially
default_arbitrary-container-read.xml, could not exist on thedual-pvc-podpod's file system. The attacker then deploy the following VM:The two PVCs will be mounted as volumes in "filesystem" mode:
From the documentation of the different volume modes, one can infer that if the backing
disk.imgis not owned by the unprivileged user with UID107, the VM should fail to mount it. In addition, it's expected that this backing file is in RAW format. While this format can contain pretty much anything, we consider that being able to mount a file from the file system ofvirt-launcheris not the expected behaviour. Below is demonstrated that after applying the VM manifest, the guest can read the/etc/passwdanddefault_migration.xmlfiles from thevirt-launcherpod's file system:Impact
What kind of vulnerability is it? Who is impacted?
This vulnerability breaches the container-to-VM isolation boundary, compromising the confidentiality of storage data.
Severity
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:NReferences
This data is provided by OSV and the GitHub Advisory Database (CC-BY 4.0).
KubeVirt Vulnerable to Arbitrary Host File Read and Write
CVE-2025-64324 / GHSA-46xp-26xh-hpqh / GO-2025-4110
More information
Details
Summary
The
hostDiskfeature in KubeVirt allows mounting a host file or directory owned b