CVE-2021-47200: drm/prime: Fix use after free in mmap with drm_gem_ttm_mmap
In the Linux kernel, the following vulnerability has been resolved:
drm/prime: Fix use after free in mmap with drm_gem_ttm_mmap
drm_gem_ttm_mmap() drops a reference to the gem object on success. If
the gem object's refcount == 1 on entry to drm_gem_prime_mmap(), that
drop will free the gem object, and the subsequent drm_gem_object_get()
will be a UAF. Fix by grabbing a reference before calling the mmap
helper.
This issue was forseen when the reference dropping was adding in
commit 9786b65bc61ac ("drm/ttm: fix mmap refcounting"):
"For that to work properly the drm_gem_object_get() call in
drm_gem_ttm_mmap() must be moved so it happens before calling
obj->funcs->mmap(), otherwise the gem refcount would go down
to zero."
Security readout for executives and security teams
Plain-English summary
CVE-2021-47200 is a Linux kernel graphics memory bug. In a specific DRM PRIME mmap path, the kernel could free a graphics memory object and then use it again. The sources do not provide CVSS severity, active exploitation evidence, or a vendor workaround beyond the referenced kernel fixes.
Executive priority
Handle through normal kernel patch governance unless your environment gives untrusted users or workloads local graphics device access. There is not enough source evidence to justify emergency action, but kernel memory-safety fixes should not be deferred indefinitely.
Technical view
The flaw is a use-after-free in drm_gem_prime_mmap() when calling drm_gem_ttm_mmap(). If the GEM object refcount is 1, drm_gem_ttm_mmap() can drop the last reference on success, then a later drm_gem_object_get() touches freed memory. The fix takes a reference before calling the mmap helper.
Likely exposure
Exposure is limited to systems running affected Linux kernel builds with the vulnerable DRM/TTM PRIME mmap behavior. The source bundle identifies Linux kernel versions and commits, but does not provide distribution package mappings or complete affected product detail.
Exploitation context
The source bundle marks KEV as false and provides no cited evidence of active exploitation or public weaponization. Treat exploitability as unconfirmed from the available evidence, while recognizing use-after-free bugs in kernel code can be security-relevant.
Researcher notes
Key review point is reference lifetime ordering around drm_gem_prime_mmap(), drm_gem_ttm_mmap(), and drm_gem_object_get(). The original regression is tied to commit 9786b65bc61ac, and the upstream stable references show the fix strategy: acquire a GEM object reference before the mmap helper can drop one.
Mitigation direction
Check your Linux distribution advisory for CVE-2021-47200 coverage.
Update kernel packages to builds containing the referenced stable fixes.
Prioritize systems exposing local GPU/DRM access to untrusted users or workloads.
Track vendor backports instead of relying only on upstream version numbers.
Validation and detection
Inventory running kernel versions across Linux hosts.
Map installed kernel packages to distribution CVE advisories or changelogs.
Confirm the DRM PRIME mmap fix is present in vendor source or patch notes.
Document that KEV status is false as of the supplied source bundle.
Reassess if vendor severity or exploitation guidance changes.
Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cve · low confidence lookup
CVE-2021-47200 mapping review
Open the CVE-to-ATT&CK bridge for reviewed, inferred, or future official mappings tied to this CVE.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.
0CVSS vectors
3Timeline events
2ADP providers
3Source links
SSVC decision data
CISA-ADPCISA Coordinator
Timestamp
Version
2.0.3
Exploitation: noneAutomatable: noTechnical Impact: total
Vulnerability timeline
Timeline events are normalized from CVE metadata, CNA source timelines, ADP timelines, and KEV metadata when present.
CVE reservedCVE Program
The CVE ID was reserved by the assigning CNA.
CVE publishedCVE Program
The CVE record was published.
Apr 10, 2024, 18:56 UTC (UTC+00:00)
CVE updatedCVE Program
The CVE record metadata indicates this as the latest update time.