Skip to main content
Vulnerability Database/CVE-2026-98200

CVE-2026-98200: Linux Kernel Use-After-Free Vulnerability

CVE-2026-98200 is a use-after-free flaw in the Linux kernel hwmon hp-wmi-sensors driver that can cause memory corruption during concurrent sensor state reads. This article covers technical details, affected versions, impact assessment, and mitigation strategies.

Published:

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

CVE-2026-98200 Overview

CVE-2026-98200 is a use-after-free vulnerability in the Linux kernel's hp-wmi-sensors hwmon driver. The flaw resides in the fungible_show() function, which reads the nsensor->current_state pointer after the protecting state->lock has been released. A concurrent call into update_numeric_sensor_from_wobj() can free the old string with devm_kfree() and install a replacement while another thread is still dereferencing the stale pointer in seq_printf(). The fix wraps the read in fungible_show() with state->lock so the free-and-replace cannot race with concurrent readers.

Critical Impact

Concurrent reads of a sensor's current_state debugfs entry can trigger a use-after-free in kernel memory, risking kernel information disclosure or memory corruption on affected HP systems.

Affected Products

  • Linux kernel versions containing the hp-wmi-sensors hwmon driver prior to the fix commits
  • Systems running HP hardware that loads the hp-wmi-sensors module
  • Distributions shipping stable kernel branches that have not yet backported the referenced patch commits

Discovery Timeline

  • 2026-10-06 - CVE-2026-98200 published to NVD
  • 2026-10-06 - Last updated in NVD database

Technical Details for CVE-2026-98200

Vulnerability Analysis

The hp-wmi-sensors driver exposes HP hardware sensor data through hwmon and debugfs. The sensor state is cached in nsensor->current_state, a heap-allocated string that is refreshed when the underlying hardware state changes. update_numeric_sensor_from_wobj() performs the refresh by allocating a new string, freeing the old one with devm_kfree(), and swapping the pointer. This update path is serialized by state->lock.

The read path in fungible_show() first calls hp_wmi_update_info(), which acquires and releases state->lock internally. After the helper returns, the lock is no longer held, yet fungible_show() proceeds to dereference nsensor->current_state directly in seq_printf(). Two user-space readers accessing the same sensor concurrently, or one reader triggering a refresh while another is formatting output, can observe the pointer being freed and reassigned mid-print. The result is a use-after-free read of kernel heap memory.

Root Cause

The root cause is incorrect lock scoping. The driver assumes the lock held inside hp_wmi_update_info() is sufficient to protect subsequent reads of fields updated under that same lock. In practice the lock is dropped before the read occurs, leaving the cached pointer unprotected against the free-and-replace sequence in the update routine [CWE-416].

Attack Vector

Exploitation requires local access to the system and the ability to read the sensor's current_state debugfs entry under /sys/kernel/debug/. An unprivileged user who can open the entry, or two cooperating readers that race their accesses, can trigger the race window. The upstream fix extends state->lock coverage to the seq_printf() call inside fungible_show(), ensuring the read and the free-and-replace in update_numeric_sensor_from_wobj() cannot interleave.

See the upstream fixes for the exact changes: Linux Kernel Commit 72c8514, Linux Kernel Commit 9c1e65b, Linux Kernel Commit b6b2a63, Linux Kernel Commit e6cb0b4, and Linux Kernel Commit f59ecfd.

Detection Methods for CVE-2026-98200

Indicators of Compromise

  • Kernel oops or panic traces referencing fungible_show, hp_wmi_sensors, or seq_printf with slab-use-after-free signatures.
  • KASAN splats reporting a use-after-free read in nsensor->current_state during debugfs access.
  • Unexpected kernel log entries from the hp-wmi-sensors subsystem coinciding with concurrent debugfs reads.

Detection Strategies

  • Enable KASAN on test kernels and exercise concurrent reads of the hwmon debugfs entries exported by hp-wmi-sensors to surface the race.
  • Review loaded kernel modules on HP endpoints with lsmod | grep hp_wmi_sensors and correlate against installed kernel version to identify unpatched systems.
  • Monitor dmesg and /var/log/kern.log for KASAN, slab, or general protection fault reports originating in the hwmon stack.

Monitoring Recommendations

  • Collect kernel log telemetry centrally and alert on crash signatures referencing hp_wmi_sensors or fungible_show.
  • Track process access to /sys/kernel/debug/hwmon/ paths on HP hardware fleets to identify unusual repeated or concurrent readers.
  • Baseline running kernel versions across the fleet and flag hosts that remain on pre-patch builds.

How to Mitigate CVE-2026-98200

Immediate Actions Required

  • Apply the stable kernel updates incorporating the fix commits referenced in the external advisories.
  • If immediate patching is not possible, restrict access to the hp-wmi-sensors debugfs entries to privileged users only.
  • Consider unloading the hp_wmi_sensors module on systems that do not require HP sensor telemetry.

Patch Information

The fix adds explicit acquisition of state->lock around the seq_printf() read in fungible_show() so the string cannot be freed while another thread is still reading it. The patch is available in the upstream Linux stable tree via the commits listed above. Downstream distribution maintainers should backport the change into supported stable branches.

Workarounds

  • Mount debugfs with restricted permissions or disable debugfs entirely where operational requirements allow.
  • Blacklist the hp_wmi_sensors module on hosts that do not depend on HP hardware monitoring with an entry in /etc/modprobe.d/.
  • Limit concurrent access to hwmon debugfs entries by restricting the user accounts and services that interact with sensor data.
bash
# Configuration example: prevent the vulnerable module from loading
echo "blacklist hp_wmi_sensors" | sudo tee /etc/modprobe.d/blacklist-hp-wmi-sensors.conf
sudo rmmod hp_wmi_sensors 2>/dev/null || true
sudo update-initramfs -u

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.