CVE-2026-139392: lib: validate in-memory LZ4 chunk length

Published Nov 30, 2026
·
Updated

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

lib: validate in-memory LZ4 chunk length

We found and validated an issue in lib/decompressunlz4.c. The bug is reachable by a root user through kexecfileload() with a crafted external initrd.

unlz4() reads the compressed chunk length from an in-memory initrd and passes it to LZ4decompresssafe(). It only checks the chunk length against the allocation size when the input is filled by a callback.

Reject an in-memory chunk that extends past the remaining input before calling the LZ4 decoder. This prevents malformed initrds from making the decoder read past the mapped archive.

Affected Software

1 affected component
Linux Linux kernel

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Compensating control

    In lib/decompress_unlz4.c, reject an in-memory LZ4 chunk whose length exceeds the remaining input or allocation size before passing it to LZ4_decompress_safe().

Event History

Nov 30, 2026
CVE Published
via MITRE·01:34 PM
Data Sourced
via MITRE·01:34 PM
Description

Frequently Asked Questions

1

Who can realistically exploit this issue?

The described path is reachable by a root user who invokes kexec_file_load() with a crafted external initrd. The provided information does not indicate that an unprivileged local user or remote attacker can reach it directly.

2

What must an attacker control to trigger the out-of-bounds read?

They need to supply an external initrd containing an in-memory LZ4 chunk whose declared compressed length extends beyond the remaining archive input. The vulnerable code passes that length to LZ4_decompress_safe() without validating it for the in-memory input path.

3

What is the effect of the fix?

The fix rejects an in-memory LZ4 chunk when its length exceeds the remaining input before invoking the LZ4 decoder. This prevents the decoder from reading beyond the mapped archive.

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