Skip to main content
Mallory
HighCISA KEVExploited in the wildPublic exploit

WebKit memory corruption RCE in Apple iOS

IdentifiersCVE-2016-4657CWE-119

CVE-2016-4657 is a memory corruption vulnerability in WebKit on Apple iOS prior to 9.3.5. A remote attacker can trigger the flaw by luring a target to a crafted web site or malicious link, causing Safari/WebKit to process attacker-controlled content. The provided context states this bug was used as the initial browser-side vector in the 2016 "Trident" iOS exploit chain, where it enabled execution of shellcode in the Safari browser and was then chained with kernel vulnerabilities CVE-2016-4655 and CVE-2016-4656 to achieve a remote jailbreak and install Pegasus spyware.

Share:
For your environment

Are you exposed to this one?

Mallory correlates every CVE against your assets, your vendors, and active adversary campaigns. Know which vulnerabilities matter for you, not just which ones are loud.

ANALYST BRIEF

Impact, mitigation & remediation

What it means. What to do now. Patch path, mitigations, and the assume-compromise checklist.

Impact

What an attacker gets, and what they’ve been doing with it.

Successful exploitation can result in arbitrary code execution in the WebKit/Safari context or denial of service due to memory corruption. In the documented Trident chain, this initial code execution was used to bootstrap further exploitation of kernel vulnerabilities, ultimately enabling full device compromise, remote jailbreak, and installation of Pegasus surveillance malware on targeted iPhones.

Mitigation

If you can’t patch tonight, do this now.

If immediate patching is not possible, reduce exposure by restricting access to untrusted websites and links, especially SMS-delivered lure links, and limiting Safari/WebKit use on at-risk devices. Mobile threat detection, network monitoring for known Pegasus-related infrastructure, and heightened protections for high-risk users can reduce risk, but these are compensating controls only; patching to iOS 9.3.5 or later is the effective mitigation.

Remediation

Patch, then assume compromise.

Upgrade affected Apple iOS devices to iOS 9.3.5 or later. Apple released iOS 9.3.5 specifically to patch CVE-2016-4657 as part of the Trident vulnerability set. Standard remediation is to apply the vendor security update across all affected devices and retire unsupported versions where patching is not possible.
PUBLIC EXPLOITS

Exploits

2 valid exploits after Mallory filtered fakes, detection scripts, and README-only repos (1 hidden).

VALID 2 / 3 TOTALView more in app
webkit-vulnerabilityMaturityPoCVerified exploit

This repository contains a proof-of-concept (PoC) exploit for CVE-2016-4657, a memory corruption vulnerability in the WebKit JavaScript engine affecting iOS 9.3 and the Nintendo Switch captive portal browser. The main exploit is implemented in 'attack.html', which uses advanced JavaScript techniques to manipulate memory and trigger the vulnerability. The exploit is designed to be run in a browser environment, specifically targeting the Nintendo Switch's captive portal (which uses a WebKit-based browser) or vulnerable versions of iOS Safari. The 'index.html' file serves as a landing page that detects the Nintendo Switch user agent and redirects to the exploit. The 'README.md' provides a brief overview and references a technical article for further reading. The 'tuto.md' is a detailed technical write-up on JavaScript engine exploitation, not directly part of the exploit but useful for understanding the context. The exploit demonstrates the vulnerability by corrupting array lengths and alerting the user, and may cause the browser to crash, showing exploitability. No weaponized payload is included; this is a research PoC.

viai957Disclosed Nov 11, 2018javascripthtmlbrowser
SwitcherooMaturityPoCVerified exploit

This repository is a proof-of-concept (PoC) exploit for CVE-2016-4657, a WebKit vulnerability, targeting the Nintendo Switch's browser. The structure includes a minimal custom browser written in C++ (main.cpp) for Debian Linux, which simulates the Nintendo Switch user agent and loads an online exploit page. The main exploit logic is implemented in JavaScript (exploit/jailbreak.js) and is loaded via an HTML page (exploit/index.html). The exploit attempts to trigger a memory corruption bug in WebKit, resulting in a browser crash on the Nintendo Switch. The repository is intended for academic purposes and does not provide a persistent jailbreak or code execution, but demonstrates the feasibility of exploiting the vulnerability. The codebase includes supporting files for logging (exploit/logger.js) and styling (exploit/style.css). The only network endpoint directly targeted is the hosted exploit page (https://idan5x.github.io/Switcheroo/), which is loaded by the custom browser.

iDaN5xDisclosed Jun 2, 2017cppjavascriptbrowser
EXPOSURE SURFACE

Affected products & vendors

Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.

VendorProductType
AppleIphone Osoperating_system

Vendor-confirmed product mapping. Mallory continuously reconciles this list against your asset inventory.

What this page doesn’t show

The version that knows your environment.

This page is what’s public. Mallory adds the parts that aren’t: which of your assets are affected, which adversaries are exploiting it right now, which detections to deploy, and what to do tonight.
Exposure mapping

Query your assets running an affected version, and investigate the blast radius.

Threat actor evidence1

Every observed campaign linking this CVE to a named adversary.

Associated malware1

Malware families riding this exploit, with evidence and IOCs.

Detection signatures2

YARA, Sigma, Snort, and vendor rules, auto-deployed to your SIEM.

Vendor-by-vendor mapping

Cross-references every affected SKU, including bundled OEM variants.

Social activity

Community discussion across Reddit, Mastodon, and other social sources.

WebKit memory corruption RCE in Apple iOS (CVE-2016-4657) | Mallory