Cursor's Claude Extension Incident: Package Trust and SSH Persistence
An evidence-led analysis of the October 29 Cursor marketplace compromise: tampered VSIX provenance, JavaScript execution, SSH persistence, detection confidence and extension supply-chain controls.
Approximately 11 min read
On October 29, 2026, a malicious copy of the Claude Code editor extension was distributed through the Cursor VS Code Extension Marketplace. The public record is unusually useful for security engineering: the distributor issued a version- and platform-specific incident notice, and Microsoft Security Research independently analyzed the injected JavaScript. Together they reveal an attack that required neither an AI prompt nor a model jailbreak. An extension that looked like a normal update ran code in the developer workstation’s extension host and attempted to establish persistent SSH access.
The engineering lesson is not simply to distrust plugins. It is that a familiar extension identifier, a trusted publisher name, a version number and the bytes installed on a machine are four different assertions. A safe software supply chain must connect them, then verify the runtime effects of the installed artifact. This article audits that boundary, distinguishes observed code from confirmed compromise, and proposes a measurable defense-in-depth program. The analysis is based on public disclosures, not independent malware execution.
What the October 29–30 evidence establishes
Cursor’s incident notice, published October 29 and updated October 30 at 11:30 a.m. Pacific, identifies Anthropic.claude-code versions 2.1.312 and 2.1.313 served from its marketplace for macOS and Windows. The stated distribution window was approximately 2:27 a.m. to 1:35 p.m. Pacific on October 29—11 hours and eight minutes. Cursor estimates that at most 5,000 users were affected. This is a potential-exposure upper bound, not evidence that 5,000 devices were controlled by an attacker.
Cursor says the malicious packages were not developed by Anthropic. Microsoft’s October 30 analysis reports that the affected packages were not distributed by Microsoft’s Visual Studio Marketplace or the official Claude Code npm distribution. Microsoft also says Anthropic confirmed its own systems were not compromised. Those statements establish a distribution boundary; they do not identify the person who uploaded the packages or explain how marketplace access was obtained. No responsible attribution is possible from the published evidence.
Cursor reports removing the affected packages, briefly shutting down the marketplace, auditing for other altered extensions, rotating its keys, rebuilding the marketplace and coordinating the takedown of the attacker-controlled server. These are vendor-reported containment actions. Their completion does not retroactively clean persistence files from workstations that executed the loader.
There is a platform-scope nuance. Cursor’s updated notice publishes malicious darwin-arm64 and win32-x64 VSIX hashes and its explicit user action targets macOS and Windows. Microsoft’s code analysis also describes a Linux crontab persistence branch. A Linux code path in the payload is not equivalent to verified distribution of a malicious Linux VSIX. Teams should examine their own installation records before extending the confirmed package scope.
The trust boundary: marketplace identity is not artifact integrity
A VS Code-style extension has a publisher and extension identifier, version metadata, package contents and a JavaScript entry point. Users see a recognizable identity; the editor ultimately executes installed bytes. If a distribution path can serve different bytes under a trusted identity, an update becomes a code-execution channel.
Microsoft reports that a malicious function was placed before the extension’s expected initialization. That matters more than the AI branding. Once the module loads, the injected JavaScript can use Node.js APIs to read local metadata, write files and launch system processes. The legitimate extension can continue working, making an ordinary functional check a weak detection method.
Consider a four-column provenance ledger for each approved extension:
| Assertion | Evidence to preserve | What it cannot prove alone |
|---|---|---|
| Publisher identity | Marketplace identity and approved publisher | The downloaded bytes came from an untampered release |
| Version identity | Extension ID, semantic version and platform | Two marketplaces serve the same artifact |
| Artifact integrity | SHA-256 of the actual VSIX and verified signature where supported | The signed or hashed code is behaviorally safe |
| Runtime authorization | Extension-host process, filesystem and network telemetry | An apparently normal UI means no malicious side effects |
This separation explains why a publisher allowlist alone would not have resolved this incident: the attack used a recognizable extension identity. Conversely, a known-good artifact hash from an independently controlled distribution path could detect a mismatched package even if its displayed publisher and version looked normal.
Cursor publishes four distinct VSIX SHA-256 values, one for each of two versions on two affected platforms. The hashes are in its IOC section. Microsoft’s hash of the injected extension.js entry point is not a VSIX package hash. Treating the two types interchangeably would produce false negatives during incident response. The same version string is insufficient to select a hash without knowing the operating-system artifact.
Five-stage loader, five different confidence levels
Microsoft reconstructs the loader in this order: collect host details; append an SSH authorization key; attempt to enable SSH and create an outbound reverse tunnel; write startup persistence; and send delayed reconnaissance. This is an analysis of the code’s intended and attempted actions, not proof that every stage succeeded on every host.
Reconnaissance. The loader collected hostname, username, OS, architecture, home and working directories, configured Git email and public IP. It also identified up to forty environment-variable names matching patterns associated with secrets. Microsoft explicitly distinguishes those names from environment-variable values. Reporting that the loader automatically stole all cloud credentials would exceed the evidence. Successful later SSH access could create additional exposure, but that requires separate investigation.
SSH authorization. The payload checked for the marker svc-telemetry in an SSH authorized_keys file and attempted to append an embedded public key. A public key in that file grants potential authentication to the holder of the corresponding private key, subject to the host’s SSH configuration. It is a persistence artifact even when no inbound connection succeeds.
Outbound tunneling. A different embedded identity was used to authenticate an outbound SSH session to an attacker server and request remote port forwarding to the workstation’s local SSH port. These are separate trust decisions: authorizing a key on the workstation and authenticating the workstation’s outbound tunnel are not the same event. An egress-capable host might establish a tunnel even without any inbound firewall rule. Yet a tunnel process by itself does not prove that an attacker logged into the workstation; local SSH availability, remote-server forwarding policy and authentication still matter.
Startup persistence. The analyzed code generated platform-specific scripts outside the extension folder. Microsoft’s list includes a macOS LaunchAgent named com.apple.sysmond.plist, Windows task/Startup-folder mechanisms using SysMon-like names, and a Linux user-crontab @reboot branch. The names imitate system monitoring components. A written startup file does not guarantee the operating system executed it, but it also will not disappear merely because the extension is uninstalled.
Reporting. A delayed callback attempted an HTTP POST to a remote /beacon endpoint on port 8099. Cursor reports the hosting provider took the server offline. This limits that destination’s present usefulness, not the possibility that data was transmitted while it was active or that residual host artifacts remain.
Cursor states that coding errors and administrator-permission requirements blocked SSH service enablement on most macOS and Windows machines. This is a reduction in demonstrated remote-access success, not a clean bill of health: the loader could still modify authorization files, create persistence and attempt reconnaissance reporting.
A practical investigation matrix
An incident responder should answer four different questions instead of asking only whether the extension is installed now.
| Question | High-value evidence | Caution |
|---|---|---|
| Was a targeted artifact delivered? | Marketplace origin, installation time, platform, extension ID/version and matching VSIX hash | Version alone does not establish malicious bytes |
| Did the injected code run? | Extension-host process ancestry, relevant file writes and the malicious key marker/fingerprint | An installed package might never have been loaded |
| Did persistence survive? | Unauthorized SSH key, macOS LaunchAgent, Windows task/Startup entry or Linux crontab, correlated with timestamps | Filenames can collide with benign artifacts |
| Was remote access or credential exposure achieved? | SSH authentication records, process/network telemetry, subsequent commands and sensitive-resource access | A beacon or tunnel attempt alone is not proof of interactive access |
Use Cursor’s platform-specific checks and remediation guidance as the authoritative starting point, but preserve evidence before deleting artifacts. For example, the key marker svc-telemetry is a triage lead; verify the actual key fingerprint before removing an entry, because a string match alone is weaker evidence. Microsoft publishes additional file, process and network indicators and example Defender hunting queries. Those queries are leads to investigate, not an automatic verdict.
For confirmed affected machines, the vendor recommends isolation, removal of the unauthorized key and persistence mechanisms, termination of malicious processes, and consideration of rebuilding the workstation. Review credentials and sessions accessible from the host, and rotate or revoke them from a trusted device when exposure is indicated or host trust cannot be restored. Simply upgrading or uninstalling the extension does not remove standalone scripts created outside its installation directory.
Do not indiscriminately delete all SSH keys, all LaunchAgents or all tasks with monitoring-related names. Preserve legitimate developer access, retain forensic context and verify the malicious key or command action first. In enterprise response, coordinate remediation with the device owner and incident team.
Why extension controls need multiple independent layers
The official VS Code extension security documentation makes a crucial point: an extension host generally runs with the editor’s own operating-system permissions. Extension code can access files, make network requests and launch processes. A prompt-injection filter or model policy cannot police JavaScript that runs before the AI assistant is even invoked.
A defensible program uses several complementary controls:
- Publisher and extension allowlists reduce exposure to unexpected software, but cannot by themselves stop a poisoned version under an approved ID. The enterprise extension policy supports specific versions and platforms. Test how your chosen editor enforces such policies, rather than assuming VS Code policy behavior is identical in every fork.
- Artifact provenance and signature checks bind an install to package bytes and a verified distribution identity. Microsoft’s marketplace documentation describes signed Visual Studio Marketplace packages. A signature only helps when the client actually validates it and trusts the correct signing authority; it does not certify that signed code is benign.
- Update delay creates time for malicious short-lived releases to be removed. VS Code documents a default extension auto-update delay of twelve hours when its delay mechanism is enabled; this incident’s stated distribution window was about eleven hours. That comparison is a hypothesis for a controlled rollout test, not proof that a twelve-hour policy would have prevented every install. Manual updates, installation timing, clients and marketplace behavior are confounders.
- Least-privilege developer sessions limit the impact of an extension attempting system-service changes. They do not eliminate user-level SSH-key modification or user-level persistence.
- Endpoint telemetry and controlled egress address the consequences of a compromised package. Correlate extension-host child processes, SSH authorization changes, startup entries and unusual outbound SSH or beacon traffic. Avoid overblocking legitimate remote development without inventory and exceptions.
- A recoverable package inventory records origin, version, platform and hash per device, with an emergency deny/update path. This enables a scoped incident response instead of treating all users of the legitimate extension as compromised.
The strongest generalization is distribution-path separation. A package legitimately released in one marketplace is not automatically identical to a package with the same ID and version served through another. Enterprises need to know which marketplace delivered which bytes, not merely which brand appears in an extensions panel.
A falsifiable validation plan without executing malware
A security team can test these controls safely with an internally built, harmless extension that writes a benign marker to a temporary test directory. Publish two distinct test artifacts with the same displayed version through two isolated test distribution channels; use no real credentials, external network destination or malicious payload.
Measure whether the client records the artifact SHA-256 and origin, whether version/platform allowlisting rejects an unapproved test package, whether signature validation detects altered bytes, whether update cooldown delays installation, and whether endpoint telemetry attributes the benign marker write to the extension host. Repeat with auto-update enabled, disabled and manual installation. Report the exact editor version, operating system, package hashes, policy configuration and observed outcomes.
This test does not reproduce the Cursor compromise and must not be presented as proof of its root cause. It tests the general control boundary exposed by the incident. A useful negative result is a client that enforces an extension ID allowlist yet silently accepts different bytes under that same identity.
What remains unknown
Public evidence does not establish how the attacker gained the ability to distribute the tampered packages, whether any developer workstation was used to move laterally, how many of the potentially exposed devices actually executed the loader, or how many interactive SSH sessions succeeded. Neither the incident notice nor the independent code analysis supports attributing the attack to Anthropic or to a named threat actor. These uncertainties matter because they determine whether a marketplace-side fix, endpoint cleanup or a wider incident investigation is required.
Bottom line: this was a software distribution and workstation-execution problem carrying an AI product’s name. The response should combine verified artifact provenance, constrained extension installation, host-level detection and incident-specific cleanup. Calling it a model escape would misidentify the entry point and lead defenders toward the wrong control.
Evidence and method
Primary references are Cursor’s October 29 notice, updated October 30, Microsoft Security Research’s October 30 injected-code analysis, the VS Code extension runtime-security documentation, VS Code marketplace controls and enterprise extension policy documentation. Sophos’s advisory independently corroborates the high-level incident scope and cleanup requirement. All attacker behavior described here is sourced from public vendor/researcher analysis; RAMGPT did not obtain or run the malicious VSIX, inspect any affected private machine, measure prevalence or independently validate the attacker’s infrastructure.
Sources and further reading
- cursor.com · claude code extension security notice
- microsoft.com · inside malicious claude code branded cursor extension persistent ssh backdoor
- code.visualstudio.com · extension runtime security
- code.visualstudio.com · extension marketplace
- code.visualstudio.com · extensions
- sophos.com · malicious claude code extension distributed through cursor marketplace