CVE-2026-98033: bpf: Preserve inner map identity in callback frames

Published Sep 25, 2026
·
Updated

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

bpf: Preserve inner map identity in callback frames

Callback frame constructors initialize map-typed argument registers with markregknownzero() and then restore mapptr. This clears mapuid, which is the only field distinguishing inner maps that share an innermapmeta template.

When a timer callback invokes bpfforeachmapelem() on a second inner map, both the saved first map and the second map value can reach the nested callback as the same template with mapuid zero. bpftimerinit() then accepts pairing the timer from the second map with the first map.

The runtime records the first map in the timer without taking a reference. Freeing that map does not find the timer stored in the second map, so a later timer callback dereferences the freed map.

Copy mapuid from the same caller register as mapptr when constructing for-each, timer/workqueue, and task-work callback arguments. The existing identity check can then reject mismatched inner maps while allowing a callback value to be paired with its actual map.

Affected Software

1 affected component
Linux Linux kernel

Event History

Sep 25, 2026
CVE Published
via MITRE·10:23 AM
Data Sourced
via MITRE·10:23 AM
Description
Data Sourced
via NVD·11:17 AM
Description

Frequently Asked Questions

1

What conditions are required to trigger the use-after-free?

A BPF program must use callback paths involving inner maps that share an inner_map_meta template, allowing a timer from one inner map to be paired with another. The affected flow includes a timer callback invoking bpf_for_each_map_elem() on a second inner map, followed by freeing the first map while its timer is recorded in the second map.

2

What is the security impact after the mismatched maps are accepted?

The runtime can retain a pointer to the first map in a timer without taking a reference. Because the timer is stored under the second map, freeing the first map does not locate and cancel that timer, and a later timer callback can dereference freed memory.

3

Which callback argument types are involved in the fix?

The fix preserves map_uid when constructing callback arguments for for-each, timer/workqueue, and task-work callbacks. This lets the existing identity check distinguish inner maps that use the same template and reject mismatched pairings.

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