CyberRota Analysis
AI-GeneratedThe vulnerability affects the Linux kernel's RDMA/rxe component, specifically in the handling of user memory registration, where a use-after-free (UAF) condition can occur due to improper error handling. This flaw could lead to potential memory corruption or arbitrary code execution, posing a significant risk to systems utilizing RDMA functionality. Organizations relying on Linux systems with RDMA capabilities should prioritize this vulnerability to mitigate the associated security risks.
Original NVD Description
In the Linux kernel, the following vulnerability has been resolved: RDMA/rxe: Fix UAF in ODP init error-handling path rxe_odp_mr_init_user() stores &umem_odp->umem in mr->umem before calling rxe_odp_init_pages(). If rxe_odp_init_pages() fails, rxe_odp_mr_init_user() releases umem_odp and returns an error. rxe_reg_user_mr() then unwinds the error through rxe_cleanup(), rxe_mr_cleanup(), ib_umem_release(mr->umem). There is an IS_ERR_OR_NULL(umem) check at the start of ib_umem_release(). But since mr->umem is NOT reset to NULL in the error handling path of rxe_odp_mr_init_user(), the check passes and it reads already-freed fields like umem->is_dmabuf, causing UAF. Fix the UAF by clearing mr->umem after releasing the failed ODP umem so the MR cleanup path does not release it again.