AI security

Uninstalling Isn't Cleaning Up: The Fake Claude Code Extension in Cursor's Marketplace

For about 11 hours on 29 October, Cursor's extension marketplace served tampered builds of Anthropic's Claude Code extension that plant an SSH backdoor. Removing the extension does not remove the backdoor. What to check, the controls, and the ISO 27001/NIS2 mapping.

Killswitch Issue 11: Uninstalling isn't cleaning up. Diagram: a tampered Claude Code extension in Cursor's marketplace leaves an SSH key, a reverse tunnel and startup entries behind.

Facts as of 2 Nov 2026.

On 29 October, Cursor told its users that its extension marketplace had been serving a "maliciously modified version" of Anthropic's Claude Code extension, versions 2.1.312 and 2.1.313 for macOS and Windows [1].

Cursor says the tampered builds were available for part of that day, roughly 11 hours by our arithmetic from the window in its notice (check your install logs against Cursor's exact times), and that they "were not developed by Anthropic" [1]. Microsoft, which analysed the code, adds that Anthropic confirmed its systems were not compromised and that the packages were never distributed through the Visual Studio Marketplace or npm [2].

The sentence in Cursor's notice that matters most for anyone who installed it is this one: "Uninstalling the extension may not be sufficient — the payload drops standalone persistence scripts that keep running." [1] Sophos puts it more bluntly: "Uninstalling the extension leaves the backdoor in place." [3]

Eleven hours in the marketplace
Eleven hours in the marketplace

What happened

A developer who installed or automatically updated to one of the two versions from Cursor's marketplace during that window got the real extension with a small loader added in front of it [2][9]. The loader runs as soon as the extension module loads. Nobody has to open a chat or click anything [2][9].

Cursor removed the version "immediately upon detection", then shut down the whole marketplace, audited access, rotated its keys, rebuilt the marketplace and brought it back online. It also worked with the hosting provider to take the attacker's server offline [1].

Sophos and StepSecurity report that Cursor estimated up to 5,000 users were affected [3][9]. That figure is not in Cursor's current notice, so treat it as Cursor's early estimate. Sophos also names only 2.1.313, while Cursor's updated notice names both versions [1][3].

What the loader does

Microsoft reconstructed the order from the injected code [2]:

  1. Recon. It collects the hostname, username, operating system, home and working directories, the Git email and the public IP [1][2]. It also collects the names of up to 40 environment variables that look like keys, tokens or passwords. Names, not values: Microsoft says this "does not demonstrate theft of the secrets stored in those variables" [2].
  2. Key and SSH. It adds an attacker-controlled key, labelled svc-telemetry, to the user's SSH authorized_keys file and tries to switch on the local SSH service (SSH is the standard remote-login protocol) [1][2].
  3. Tunnel. It opens an outbound "reverse" SSH tunnel to the attacker's server, so the attacker could come back in through it, and retries roughly every 60 seconds [1][2].
  4. Persist. It writes startup entries outside the extension folder: a LaunchAgent on macOS, a scheduled task with a Startup-folder fallback on Windows, and an @reboot cron entry on Linux [1][2].
  5. Report. A delayed callback sends the collected host details to the attacker [2].
What the loader does, in order
What the loader does, in order

There is one piece of luck. Switching on SSH needs admin rights, which the extension does not have on most macOS and Windows machines, and Cursor says errors in the malicious code make that step fail there. On those hosts "the attacker could not have logged in through the tunnel" [1].

But the key, the startup scripts and the host report are separate steps, and Cursor says those still happened [1]. Microsoft makes the same point: the loader "may still write keys and persistence artifacts even when tunnel access fails" [2]. That is why uninstalling is not cleaning up.

Is the key there?

Cursor publishes a short check for macOS and Windows that looks for the svc-telemetry key comment in the SSH authorised-keys files [1]. If the key is there, the machine is affected.

Microsoft adds a caveat worth repeating: confirm the key against the published fingerprint before you remove it, and "a missing marker alone should not replace review of the installation, process, network, and persistence evidence" [2]. We name this one indicator because Cursor and Microsoft publish it for exactly this purpose. For the full indicator list, use the vendor pages [1][2], not a copy.

Cursor's five steps, in short [1]:

If you installed it: check, then clean up
If you installed it: check, then clean up

Two details from the vendors are easy to miss. Preserve the evidence (the extension package, the modified key files, the scripts and the startup entries) before you clean up [2]. And rotate credentials from a trusted machine, not from the one you are cleaning: Cursor says the limited environment-variable collection "does not rule out later credential access over the backdoor" [1]. Cursor publishes remediation scripts for macOS and Windows; Microsoft advises reviewing them before use [1][2].

The controls that would have helped

Cursor's own guidance, which Microsoft also points to, gives you three controls [2][4][5]:

  • An allowlist of approved publishers. In Cursor, any entry in the allowed-extensions list blocks everything else unless you add "*": true [5]. Admins can push it to managed machines as the AllowedExtensions policy [8].
  • An install cooldown. Team admins can delay installs and updates until a marketplace version has been public for a set number of hours. The default is 0, which means off. A non-zero value applies fleet-wide and overrides each user's own setting [4].
  • Signature verification. Enterprise teams can require valid Open VSX extension signatures before install [4].

In our view, a cooldown of 12 hours or more would probably have kept these builds, live for about 11 hours, off machines that took them as automatic updates. That is our inference from the window and the documentation [1][4], not a vendor claim. A cooldown does not stop a malicious release that stays up longer than the delay. It removes the cheapest version of this attack: the short-lived upload.

We add a fourth control that none of the vendors names: an extension inventory. You cannot answer "did anyone install 2.1.312 or 2.1.313 from Cursor's marketplace that day?" in an hour unless you already know which developer machines run which extensions, at what version, from which marketplace.

Four controls that blunt the next one
Four controls that blunt the next one

Mapping it for GRC

  • ISO/IEC 27001:2022 [6]: supplier relationships and the ICT supply chain (A.5.19, A.5.21); installation of software on operational systems (A.8.19) and change management (A.8.32), which is where a cooldown and an allowlist sit; the inventory of assets (A.5.9) and privileged access (A.8.2); incident response and evidence (A.5.26, A.5.28); and learning from incidents (A.5.27) for the post-incident review. These are our mapping; check the control titles against your licensed copy.
  • NIS2 [7]: if you are an essential or important entity under NIS2, the anchors are Art. 21(2)(d), supply chain security, and (e), security in acquisition, development and maintenance, for the allowlist and cooldown; (i), access control and asset management, for the inventory; (b), incident handling, for the key check and rotation; and (c), business continuity and recovery, for rebuild decisions. Any notification duty under Art. 23 applies only if the incident is significant: an early warning within 24 hours, a notification within 72 hours, and a final report within one month of the incident notification (Art. 23(4)(d)) [7].
Where this lives in your frameworks
Where this lives in your frameworks

What we don't know yet

  • How the tampered builds got in. Cursor has not said publicly how they reached its marketplace or who was behind them [1]. Someone from Anthropic said publicly on Hacker News that "a malicious actor used access to Cursor's marketplace" to publish them [10][9], and another said 2.1.313 "was never published on OpenVSX, the VS Code marketplace, or on any of our official hosts" [11]. These are individuals' comments on Hacker News, not a formal company statement. Cursor has not confirmed it. Microsoft's ATT&CK mapping describes the code's behaviour and, in its own words, does "not establish attribution" [2].
  • Linux. Cursor lists no Linux build and publishes hashes only for macOS (darwin-arm64) and Windows (win32-x64), but the payload has a Linux code path: Cursor's indicators and Microsoft both describe a cron @reboot entry [1][2]. Check any Linux machine that could have side-loaded the package.
  • How many machines were really reached. The 'up to 5,000' figure is Cursor's estimate as reported by Sophos and StepSecurity [3][9]; it is not in Cursor's current notice. No source says how many hosts actually ran SSH with admin rights.

Your checklist for this week

  • Find every machine that runs Cursor, and check whether it installed or updated the Claude Code extension from Cursor's marketplace on 29 October.
  • On those machines, run Cursor's key check, preserve evidence, then follow its five steps [1].
  • Rotate credentials those machines could reach, from a clean machine.
  • Set an extension allowlist and a non-zero install cooldown for your Cursor team [4][5].
  • Start an extension inventory, and record the settings and the review as evidence.

Download the slides

Use this issue in your next team briefing. The slides are free to download:

Keep going

About the author. Emmanuel Aigbehi Walstra is a CISO who also serves as a virtual CISO (vCISO) for several organisations, with 30+ years in cybersecurity, 10,000+ people trained, and author of the CCSP Excellence books.

Sources

  1. Cursor: Security notice, malicious version of Anthropic.claude-code (2.1.312 and 2.1.313) in the Cursor VS Code Extension Marketplace (29 Oct 2026, updated 30 Oct)
  2. Microsoft Security Blog: Inside a malicious Claude Code-branded extension and its persistent SSH backdoor (30 Oct 2026)
  3. Sophos X-Ops: Malicious Claude Code extension distributed through Cursor marketplace
  4. Cursor Help: Extensions (marketplace install cooldown, allowed extensions, signature verification)
  5. Cursor Docs: Security and Privacy Hardening
  6. ISO/IEC 27001:2022 Information security management systems
  7. NIS2 Directive (EU) 2022/2555, Articles 21 and 23
  8. Cursor Docs: Deployment Patterns (AllowedExtensions policy)
  9. StepSecurity: Trojanized Claude Code Extension Delivered Persistent SSH Backdoor to Developer Machines (30 Oct 2026, updated 1 Nov)
  10. Hacker News: comment by Felix Rieseberg (felixrieseberg, self-identified as from Anthropic), item 50304129 (30 Oct 2026)
  11. Hacker News: comment by David Dworken (ddworken, self-identified as from Anthropic), item 50305148 (30 Oct 2026)

Facts are from Cursor's security notice and Microsoft's analysis, with Sophos and StepSecurity where stated, as published by 2 Nov 2026. How the tampered builds got into the marketplace has not been fully disclosed. The cooldown reasoning, the extension inventory control and the framework mapping are Killswitch's own.

Checked against the primary sources cited above. Spotted an error? See our corrections page.