Malicious Claude Code Extension in Cursor: Check Your Machines and Lock Down VS Code Fork Extensions
For about 11 hours on October 29, Cursor's extension marketplace served a tampered build of Anthropic's Claude Code extension that tried to install SSH backdoors. This guide covers how to check affected machines and how to control extensions in Cursor and other VS Code forks across a developer fleet.
On October 29, 2026, Cursor's own VS Code Extension Marketplace served a malicious build of Anthropic's official Claude Code extension. The tampered builds tried to plant persistent SSH backdoors on developer machines. Teams that still treat IDE extensions as a matter of personal taste may want to rethink that. After this incident, we suggest extensions belong in the supply chain conversation.
This guide has two parts. First, a triage playbook for finding affected installs and deciding whether to clean up or reimage. Second, fleet controls for extensions in Cursor and other VS Code forks, with a frank account of what each one stops and what it doesn't.
What happened in Cursor's extension marketplace on October 29
According to Cursor's security notice, a maliciously modified version of Anthropic's Claude Code extension was available in the Cursor VS Code Extension Marketplace between about 2:27am PT and 1:35pm PT on October 29.
Cursor's later incident update puts the exposure at no more than 5,000 users who requested those specific cached versions that day, with the build live for approximately 11 hours before removal. BleepingComputer describes the malware as installing persistent SSH backdoors.
The distribution channel shapes your investigation. SecurityWeek reports that Anthropic did not develop the modified versions and that neither was pushed to the Microsoft Visual Studio Marketplace, Open VSX or the npm registry. The problem sat in Cursor's cache. Anthropic jumped its legitimate extension straight to version 2.1.314 to avoid confusion.
Cursor believes the incident is contained. The last attacker activity it saw was on November 1, and it was blocked.
How the payload worked, and why uninstalling won't fix it
StepSecurity's analysis calls the tampering a pure prepend. Take the clean Open VSX 2.1.312 extension.js, splice a single 7,386-byte loader onto the front, and you have the malicious file. Everything after the loader is official code, so a casual look at the extension shows nothing odd.
StepSecurity also published indicators you can hunt with: a SHA-256 hash for the malicious extension.js and a file size of 3,692,922 bytes, roughly 7 KB larger than the previous clean release.
| Indicator | Value |
|---|---|
| File | extension.js in the tampered Claude Code build |
| SHA-256 | ecb58cb29078d9646ad1dcdbe51526f2d9cfea06be5fb2ab183e8ecc3ab6bf15 |
| Size | 3,692,922 bytes |
| Loader | 7,386 bytes prepended to the clean code |
Sandbox telemetry showed the payload running under plain Node.js with no VS Code APIs. Loading the extension module was enough. Nobody had to click anything or open a Claude Code panel.
Cursor's own warning is the one to take most seriously: uninstalling the extension may not be sufficient, because the payload drops standalone persistence scripts that keep running. Removing the extension gets rid of the delivery vehicle. The implant stays.
macOS sets a trap for responders. Phorion's advisory found that the systemsetup -getremotelogin command, run as a standard user, prints an administrator-access error and exits with status 0 rather than returning Off. In practice that bug often stopped the malware from actually enabling SSH, but keys and persistence could still land. So a Mac with Remote Login switched off has not been cleared.
Triage playbook: checking a machine for the poisoned build
Go through these steps in order. They assume a security or platform team, though a developer can run them on their own laptop.
Step 1: Scope the population
Start with every machine running Cursor. We suggest using MDM inventory, endpoint telemetry or plain self-reporting to flag machines where the Claude Code extension was installed or updated during the exposure window described above. Machines set to auto-update extensions need a look even if the developer remembers no update. The window is in Pacific time, so convert before you read logs.
Step 2: Check versions, hashes and timestamps
Look for Claude Code extension folders that were installed or updated in the exposure window. Check wherever Cursor stores extensions for every user profile, plus any custom extension directory, then hash each extension.js you find:
# macOS or Linux
shasum -a 256 path/to/extension.js
ls -l path/to/extension.js
# Windows PowerShell
Get-FileHash path\to\extension.js -Algorithm SHA256Folder and file modification times may help show whether an install or update fell inside the window. Timestamps can be altered, so treat them as supporting evidence.
A match on the published SHA-256 confirms exposure, and a size of 3,692,922 bytes is a strong second signal. A hash that doesn't match doesn't necessarily clear the machine, so we suggest treating any Claude Code folder installed or updated in the window as suspect and continuing with the remaining steps.
Step 3: Review SSH access
Open ~/.ssh/authorized_keys for every account on the machine, service and admin accounts included, and flag any key nobody can explain. Check whether sshd (Linux) or Remote Login (macOS) is on when it shouldn't be. A disabled setting still doesn't mean no keys were planted.
Step 4: Review persistence
List startup items for every account and look for anything created or modified since the exposure window opened. Open each unfamiliar script they point to.
# macOS
launchctl list
ls -la ~/Library/LaunchAgents /Library/LaunchAgents /Library/LaunchDaemons
# Linux
systemctl --user list-unit-files
systemctl list-unit-files --state=enabled
crontab -l
# Windows (Command Prompt)
schtasks /query /fo LIST /v
reg query HKCU\Software\Microsoft\Windows\CurrentVersion\Run
reg query HKLM\Software\Microsoft\Windows\CurrentVersion\RunStep 5: Check network indicators
See whether Cursor's notice, StepSecurity's analysis or Phorion's advisory publish command-and-control domains or IP addresses. If they do, we suggest searching proxy, DNS and EDR logs for outbound connections to them from the start of the exposure window onward. A hit means you treat the machine as compromised, even if the host checks came back clean. If nothing is published, note that and rely on the host evidence.
Step 6: Contain: preserve, then remove
Preserve first. If you have endpoint tooling, copy the suspicious extension.js, unknown keys and persistence files, with their timestamps, before you change anything. Then remove unknown keys and persistence items, update the extension to 2.1.314 or later, and keep the machine off sensitive networks until the review is done. If the machine is headed for a reimage under Step 7, skip the manual cleanup: isolate it, preserve the evidence, rebuild.
Step 7: Decide between cleanup and reimage
For confirmed hits, we recommend a reimage. A loader running with the developer's privileges could have done things the published analysis didn't capture, and a rebuild removes that doubt. Either way, rotate the SSH keys, tokens and cloud credentials that machine could reach.
Step 8: Record what you did
Write down which machines were checked, who checked them, what turned up and what you did about it. A customer or auditor may ask later, and you'll want a clear answer.
The leaked traces: why agent traces matter for credential rotation
Cursor's update says the stolen bucket contained limited coding agent traces, mostly from 2025, from sessions not in Privacy Mode, which Cursor was permitted to use for model training. A small number of those traces contained unredacted credentials, and less than 0.01% of customers had API credentials exposed. Among users not on Privacy Mode, coding agent traces were exposed for fewer than 0.05%.
The Cloud Security Alliance research note draws the wider lesson: agent session traces can work as an unmanaged credential store. A coding agent records what it reads and runs. That record often captures secrets, and whoever holds unredacted traces may hold those secrets as well.
Don't sit on this one. In two enterprise cases Wiz investigated, cited in the CSA note, the first unauthorized model call came within 30 minutes of the reported credential access at the vendor. The same note says Wiz counted at least nine AI developer and hosting platforms that disclosed incidents in October 2026.
Confirm your organization's Privacy Mode settings and rotate any secrets that may have passed through agent sessions now, before anyone confirms whether you were in the affected group. Longer term, a credential proxy that keeps API keys out of AI agents cuts down how many raw secrets can end up in traces in the first place.
Fleet controls: the What, When, Whether model
CSO Online's reporting puts the core problem plainly: when malicious code can reach developers through what looks like a routine update, the assumption that software from a trusted marketplace is safe starts to break down. No single control fixes that.
We sort extension controls into three layers. Each answers one question and fails in its own way, which is why you want them stacked:
- What may be installed: allowlists.
- When a version reaches machines: install cooldowns, version pinning and update windows.
- Whether the copy on disk matches what upstream published: signature verification and integrity hashing.
What: allowlists
Cursor's identity and access management docs state that extensions.allowed uses an allowlist model: once you add any entries, only explicitly allowed entries are permitted and everything else is blocked. That gives admins a genuine default-deny control.
The catch is that an allowlist decides which extension may be installed, not which copy ends up on disk. VS Code's enterprise documentation says that for locally supplied VSIX packages, these rules use identifiers declared in the package and do not verify the package's origin, prevent changes to local extension files or limit an extension's runtime permissions. The tampered build carried the real Claude Code identity. An allowlist that approved Claude Code would have waved it through.
When: cooldowns, pinning and update windows
Cursor's security hardening docs describe holding extension installs and updates until a marketplace version has been public for a set number of hours, enforced across the fleet, with optional signature verification, to blunt short-lived malicious uploads. The bad builds were live for about 11 hours, so a cooldown looks like a fit for incidents of this shape. It assumes, though, that the marketplace's publication metadata and signing are intact. These builds came out of Cursor's compromised cache, and it isn't clear a cooldown or signature check would have kicked in here.
Pin critical extensions to known-good versions and move the pins on purpose, not through silent auto-update. Batch updates into a scheduled window, send them to a small canary group first, and widen the rollout once nothing odd shows up.
Whether: signatures and integrity hashing
Turn on signature verification where it exists. Then hash installed extension bundles on managed machines on a schedule and compare them with hashes from the official upstream release. The tampered file was the clean Open VSX build with a loader stuck on the front, so its hash would not have matched upstream. This is the layer that catches what allowlists miss: a modified copy wearing a legitimate identifier.
| Layer | Control | Helps with | Does not cover |
|---|---|---|---|
| What | Allowlist (extensions.allowed) | Blocks unapproved extensions by default | Package origin or tampered local files |
| When | Install cooldown | Delays exposure to short-lived malicious versions | Versions live past the delay; a compromised marketplace |
| When | Version pinning | Stops silent upgrades to untested versions | A pinned version that was already compromised |
| When | Update windows with canaries | Limits the blast radius of a bad update | Slow-acting or dormant payloads |
| Whether | Signature verification | Checks package authenticity where supported | Optional; depends on configuration and intact signing |
| Whether | Integrity hashing | Detects modified bundles after install | Needs a trusted upstream hash |
A rollout sequence that won't stall developers
Controls that block work get bypassed. Stage the rollout and keep the friction visible.
- Inventory installed extensions and agree an approved list with engineering leads.
- Enable the allowlist for one pilot team, collect exceptions, then enforce it for everyone.
- Add the install cooldown and signature verification, and explain to developers why new versions now arrive later.
- Set up an exception path with a named owner and a response target, so nobody sideloads VSIX files to get around the rules.
- Review the approved list every quarter and drop extensions nobody uses.
Caveats and limits of this guidance
- The exposure figure is an upper bound from Cursor's own disclosure. Being in the group of at most 5,000 doesn't mean a machine was compromised, and being outside it doesn't prove one is clean.
- The hash and file size describe the analysed sample. Check vendor advisories for other variants before you call a machine clean.
- Cooldowns only help against short-lived uploads when the marketplace's own data can be trusted. A malicious version that stays live past the delay gets through.
- Allowlists and pinning add friction. Push too hard and people drift to unmanaged installs.
- Setting names and options in Cursor and VS Code change over time, so check current documentation before rolling anything out.
Key Takeaways
- A tampered Claude Code build was live in Cursor's extension marketplace for about 11 hours on October 29, and at most 5,000 users may have received it.
- The bad builds were not on the Microsoft Visual Studio Marketplace, Open VSX or npm. Anthropic moved its legitimate extension straight to 2.1.314.
- Uninstalling is not remediation. The payload drops persistence scripts that keep running, and a disabled macOS Remote Login setting does not prove a machine is clean.
- Hunt with the published SHA-256 and file size, review authorized_keys, startup items and network logs, preserve evidence before removal, and reimage confirmed hits.
- In two cases Wiz investigated, first misuse came within 30 minutes of credential access, so rotate secrets that may have passed through agent sessions without waiting for confirmation.
- Use the What, When, Whether model: allowlists decide what is installed, cooldowns and update windows decide when, and signature and integrity checks decide whether the copy on disk matches upstream.
Conclusion
The malicious build was available for approximately 11 hours, but the lessons reach well beyond this one incident. A tampered build kept the legitimate identifier, ran on module load and left persistence behind. Informal checks, such as uninstalling the extension or simply trusting the marketplace, are not enough on their own against that combination. If you ran Cursor with the Claude Code extension during the exposure window, we suggest working through the triage steps now. Reimage confirmed hits and rotate reachable credentials without waiting for certainty.
For the longer term, treat IDE extensions as part of your software supply chain and apply the What, When, Whether model. Allowlists decide what may be installed. Cooldowns, pinning and update windows decide when. Signature and integrity checks decide whether the copy on disk matches upstream. None of them is enough alone, and each adds friction, so roll them out in stages with a clear exception path. The goal isn't to stop developers using extensions. It's to make sure a short-lived malicious upload reaches as few machines as possible, and stays detectable when it does get through.
If it would help, Optijara can run an extension governance review with your platform team or support a staged rollout of these controls.
Related reading on Optijara: checklist for reviewing inference providers after the Fireworks AI LLMjacking breach and audit 'Don't Ask Again' rules in settings.local.json for leaked secrets.
Frequently Asked Questions
Which Claude Code extension builds in Cursor were malicious, and when were they available?
Cursor says a maliciously modified version of Anthropic's Claude Code extension was available in its VS Code Extension Marketplace between about 2:27am PT and 1:35pm PT on October 29, roughly 11 hours, and that at most 5,000 users who requested specific cached versions may have received the malicious build. Anthropic moved its legitimate extension straight to version 2.1.314 to avoid confusion with the malicious versions.
If I uninstalled the extension, is my machine safe?
Not necessarily. Cursor warns that uninstalling may not be sufficient because the payload drops standalone persistence scripts that keep running. Check authorized_keys for every account, review startup items and scheduled jobs from the exposure window, and consider reimaging if you confirm the malicious build was present.
Were VS Code users who got the extension from the Microsoft Marketplace or Open VSX affected?
According to SecurityWeek, the modified versions were not developed by Anthropic and were not pushed to the Microsoft Visual Studio Marketplace, Open VSX or npm. The exposure came from Cursor's marketplace cache, so the main concern is machines that installed or updated the extension through Cursor.
How can I confirm whether my extension.js file is the tampered one?
Hash it with SHA-256 and compare the result with the value StepSecurity published, listed in the indicator table in this guide. The malicious file is 3,692,922 bytes, roughly 7 KB larger than the clean release. A non-matching hash does not necessarily clear the machine, so we suggest still running the full SSH, persistence and network review on any Claude Code install that was installed or updated in the window.
Does Cursor's extensions.allowed setting stop this kind of attack on its own?
No. Once any entry is added, it blocks everything not explicitly allowed, which is useful. But VS Code's documentation notes that identifier-based rules do not verify a package's origin or prevent changes to local extension files, so a tampered copy using the legitimate identifier would pass. Pair it with controls on when versions arrive and integrity checks on what is on disk.
Do I need to rotate credentials even if my machine looks clean?
It is the safer choice. Cursor says a small number of coding agent traces in the stolen bucket contained credentials that had not been redacted, and the CSA note cites two Wiz cases where the first unauthorized model call came within 30 minutes of the reported credential access at the vendor. Rotate secrets that may have passed through agent sessions rather than waiting for confirmation.
Sources
- https://cursor.com/blog/claude-code-extension-security-notice
- https://cursor.com/blog/security-incident-update
- https://www.bleepingcomputer.com/news/security/cursor-confirms-security-breach-led-to-malicious-claude-code-extension/
- https://www.securityweek.com/malicious-claude-code-extension-served-in-cursor-supply-chain-attack/
- https://thehackernews.com/2026/10/official-claude-code-vs-code-extension.html
- https://www.csoonline.com/article/4243210/cursor-removes-malicious-claude-code-extension-after-ssh-backdoor-attempt.html
- https://phorion.io/blog/offical-claude-code-vsx-compromise/
- https://www.stepsecurity.io/blog/claude-code-extension-trojanized
- https://labs.cloudsecurityalliance.org/research/csa-research-note-fireworks-cursor-extension-chain-20261116/
- https://code.visualstudio.com/docs/enterprise/extensions
- https://cursor.com/docs/enterprise/security-hardening
- https://cursor.com/docs/enterprise/identity-and-access-management



