WebKit JavaScriptCore Type Confusion Leading to Arbitrary Code Execution
CVE-2021-1789 is a type confusion vulnerability in WebKit that permits arbitrary code execution when maliciously crafted web content is processed. Technical analysis attributes the flaw to JavaScriptCore property enumeration during for...in loops: a Proxy getPrototypeOf callback can mutate the base object's layout while enumeration metadata is being collected, without subsequent validation of the final structure-property count. The optimized property-access path then uses stale enumeration metadata and inline-capacity assumptions, producing an out-of-bounds read that can be developed into a use-after-free primitive. Successful exploitation was demonstrated on WebKitGTK 2.30.5 and equivalent WebKit versions. Apple addressed the vulnerability through improved state handling.
What it means and what to do now: patch path, interim mitigations, and the assume-compromise checklist.
What an attacker gets, and what they’ve been doing with it.
Processing attacker-controlled web content can execute arbitrary code in the vulnerable WebKit execution context. Exploitation has been associated with watering-hole attacks that achieved in-memory execution of native macOS code. In the DazzleSpy infection chain, a separate vulnerability, CVE-2021-30869, subsequently provided root privileges; root access and the backdoor's surveillance capabilities are not direct effects of CVE-2021-1789 alone. The identification of the campaign's initial WebKit vulnerability as CVE-2021-1789 remains uncertain in some analyses.
If you can’t patch tonight, do this now.
Until patching is complete, reduce exposure to untrusted web content in Safari and other affected WebKit-based applications, especially for high-risk users. Restrict browsing to trusted sites, disable or limit JavaScript where operationally feasible, and use platform/browser hardening and application control to reduce post-exploitation impact. Monitor for suspicious Safari/WebKit crashes and signs of exploit chaining with local privilege-escalation vulnerabilities. These are only partial mitigations and do not eliminate the underlying flaw.
Patch, then assume compromise.
Install the applicable fixed release or a later supported release: macOS Big Sur 11.2, Security Update 2021-001 Catalina, Security Update 2021-001 Mojave, tvOS 14.4, watchOS 7.3, iOS 14.4, iPadOS 14.4, or Safari 14.0.3. The fix improves WebKit state handling. A fixed WebKitGTK release is not specified.
No public exploits tracked yet. Mallory keeps watching.
Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.
6 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.