CVE-2021-39793
High · 7.8 CISA KEVCVSS
7.8
EPSS
0.7%
Published
Mar 16, 2022
CISA due date
May 2, 2022
Cloudanix analysis
A malicious app on an unpatched Android device could abuse a graphics driver flaw to take powerful control of the device without the user doing anything.
- Exploitation
- Local Privilege
- Attacker needs
- Low Privilege
- Complexity
- Low
- Impact
- Privilege Gain
- Component
- OS kernel
- Class
- Memory Corruption
- Remediation
- Upgrade
- Effort
- Medium
- Patch risk
- Low
What it actually does
CVE-2021-39793 is a local privilege escalation vulnerability in the Android kernel implementation of the Arm Mali GPU driver. A logic error in kbase_jd_user_buf_pin_pages in mali_kbase_mem.c can cause an out-of-bounds write while handling user-supplied GPU memory pinning operations. A local app or process with access to the vulnerable GPU driver interface can corrupt kernel memory and potentially gain elevated kernel-level privileges. Because exploitation requires only local code execution, low privileges, and no user interaction, successful exploitation can provide high confidentiality, integrity, and availability impact on affected Android devices.
Why it matters to the business
Successful exploitation can allow a malicious application already running on an affected Android device to take control of the device at a privileged level, bypass app sandboxing, access sensitive data, tamper with system behavior, install persistent malware, or disable security controls. This vulnerability is listed in CISA KEV and has been exploited in the wild, with a remediation due date of 2022-05-02, so unpatched affected devices should be treated as higher-risk even though the EPSS score is relatively low. Organizations with large Android fleets may face increased risk of targeted spyware, device compromise, data leakage, and operational disruption if kernel security updates are delayed.
How an attack unfolds
An attacker first needs code execution on the Android device, typically through a malicious app, a chained browser or messaging exploit, or another foothold that provides a local unprivileged process. The attacker then interacts with the vulnerable Mali GPU kernel driver interface and triggers the flawed memory pinning path in kbase_jd_user_buf_pin_pages. By carefully shaping GPU memory operations, the exploit causes an out-of-bounds kernel memory write. If the corruption is controlled successfully, the attacker can modify kernel data structures or process credentials to elevate privileges. In real-world attacks, this type of bug is often chained with an initial remote code execution or sandbox escape to move from app-level access to full device compromise. The vulnerability has been observed in active exploitation and is tracked in the Known Exploited Vulnerabilities catalog, indicating operational use by attackers against Android devices.
How to fix it
Apply the vendor-provided Android security update containing the fix for Android ID A-210470189. Because no specific fixed version was provided in the input, remediation should be based on the Android security bulletin and device OEM patch level that includes the March 2022 Android kernel/Mali GPU driver fix or later. Prioritize updates for devices using Arm Mali GPU kernel drivers and any devices that remain on security patch levels older than the vendor bulletin that remediated this issue. Where immediate patching is not possible, reduce exposure by restricting installation of untrusted applications, enforcing enterprise mobile device management controls, disabling sideloading, requiring Play Protect or equivalent app vetting, and isolating or replacing devices that no longer receive kernel security updates. Mitigations should not be treated as equivalent to patching because the flaw is in kernel driver code and has known in-the-wild exploitation.
How to confirm the fix worked
Confirm that affected Android devices have received an OEM or platform security update that includes the fix for Android ID A-210470189 and are running an Android security patch level at or after the bulletin containing the remediation. Validate device patch status through MDM inventory, Android Settings security patch level, OEM firmware build information, or enterprise device compliance reporting. For engineering validation, confirm the vulnerable Mali kernel driver source or binary has been updated so that the flawed kbase_jd_user_buf_pin_pages logic is no longer present. Where possible, compare kernel build fingerprints and GPU driver versions against OEM advisories. Devices that cannot be updated to a fixed patch level should be considered exposed and handled through compensating controls or retirement.
Typical attack path
- Obtain local code execution on an affected Android device, such as through a malicious app or exploit chain.
- Confirm access to the vulnerable Mali GPU kernel driver interface exposed to local processes.
- Trigger the vulnerable kbase_jd_user_buf_pin_pages memory handling path with crafted GPU memory operations.
- Cause an out-of-bounds write in kernel memory due to the logic error.
- Use memory corruption to alter privileged kernel state or bypass Android application sandbox restrictions.
- Escalate privileges and execute follow-on actions such as data theft, surveillance, persistence, or disabling security protections.
How to detect it
Detection is difficult because this is a kernel-level local privilege escalation and successful exploitation may leave few reliable artifacts. Review Android kernel logs, crash reports, MDM telemetry, mobile EDR alerts, and application installation history for suspicious activity around the time of suspected compromise. Look for kernel oops, panic, or memory access violations involving Mali, kbase, GPU memory handling, or /dev/mali device access, especially followed by unexpected privilege changes, root-like behavior, disabled security controls, unknown persistent apps, or abnormal data access. Examine logs for untrusted or recently installed applications accessing GPU driver interfaces shortly before crashes or privilege anomalies. If available, correlate with mobile threat intelligence for spyware or exploit-chain campaigns targeting Android devices. Because this issue has known in-the-wild exploitation, absence of logs should not be used to rule out compromise; prioritize patch validation and forensic review of high-risk devices.
- kbase_jd_user_buf_pin_pages
- mali_kbase_mem.c
- /dev/mali0
- /dev/mali
- mali_kbase
- kbase
- Mali
- Unable to handle kernel paging request
- kernel panic
- Oops
- BUG: kernel NULL pointer dereference
- A-210470189
What your security team should do
- Prioritize patching or replacement of affected Android devices because the vulnerability is in CISA KEV and has known active exploitation.
- Use MDM or endpoint inventory to identify Android devices with security patch levels older than the vendor update that fixed Android ID A-210470189.
- Block or tightly control sideloaded applications and unknown app sources, especially on devices that cannot be immediately patched.
- Review mobile threat defense, EDR, and MDM telemetry for signs of kernel crashes, suspicious app behavior, privilege escalation attempts, or unexpected root-level activity.
- Treat compromise of an unpatched device as plausible if it was exposed to high-risk applications, phishing, spyware campaigns, or prior exploit-chain indicators.
- Retire or isolate Android devices that no longer receive OEM kernel security updates.
- Monitor threat intelligence for Android exploit chains involving Mali GPU driver privilege escalation and update detection logic as new indicators become available.
The record
In kbase_jd_user_buf_pin_pages of mali_kbase_mem.c, there is a possible out of bounds write due to a logic error in the code. This could lead to local escalation of privilege with no additional execution privileges needed. User interaction is not needed for exploitation.Product: AndroidVersions: Android kernelAndroid ID: A-210470189References: N/A
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| Android | :unknown: | Pixel-family specific:0 | Pixel-family specific:2022-03-05 |
Related vulnerabilities
- CVE-2026-0106 In vpu_mmap of vpu_ioctl, there is a possible arbitrary address mmap due to a missing… Also affects :unknown:
- CVE-2025-36938 In U-Boot of append_uint32_le(), there is a possible fault injection due to a logic error… Also affects :unknown:
- CVE-2025-20791 In Modem, there is a possible system crash due to incorrect error handling. Also affects :unknown:
- CVE-2025-20757 In Modem, there is a possible system crash due to improper input validation. Also affects :unknown:
- CVE-2025-20751 In Modem, there is a possible system crash due to a missing bounds check. Also affects :unknown:
- CVE-2025-20752 In Modem, there is a possible system crash due to a missing bounds check. Also affects :unknown:
- CVE-2025-20750 In Modem, there is a possible system crash due to improper input validation. Also affects :unknown:
- CVE-2025-20756 In Modem, there is a possible system crash due to a logic error. Also affects :unknown: