Back

HIGH

idpf: fix double free and use-after-free in aux device error paths

Published Jun 26, 2026

Description

When auxiliary_device_add() fails in idpf_plug_vport_aux_dev() or idpf_plug_core_aux_dev(), the err_aux_dev_add label calls auxiliary_device_uninit() and falls through to err_aux_dev_init. The uninit call will trigger put_device(), which invokes the release callback (idpf_vport_adev_release / idpf_core_adev_release) that frees iadev. The fall-through then reads adev->id from the freed iadev for ida_free() and double-frees iadev with kfree().

Free the IDA slot and clear the back-pointer before uninit, while adev is still valid, then return immediately.

Commit 65637c3a1811 ("idpf: fix UAF in RDMA core aux dev deinitialization") fixed the same use-after-free in the matching unplug path in this file but missed both probe error paths.

Affected products

Remediation

No remediation recorded yet.

Weaknesses (2)

References (9)

Change history (0)

No recorded changes yet.

Sources

CVE.org / MITRE

Status PUBLISHED
Assigner Linux
Published Jun 26, 2026
Updated Jun 26, 2026
Reserved Jun 9, 2026

CISA Vulnrichment

No data

NVD

Status Analyzed
Modified Jul 8, 2026

Red Hat

Severity Moderate
Public date Jun 26, 2026
Bugzilla 2493742

ENISA EUVD

Assigner Linux
Published Jun 26, 2026
Updated Jun 26, 2026

GitHub

No data