VYPR
Unrated severityNVD Advisory· Published Oct 28, 2025· Updated Apr 15, 2026

CVE-2025-40056

CVE-2025-40056

Description

In the Linux kernel, the following vulnerability has been resolved:

vhost: vringh: Fix copy_to_iter return value check

The return value of copy_to_iter can't be negative, check whether the copied length is equal to the requested length instead of checking for negative values.

AI Insight

LLM-synthesized narrative grounded in this CVE's description and references.

In the Linux kernel's vhost vringh, a flawed return value check for copy_to_iter could cause undetected incomplete data copies, leading to potential data corruption.

Root

Cause

The vulnerability resides in the vhost vringh code, which handles virtual I/O ring operations. The function copy_to_iter returns the number of bytes successfully copied, which is always non-negative (zero or positive). The original code incorrectly checked for a negative return value to detect errors. Since copy_to_iter never returns a negative value, this check would never trigger, meaning partial copies (where the return value is less than the requested length) would go unnoticed [1].

Exploitation

An attacker who can influence the data passed to vringh operations—for instance, through a malicious virtual machine or a compromised userspace process—could exploit this bug. By causing copy_to_iter to perform a partial copy, the kernel would proceed as if the operation succeeded, even though only part of the intended data was transferred [2].

Impact

If exploited, this could lead to data corruption in kernel buffers, potentially leaking sensitive information from memory that was not completely overwritten. In virtualized environments, it might enable a guest VM to corrupt host memory or escape isolation, though the specific impact depends on the wider system configuration and attack scenario [2].

Mitigation

The fix has been applied to the Linux kernel stable branches. System administrators should update their kernels to versions containing the patch (commit references [1] and [2]). No workaround is available; updating is the recommended course of action.

AI Insight generated on May 19, 2026. Synthesized from this CVE's description and the cited reference URLs; citations are validated against the source bundle.

Affected products

1

Patches

5

Vulnerability mechanics

Generated on May 9, 2026. Inputs: CWE entries + fix-commit diffs from this CVE's patches. Citations validated against bundle.

References

5

News mentions

0

No linked articles in our index yet.