CVE-2025-21656: hwmon: (drivetemp) Fix driver producing garbage data when SCSI errors occur
In the Linux kernel, the following vulnerability has been resolved:
hwmon: (drivetemp) Fix driver producing garbage data when SCSI errors occur
scsi_execute_cmd() function can return both negative (linux codes) and
positive (scsi_cmnd result field) error codes.
Currently the driver just passes error codes of scsi_execute_cmd() to
hwmon core, which is incorrect because hwmon only checks for negative
error codes. This leads to hwmon reporting uninitialized data to
userspace in case of SCSI errors (for example if the disk drive was
disconnected).
This patch checks scsi_execute_cmd() output and returns -EIO if it's
error code is positive.
[groeck: Avoid inline variable declaration for portability]
Security readout for executives and security teams
Plain-English summary
CVE-2025-21656 is a Linux kernel bug in the drivetemp hardware-monitoring driver. When a storage device has SCSI errors, such as a disconnected disk, the driver can report uninitialized or garbage temperature data to userspace. The main business concern is unreliable monitoring data and possible unintended data exposure, not remote takeover based on available sources.
Executive priority
Treat as routine kernel hygiene unless affected systems use drive temperature data for safety, availability, or automation decisions. There is no sourced evidence of active exploitation or remote compromise, but inaccurate monitoring can still create operational risk.
Technical view
The drivetemp hwmon driver mishandles scsi_execute_cmd() return values. Positive SCSI result codes are passed to hwmon, which only treats negative values as errors. On SCSI errors, hwmon may expose uninitialized data to userspace. The kernel fix converts positive SCSI error results to -EIO before returning to hwmon.
Likely exposure
Exposure is most likely on Linux systems using the drivetemp hwmon driver for drive temperature monitoring, especially where SCSI command errors occur. The CVE record identifies affected Linux kernel ranges and stable commits, but distribution-specific affected versions require vendor confirmation.
Exploitation context
No active exploitation is indicated in the provided sources, and the CVE is not listed as KEV. Triggering requires relevant kernel code paths and SCSI error conditions. The sources describe incorrect telemetry and uninitialized data reporting, not a remote code execution path.
Researcher notes
The issue is a signed/semantic error-handling mismatch: scsi_execute_cmd() may return positive SCSI result codes, while hwmon expects negative Linux errno values. The patch normalizes positive errors to -EIO. Source detail is limited; no CVSS, CWE, or distribution matrix is provided.
Mitigation direction
Apply a vendor kernel update that includes the referenced stable drivetemp fix.
Check Linux distribution advisories for affected package versions and backport status.
Prioritize systems relying on drive temperature telemetry for alerting or automation.
Validation and detection
Inventory Linux kernel versions across servers and appliances.
Confirm whether the vendor kernel includes the referenced stable commits.
Review monitoring systems for anomalous drive temperature readings during SCSI errors.
Track remediation through normal kernel patch compliance reporting.
Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cve · low confidence lookup
CVE-2025-21656 mapping review
Open the CVE-to-ATT&CK bridge for reviewed, inferred, or future official mappings tied to this CVE.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.
0CVSS vectors
3Timeline events
0ADP providers
4Source links
Vulnerability timeline
Timeline events are normalized from CVE metadata, CNA source timelines, ADP timelines, and KEV metadata when present.
CVE reservedCVE Program
The CVE ID was reserved by the assigning CNA.
CVE publishedCVE Program
The CVE record was published.
Jan 21, 2025, 12:18 UTC (UTC+00:00)
CVE updatedCVE Program
The CVE record metadata indicates this as the latest update time.