Ad

CVE-2026-139010

NONE EPSS 0.21%
Обновлено 30 ноября 2026
HP
Параметр Значение
Поставщик HP
Публичный эксплойт Нет

В ядре Linux была устранена следующая уязвимость: platform/x86: hp-bioscfg: fix slab-out-of-bounds write in hp_convert_hexstr_to_str() hp_convert_hexstr_to_str() декодирует строку ACPI, состоящую из разделенных пробелами шестибайтовых токенов ASCII вида «0xHH». For example, the four-byte input "0x41" decodes to the single character 'A', and the nine-byte input "0x09 0x41" decodes to "\tA": each token is read in a five-byte step (four characters for the token, one for the trailing delimiter), and produces one output byte, or two if that byte is '\\', '\r', '\n', or '\t', which are written back out as a backslash followed by the matching letter. Выходной буфер имеет размер kmalloc(input_len, GFP_KERNEL), сырую кодированную длину входа, а не декодированную длину.

Для хорошо сформированного ввода это щедро, так как пять входных байтов никогда не декодируют более двух выходных байтов. Но input_len поступает непосредственно из длины строки ACPI, о которой сообщается в прошивке, и не гарантирует соблюдение пятибайтового кодирования, поэтому короткий input_len может недооценивать выделение. При input_len 1 выделяется только один байт, но декодирование по-прежнему производит по крайней мере один выходной байт плюс терминатор NUL, записанный безоговорочно впоследствии, поэтому требуется два байта.

Этот терминатор записывает один байт после конца распределения. KASAN caught exactly this during BIOS attribute enumeration on boot, triggered by a one-byte encoded input value: BUG: KASAN: slab-out-of-bounds in hp_convert_hexstr_to_str+0x6d8/0x710 [hp_bioscfg] Write of size 1 at addr ffff8881032e5d81 by task (udev-worker)/520 The buggy address is located 0 bytes to the right of allocated 1-byte region [ffff8881032e5d80, ffff8881032e5d81) Size the allocation to the worst-case decoded length instead of the raw input length: two output bytes for every five-byte input chunk (DIV_ROUND_UP(input_len, 5)), plus one byte for the terminator.

Показать оригинальное описание (EN)

In the Linux kernel, the following vulnerability has been resolved: platform/x86: hp-bioscfg: fix slab-out-of-bounds write in hp_convert_hexstr_to_str() hp_convert_hexstr_to_str() decodes an ACPI string made up of space-separated ASCII hex-byte tokens of the form "0xHH". For example, the four-byte input "0x41" decodes to the single character 'A', and the nine-byte input "0x09 0x41" decodes to "\tA": each token is read in a five-byte step (four characters for the token, one for the trailing delimiter), and produces one output byte, or two if that byte is '\\', '\r', '\n', or '\t', which are written back out as a backslash followed by the matching letter. The output buffer is sized with kmalloc(input_len, GFP_KERNEL), the raw encoded length of the input, not the decoded length. For well-formed input this is generous, since five input bytes never decode to more than two output bytes. But input_len comes directly from the ACPI string length reported by firmware and isn't guaranteed to respect the five-byte encoding, so a short input_len can undersize the allocation. With input_len == 1, only one byte is allocated, yet decoding still produces at least one output byte plus the NUL terminator written unconditionally afterwards, so two bytes are needed. That terminator write then lands one byte past the end of the allocation. KASAN caught exactly this during BIOS attribute enumeration on boot, triggered by a one-byte encoded input value: BUG: KASAN: slab-out-of-bounds in hp_convert_hexstr_to_str+0x6d8/0x710 [hp_bioscfg] Write of size 1 at addr ffff8881032e5d81 by task (udev-worker)/520 The buggy address is located 0 bytes to the right of allocated 1-byte region [ffff8881032e5d80, ffff8881032e5d81) Size the allocation to the worst-case decoded length instead of the raw input length: two output bytes for every five-byte input chunk (DIV_ROUND_UP(input_len, 5)), plus one byte for the terminator.