CVE-2026-46151: usb: usblp: fix heap leak in IEEE 1284 device ID via short response

Published May 28, 2026
·
Updated

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

usb: usblp: fix heap leak in IEEE 1284 device ID via short response

usblpctrlmsg() collapses the usbcontrolmsg() return value to 0/-errno, discarding the actual number of bytes transferred. A broken printer can complete the GETDEVICEID control transfer short and the driver has no way to know.

usblpcachedeviceidstring() reads the 2-byte big-endian length prefix from the response and trusts it (clamped only to the buffer bounds). The buffer is kmalloc(1024) at probe time. A device that sends exactly two bytes (e.g. 0x03 0xFF, claiming a 1023-byte ID) leaves deviceidstring[2..1022] holding stale kmalloc heap.

That stale data is then exposed: - via the ieee1284id sysfs attribute (sprintf("%s", buf+2), truncated at the first NUL in the stale heap), and - via the IOCNRGETDEVICEID ioctl, which copytouser()s the full claimed length regardless of NULs, up to 1021 bytes of uninitialized heap, with the leak size chosen by the device.

Fix this up by just zapping the buffer with zeros before each request sent to the device.

Affected Software

16 affected componentsFixes available
Linux Linux kernel (usblp)
Linux Linux kernel>=2.6.12.1<5.10.258
Linux Linux kernel>=5.11<5.15.209
Linux Linux kernel>=5.16<6.1.175
Linux Linux kernel>=6.2<6.6.140
Linux Linux kernel>=6.7<6.12.88
Linux Linux kernel>=6.13<6.18.30
Linux Linux kernel>=6.19<7.0.7
Linux Linux kernel=2.6.12
Linux Linux kernel=2.6.12-rc2
Linux Linux kernel=2.6.12-rc3
Linux Linux kernel=2.6.12-rc4
Linux Linux kernel=2.6.12-rc5
Linux Linux kernel=7.1-rc1
Linux Linux kernel=7.1-rc2
Microsoft azl3 kernel 6.6.139.1-1<6.6.141.1-1
6.6.141.1-1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 6.6.141.1-1
  2. Upgrade

    Upgrade Linux kernel usb: usblp to a version that resolves this vulnerability.

    Patch usblp: fix heap leak in IEEE 1284 device ID via short response
  3. Configuration

    Modify usblp to clear (zero) the kmalloc(1024) device ID string buffer before each device request, so stale heap data cannot be exposed via ioctl/sysfs even when the device completes GET_DEVICE_ID control transfers short or claims a length with NULs.

    usblp device ID string buffer handling = zap buffer with zeros before each request (before each request, clear kmalloc(1024) buffer)

Event History

May 28, 2026
CVE Published
via MITRE·09:36 AM
Data Sourced
via MITRE·09:36 AM
Description
Data Sourced
via NVD·10:16 AM
RemedyDescriptionSeverityWeaknessAffected Software
May 29, 2026
Data Sourced
via Microsoft·08:08 AM
DescriptionSeverityWeakness
Data Sourced
via Microsoft·08:08 AM
Affected Software
Updated
via Microsoft·08:08 AM
DescriptionSeverity

Frequently Asked Questions

1

Who is realistically exposed to this issue?

Systems using the Linux usblp printer driver are exposed when a broken or malicious USB printer provides a deliberately short IEEE 1284 GET_DEVICE_ID response. The affected data can be exposed through the ieee1284_id sysfs attribute or the IOCNR_GET_DEVICE_ID ioctl.

2

What access does an attacker need to trigger the leak?

An attacker needs local access and control of, or the ability to connect, a USB printer device that can send a crafted short control-transfer response. The CVSS vector also indicates low-privilege local access is required and no user interaction is required.

3

How much data can be disclosed?

The device can cause disclosure of stale kmalloc heap contents from the device-ID buffer. The ioctl can copy up to 1021 bytes of uninitialized heap data to user space, while the sysfs output stops at the first NUL byte.

4

What is the remediation described by the fix?

The fix clears the device-ID buffer to zeros before each request to the USB device. This prevents bytes not returned by a short response from retaining stale heap contents.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203