CVE-2026-142942

Not scored yetLast modified Dec 3, 2026

Description

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

bpf: Destroy callee-local dynptrs on subprog return

A data slice is valid only while the specific dynptr that produced it remains valid. prepare_func_exit() copies a subprogram return value into the caller and then frees the callee state without applying the normal destruction semantics to dynptrs in the callee stack.

A callee can therefore derive a slice from a local dynptr, return or spill the slice into its caller, and then let the dynptr disappear with the callee frame. The slice retains the id of a dynptr that is no longer in the verifier state, so the verifier continues to accept accesses through it.

Before the object relationship refactor, bpf_dynptr_data() slices from referenced dynptrs also carried the shared reference id, allowing a later release to catch some of these escaped slices. The refactor made those slices precise children of their source dynptr and exposed the missing teardown as an accepted stale access even after the shared resource is released.

Add destroy_dynptrs_in_stack_slots() to apply the existing dynptr teardown to an inclusive range of stack slots. Reuse it for dynptr initialization, variable-offset stack writes, and the entire callee stack before freeing the frame. The teardown rejects losing the last dynptr for a referenced resource and invalidates the dynptr and all its descendants, including slices held in the caller. Propagate errors through prepare_func_exit().

Reuse the existing teardown API and diagnostic. Update the affected callback test expectation in this change so the commit remains test-clean.

Metrics

No CVSS score has been published yet.

Affected software

Source: the vendor's advisory (CNA). NVD analysis pending.

No affected versions have been published.

Timeline

Published
Dec 3, 2026
Last modified
Dec 3, 2026
NVD status
Received

Related CVEs from 2026

CVE-2026-142943In the Linux kernel, the following vulnerability has been resolved: ASoC: amd: acp3x-es83xx: Keep an owned codec device reference acpi_getCVE-2026-142944In the Linux kernel, the following vulnerability has been resolved: ASoC: amd: acp-es8336: Use an owned codec device reference acpi_get_fiCVE-2026-142945In the Linux kernel, the following vulnerability has been resolved: ASoC: amd: acp3x-es83xx: Switch to use acpi_bus_get_primary_device() RCVE-2026-142946In the Linux kernel, the following vulnerability has been resolved: ASoC: amd: acp-es8336: Switch to use acpi_bus_get_primary_device() RepCVE-2026-142947In the Linux kernel, the following vulnerability has been resolved: cxl/core: Skip einj_inject creation when devm_add_action_or_reset() faiCVE-2026-142948In the Linux kernel, the following vulnerability has been resolved: i2c: designware: queue only one read command for block reads i2c_dw_xfCVE-2026-142949In the Linux kernel, the following vulnerability has been resolved: tcp: fix NULL pointer dereference when restarting a Fast Open listener CVE-2026-142950In the Linux kernel, the following vulnerability has been resolved: nvme: fix deadlock on nvme_subsystems_lock in nvme_init_subsystem() CoCVE-2026-142951In the Linux kernel, the following vulnerability has been resolved: sctp: fix skb_over_panic when adding addresses with a pending delete ofCVE-2026-142952In the Linux kernel, the following vulnerability has been resolved: accel/ivpu: Defer recovery until probe completes An error IRQ that firCVE-2026-142953In the Linux kernel, the following vulnerability has been resolved: gpio: mpsse: reject bulk-in endpoints smaller than 3 bytes mpsse_read(CVE-2026-142954In the Linux kernel, the following vulnerability has been resolved: blk-mq: take quiesce_lock when removing a queue from the tag set Unqui
CVE-2026-142942: Unscored | Vulnix