Commit 2282fc11 authored by kevenny hsieh's avatar kevenny hsieh Committed by Treehugger Robot
Browse files

ANDROID: gzvm driver: fix UAF issue



When a VM is destroyed, it also triggers the destruction of its
associated vCPUs. However, this process can potentially result
in use-after-free issue. To address this, we add kref (kernel
reference counter) to trace the  userspace events. Once the
vCPU is destroyed, gzvm release all the resources.

(e.g. Open VM_FD -> Open VCPU_FD -> Close VM_FD -> VCPU_RUN)

Bug: 444329675
Signed-off-by: default avatarkevenny hsieh <kevenny.hsieh@mediatek.com>
Signed-off-by: default avatarLiju Chen <liju-clr.chen@mediatek.com>
Change-Id: Idb7dd29da2515500ff4348940478443085bded4e
parent 9e3a0161
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment