KernelScan.io

HIGH Introduced in 6.6

hp-bioscfg StringBuffer Overflow

CVE-2026-81012

CVSS 8.4 / 10.0 NVD

CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

KernelScan AI7.0HIGH

01

In the Linux kernel, the following vulnerability has been resolved: platform/x86: hp-bioscfg: fix off-by-one write in hp_get_string_from_buffer() hp_get_string_from_buffer() clamps the converted string length against the destination buffer size with "size > dst_size", so when the converted length is exactly equal to dst_size, conv_dst_size is left at dst_size and the unconditional NUL terminator write dst[conv_dst_size] = 0; lands one byte past the destination buffer. This is the same shape of bug as the previously fixed off-by-one in hp_convert_hexstr_to_str(): the buffer is sized correctly for the content, but the terminator write is never checked against that size. Fix by changing the comparison to ">=" so conv_dst_size is always left with room for the terminator. All fixed-size destinations that reach this function (path[512], current_value[512], current_password/current_value[64], and the per-entry buffers in encodings[][512] and prerequisites[][512]) are affected.

02

Engine v0.6.0

Risk summary

A one-byte stack buffer overflow exists in the HP BIOS Configuration driver, triggered when firmware data produces a string whose converted length exactly matches a fixed-size destination buffer. Any local user on an affected HP notebook can reach the vulnerable path by reading sysfs attributes, though exploitation requires a specific string length from firmware. The overflow corrupts kernel stack memory and may lead to privilege escalation or a system crash.

Affecteddrivers/platform/x86/hp/hp-bioscfg/bioscfg.c (platform/x86 hp-bioscfg)

Vulnerability analysis

The HP BIOS Configuration driver copies strings from firmware data into fixed-size buffers, but it fails to leave room for the string terminator when the content exactly fills the buffer. This causes a one-byte write past the end of a kernel stack buffer. The corrected code always reserves space for the terminator. The flaw is reached when a local user reads the firmware-attributes exposed by the driver through sysfs, which triggers parsing of BIOS configuration data; the overflow only occurs when a string in that data has a precise length matching the buffer size. The driver is only present on HP commercial notebooks.

03

BranchIntroducedFixed inPatch commit
6.126.66.12.1093cc772d01547
6.186.66.18.50b15b334fbc3c
6.66.66.6.1578f5aa1506cdd
mainline6.67.3-rc1dc03f05e419f
7.26.67.2.4ddf98cf33529
cip/6.126.66.12.111-cip323cc772d01547