Cursor Breach: How Hackers Poisoned Claude Code Extension

SOC Briefing Summary :: Executive Key Takeaways
- [01]Threat summary: Cursor confirmed an internal breach exposing up to 5,000 developers after attackers trojanized the Claude Code extension with persistent SSH backdoors.
- [02]Root cause vector: Stolen Fireworks AI credentials exposed unredacted API tokens from 2025 AI agent telemetry logs, enabling cache injection into the Cursor marketplace.
- [03]Immediate action: Audit developer machines for Claude Code versions 2.1.312 and 2.1.313, inspect ~/.ssh/authorized_keys, and rotate cloud credentials.
Executive Summary
Cursor, the widely adopted AI-assisted code editor built on Visual Studio Code, has released a comprehensive post-incident analysis confirming that an external security breach allowed threat actors to distribute trojanized versions of Anthropic's Claude Code extension directly through its marketplace cache. The supply chain compromise exposed up to 5,000 developers to malicious builds that attempted to deploy persistent SSH backdoors onto developer workstations.
The incident originated from the compromise of an access credential stored at Fireworks AI, a third-party artificial intelligence infrastructure provider utilized for model inference and training. Attackers weaponized the stolen Fireworks key to access a shared cloud storage bucket holding historical AI agent traces, harvested unredacted customer API keys, and pivoted into Cursor's internal systems to overwrite the extension cache. The intrusion forms part of a wider coordinated campaign dubbed "Black October", which has systematically targeted AI developer platforms including Railway, OpenCode, Lightning AI, and Fireworks AI.
---
Breach Architecture & Attack Vector Analysis

1. Ingress via Third-Party AI Infrastructure Provider
Cursor maintains dedicated cloud storage buckets to facilitate training and inference data exchange with Fireworks AI. Threat actors obtained valid credentials associated with Fireworks AI and queried a read-only S3 storage repository. This bucket hosted historical coding-agent telemetry from 2025, primarily derived from non-Privacy Mode interactions. While Cursor notes that fewer than 0.05% of users had traces exposed, a subset of these execution logs contained plaintext, unredacted API tokens.
2. Lateral Pivot to Marketplace Cache Infrastructure
Equipped with harvested API credentials, adversaries accessed several of Cursor's internal SaaS operational tools. Rather than attempting to compromise upstream package registries (such as Open VSX or Anthropic's verified GitHub releases), the attacker leveraged a stolen internal publishing credential to bypass external review queues and write unauthorized artifacts directly into the edge cache serving the Cursor VS Code extension marketplace.
3. Backdoor Deployment and Endpoint Persistence
On October 29, the adversary published malicious Claude Code builds (v2.1.312 and v2.1.313). During the 11-hour window before telemetry alarms triggered cache invalidation, approximately 5,000 developers downloaded or updated the extension. The embedded payload executed asynchronous JavaScript upon extension initialization, attempting to:
- Harvest environment variables, hostnames, and user identities.
- Append an attacker-controlled cryptographic key to
~/.ssh/authorized_keys. - Configure persistence by attempting to enable the local SSH daemon (
sshd).
Implementation bugs within the malware prevented automatic persistence on endpoints where SSH services were not pre-configured, preventing widespread automated exploitation on standard consumer macOS and Windows configurations.
---
MITRE ATT&CK Tactics, Techniques & Procedures (TTPs)
| Tactic | Technique ID | Technique Name | Operational Context |
|---|---|---|---|
| Initial Access | T1078 | Valid Accounts | Ingress achieved using stolen third-party Fireworks AI cloud storage credentials. |
| Credential Access | T1552.001 | Credentials in Files | Plaintext API tokens harvested from historical AI coding-agent execution logs in S3. |
| Lateral Movement | T1021.007 | Cloud Services | Threat actors navigated Cursor's internal SaaS stack using harvested administrative tokens. |
| Resource Development | T1195.002 | Compromise Software Supply Chain | Trojanized Claude Code extension versions 2.1.312/313 injected directly into marketplace cache. |
| Persistence | T1098.004 | SSH Authorized Keys | Injected attacker-controlled public keys into developer ~/.ssh/authorized_keys files. |
| Execution | T1059.007 | JavaScript | Extension initialization scripts triggered malicious Node.js payloads inside developer IDE processes. |
---
Threat Actor Profile & "Black October" Campaign Context
Threat telemetry from enterprise security firms confirms that the Cursor intrusion is linked to a broader adversary cluster targeting generative AI development stacks throughout October and November:
- Campaign Objectives: The threat group targets developer environments to capture AI API tokens, cloud infrastructure secrets, and high-tier compute credits. Stolen credentials are subsequently weaponized for unauthorized model inference, massive model distillation operations, and lateral pivoting into corporate GitHub repositories.
- Correlated Incidents: Fireworks AI suffered multiple disclosures regarding compromised cloud vendor keys, which subsequently affected Notion workspace transcripts. Contemporaneously, Railway reported severe credential theft resulting in over $740,000 in fraudulent compute charges, while OpenCode and Lightning AI disclosed parallel API key exfiltration attempts.
---
Incident Response & SOC Mitigation Playbook
Organizations whose engineering teams utilize Cursor must immediately execute the following defensive containment procedures:
1. Developer Endpoint Verification & Containment
- [ ] Scan Extension Directories: Inspect
.cursor/extensions/and VS Code directories for artifacts ofanthropic.claude-codematching versions2.1.312or2.1.313. - [ ] Audit SSH Authorized Keys: Review
~/.ssh/authorized_keyson all developer workstations for unknown public keys introduced on or after October 29, 2026. - [ ] Credential Invalidation: Mandate a global rotation of all developer personal access tokens (PATs), AWS/GCP keys, and AI platform secrets stored in local
.envfiles or system environment variables.
2. Detection & Threat Hunting Queries
title: Malicious Extension SSH Authorized Keys Injection
id: a8f4139e-4c7b-4892-98e3-dc481b7a2e99
status: experimental
description: Detects file modification events targeting SSH authorized_keys initiated by developer IDE processes (Cursor, VS Code).
author: CyberNewsAI Threat Research Team
references:
- https://www.bleepingcomputer.com/news/security/cursor-confirms-security-breach-led-to-malicious-claude-code-extension/?ref=cybernewsai.com
logsource:
category: file_event
product: windows
detection:
selection_process:
Image|endswith:
- '\cursor.exe'
- '\code.exe'
- '\node.exe'
selection_file:
TargetFilename|contains: '.ssh\\authorized_keys'
condition: selection_process and selection_file
falsepositives:
- Legitimate automated administrative deployment scripts
level: high
tags:
- attack.persistence
- attack.t1098.004// Microsoft Defender for Endpoint / Sentinel Hunting Query
// Identifies Cursor IDE and child processes modifying SSH configuration or establishing unexpected outbound SSH sessions
let IdeProcesses = dynamic(["cursor.exe", "code.exe", "node.exe"]);
DeviceFileEvents
| where Timestamp >= datetime(2026-10-29T00:00:00Z)
| where InitiatingProcessFileName in~ (IdeProcesses)
| where FolderPath has ".ssh" and FileName =~ "authorized_keys"
| project Timestamp, DeviceName, ActionType, InitiatingProcessFileName, InitiatingProcessCommandLine, FolderPath, FileName, AccountName
| join kind=leftouter (
DeviceNetworkEvents
| where RemotePort in (22, 2222)
| project DeviceName, NetworkConnectionTime=Timestamp, RemoteIP, RemoteUrl
) on DeviceName
| order by Timestamp desc---
| Indicator | Indicator Type | Context & Threat Description |
|---|---|---|
| Anthropic Claude Code v2.1.312 | Extension Identifier | Trojanized Cursor marketplace extension package deployed October 29. |
| Anthropic Claude Code v2.1.313 | Extension Identifier | Secondary trojanized package injected into Cursor cache. |
| ~/.ssh/authorized_keys | File Target | Target artifact modified during backdoor persistence routine. |
| 2026-10-29 02:00 to 13:00 UTC | Temporal IOC | Active exposure window for malicious marketplace downloads. |
---
Related Topic Cluster Intelligence
- CVE-2026-61500: How to Detect & Patch Rejetto HFS RCE Flaw: Hackers actively scan for critical Rejetto HFS flaw CVE-2026-61500, enabling session forgery and remote code execution via weak PRNG signing keys.
- BragJack Attacks Hijack AI Browser Agents via Extensions: BragJack attacks exploit extension permissions via Prompt Forcing to hijack AI assistants in Chrome, Edge, and Claude, exfiltrating emails and enterprise data.
- Passkey Phishing Lures Fuel Major Microsoft 365 Data Theft: Extortion groups Storm-3121 and Storm-3032 weaponize fake passkey lures and device-code phishing to breach Microsoft 365 tenants and covertly exfiltrate enterprise SharePoint data.
Claude Code Extension v2.1.312Claude Code Extension v2.1.313~/.ssh/authorized_keys// VERIFIED_SOURCES_&_REFERENCES
Related Threat Intelligence
View Archive
ARTEX AI Agents: How to Detect & Counter Autonomous Attacks
FBI issues FLASH advisory warning that cybercriminals abuse ARTEX AI agents to achieve domain compromise in under 3 hours. Hunt rapid automated lateral moves.

AI Infostealer Market: How to Detect & Block Replay Attacks
Dark web shops deploy AI to parse infostealer logs into searchable corporate dossiers, targeting enterprise VPNs and AI tokens. Hunt token replay attacks.

Telegram Widgets: How to Detect & Block WebRAT Infiltration
Flaws in Telegram's newly launched widgets enable zero-click RCE to deliver WebRAT infostealer via PowerShell. Hunt Telegram child processes with KQL.