Linux apparmor: query_data() output overlaps lookup key
Key facts
- Attack vector
- —
- Privileges required
- —
- User interaction
- —
- Attack complexity
- —
- Impact type
- —
- Confidentiality · integrity · availability
- —
- Fix status
- Fixed
No CVSS vector from any source. Fix status from CNA.
Summary
query_data() in the Linux kernel's apparmor module writes output into a buffer overlapping the lookup key that later label_for_each_confined() iterations use, so with several profiles carrying a data table, the first match can corrupt later lookups. Without a NUL byte from the key to the allocation's end, strhash() reads past the 4096-byte slab object (KASAN: slab-out-of-bounds in jhash). The .access file is writable by unprivileged users (0666), but the bug needs loaded profiles with a data table, which requires CAP_MAC_ADMIN and is absent on default distribution policies. The issue affects Linux from 4.13.
Written with Claude Haiku 5.5 from the sources below · 2026-12-01
Description from the CNA
In the Linux kernel, the following vulnerability has been resolved: apparmor: fix query_data() output overlapping the lookup key In query_data(), buf and query point into the same multi_transaction buffer: buf at the start, query a few bytes in, and the lookup key right after the label string that query points to. Reusing the buffer is by design and is safe as long as the query is fully parsed before buf is written to, but the key is not: it is dereferenced on every iteration of label_for_each_confined(), after output has already been written. So when the label has more than one profile with a data table, the data of the first matching profile is written to buf while the key is still needed, and overwrites it if the data is large enough. The later lookups then run on a corrupted key. Besides, if the data has no NUL byte from the key's position to the end of the allocation, strhash() -> strlen() -> jhash() reads past the 4096-byte slab object, triggering an out-of-bound read: BUG: KASAN: slab-out-of-bounds in jhash+0x595/0x5e0 Read of size 1 at addr ff1100001159d000 by task exploit/155 CPU: 0 UID: 1000 PID: 155 Comm: exploit Not tainted 7.3.0-rc7 #1 Call Trace: jhash+0x595/0x5e0 aa_write_access+0x880/0x1400 vfs_write+0x26f/0xd20 ksys_write+0x115/0x210 Writing to the .access file is unprivileged (0666), but triggering this requires loaded profiles that carry a data table, which needs CAP_MAC_ADMIN and is not the case on default distribution policies. Fix by copying the key with kstrdup() before writing any output to buf, so the key stays valid across all loop iterations regardless of what gets written to the overlapping buffer.
Why it matters now
SSVC decision points
Not available: CISA has not published SSVC decision points for this record.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| Linux | Linux | 4.13 and later | 5.10.275, 5.15.226, 6.1.193, 6.6.163, 6.12.119, 6.18.65, 7.3.4, 7.4-rc1 | Patch available | CNA |
- Linux VendorLinux Affected 4.13 and later Fixed in 5.10.275, 5.15.226, 6.1.193, 6.6.163, 6.12.119, 6.18.65, 7.3.4, 7.4-rc1 Patch available CNA
Remediation
Upgrade to a fixed kernel: 5.10.275, 5.15.226, 6.1.193, 6.6.163, 6.12.119, 6.18.65, 7.3.4 or 7.4-rc1. The fix copies the lookup key with kstrdup() before any output is written to buf. Red Hat rates this Moderate.
Written with Claude Haiku 5.5 from the sources below · 2026-12-01
- Fix · CNA Linux (Linux) Fixed in 5.10.275, 5.15.226, 6.1.193, 6.6.163, 6.12.119, 6.18.65, 7.3.4, 7.4-rc1
Vendor assessments
Red Hat
Red Hat rating: Moderate. Red Hat's page for this CVE →
Not affected: 7 products
- Red Hat Enterprise Linux 10
- Red Hat Enterprise Linux 6
- Red Hat Enterprise Linux 7
- Red Hat Enterprise Linux 8
- Red Hat Enterprise Linux 9
- Red Hat OpenShift Container Platform 4
- Red Hat OpenShift Container Platform 5
Timeline
- 2026-11-30 Threatist record created from CVE-2026-99833
- 2026-11-30 Alias added: GHSA-5rf7-9wpc-4vvj
- 2026-12-01 Affected versions changed · Red Hat
- 2026-12-01 CVSS score added · Red Hat
References
Other 8
- https://git.kernel.org/stable/c/decf312cdffb13c2c3b5d5217ae7d85e45150f88
- https://git.kernel.org/stable/c/e4c6ebf03802ee9e6de2be36d231462d30d49fb0
- https://git.kernel.org/stable/c/cddbf0c270b7bb2b21deb7dbcffd9802be23da4f
- https://git.kernel.org/stable/c/54f911b9c19582927c932b809e693db840b97e3e
- https://git.kernel.org/stable/c/f2143b4ecaf6afb81a785b6bf976274e16e58997
- https://git.kernel.org/stable/c/ff9f9a86b5b3e0942a96b6a1f91ed074090203c7
- https://git.kernel.org/stable/c/64d601ac18874892cb96bf81dab1fedfe77f41df
- https://git.kernel.org/stable/c/d30844001360a403a511cf24fc75ecaa6a7a7544
More Linux vulnerabilities
- TI-2025-26358 Zero-length TLS records mishandled on rx_list in Linux kernel KEVCVSS 3.1CRITICAL 9.8
- TI-2026-38352 Out-of-bounds write in Linux kernel ebtables SNAT ARP rewrite KEVCVSS 3.1HIGH 8.8
- TI-2021-02452 Overlayfs flaw in Linux kernel lets attackers gain elevated privileges KEVCVSS 3.1HIGH 8.8
- TI-2013-05264 Missing address checks in Linux kernel get_user and put_user on ARM KEVCVSS 3.1HIGH 8.8
- TI-2022-00125 Heap overflow in Linux kernel lets local users escalate privileges KEVCVSS 3.1HIGH 8.4
- TI-2013-01864 Wrong integer type in Linux kernel perf_swevent_init KEVCVSS 3.1HIGH 8.4
Sources
- CVE-2026-99833 · CVE Program
- CVE-2026-99833 · NVD
- GHSA-5rf7-9wpc-4vvj · GitHub Advisory Database · CC BY 4.0
- CVE-2026-99833 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences