CVE-2025-40051
Description
From CVE.org
In the Linux kernel, the following vulnerability has been resolved: vhost: vringh: Modify the return value check The return value of copy_from_iter and copy_to_iter can't be negative, check whether the copied lengths are equal.
Statement
vringh incorrectly treated copy_from_iter() as potentially negative and only checked ret < 0. Since copy_from_iter() returns the number of bytes copied (non-negative), short/partial copies were falsely accepted, risking use of incomplete data and subsequent corruption/instability. The fix checks size != translated and returns -EFAULT on mismatch, properly handling faults/short copies in the vhost IOTLB translation path. Exploitation requires local access to the vhost/virtio datapath — i.e. a process that can open and interact with /dev/vhost-* or /dev/kvm. On typical systems this means the attacker must be root or a member of the kvm group. If vhost or kvm not being used, then ordinary unprivileged users do not have access by default.
Mitigation
To mitigate this issue, prevent module vringh from being loaded. Please see https://access.redhat.com/solutions/41278 for how to blacklist a kernel module to prevent it from loading automatically.
Common Vulnerability Scoring System (CVSS) Score Details
Info alert:Important note
CVSS scores for open source components depend on vendor-specific factors (e.g. version or build chain). Therefore, Red Hat's score and impact rating can be different from NVD and other vendors. Red Hat remains the authoritative CVE Naming Authority (CNA) source for its products and services (see Red Hat classifications).
The following CVSS metrics and score provided are preliminary and subject to review.
CVSS v3 Score Breakdown
| Red Hat | NVD | cve.org | |
|---|---|---|---|
| Base Score | 5.5 | N/A | 7.8 |
| Attack Vector | Local | N/A | Local |
| Attack Complexity | Low | N/A | Low |
| Privileges Required | Low | N/A | Low |
| User Interaction | None | N/A | None |
| Scope | Unchanged | N/A | Unchanged |
| Confidentiality | None | N/A | High |
| Integrity Impact | None | N/A | High |
| Availability Impact | High | N/A | High |
Vector
Red Hat: CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
cve.org: CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
Understanding the Weakness (CWE)
Confidentiality,Availability,Integrity
Technical Impact: Read Application Data; DoS: Crash, Exit, or Restart; Unexpected State
Frequently Asked Questions
Not sure what something means? Check out our Security Glossary.
Want to get errata notifications? Sign up here.