SecurityContext

CVE-2026-31854: Cursor - Command Injection

  • Cve: CVE-2026-31854
  • Name: Cursor - Command Injection
  • Description: Cursor is a code editor built for programming with AI. Prior to 2.0 ,if a visited website contains maliciously crafted instructions, the model may attempt to follow them in order to “assist” the user. When combined with a bypass of the command whitelist mechanism, such indirect prompt injections could result in commands being executed automatically, without the user’s explicit intent, thereby posing a significant security risk. This vulnerability is fixed in 2.0.
  • Impact: Attackers can execute commands automatically without user consent, leading to potential full system compromise.
  • Remediation: Update to version 2.0 or later.
  • Vulnerability type: command_injection
  • Vulnerability impact: remote_code_execution
  • Requirement type: user_interaction
  • Requirements: Attacker needs user to visit a malicious website
  • Labels source: projectdiscovery
  • Severity: high
  • Cvss score: 8.8
  • Cvss vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
  • Epss score: 0.00367
  • Epss percentile: 0.30901
  • Assignee: [email protected]
  • Published at: 2026-03-11T17:16:58Z
  • Age in days: 258
  • Modified at: 2026-06-17T10:34:38Z
  • Patch available: yes
  • References total: 1
  • Products total: 1
  • Oss: yes
  • Projects total: 1
  • Advisory url: https://nvd.nist.gov/vuln/detail/CVE-2026-31854
  • Nvd status: analyzed
  • Checked, none or zero: known exploited entries, nuclei templates, public exploits total, public exploits capped, public exploits, rejected by nvd
  • Not known: hackerone

Cwe

IdName
CWE-78Improper Neutralization of Special Elements used in an OS Command

References

UrlSourceTags
https://github.com/cursor/cursor/security/advisories/GHSA-hf2x-r83r-qw5qnvdVendor Advisory

Products

ProductAffectedPlatform boundSourcesUrl
anysphere:cursor< 2.0nonvd/v1/products/anysphere/cursor

Projects

RepositoryLink kindsIndexedUrl
cursor/cursorsecurity_advisoryyes/v1/repositories/cursor/cursor

Index

  • Checked, none or zero: repositories, repositories high signal, packages

Exploitation

  • Remote: yes
  • Checked, none or zero: known exploited, known exploited by, exploitation seen, public exploit, public exploit count, initial access, authentication required
  • Not known: known exploited since, vulncheck known exploited since, public exploit first date, nuclei template, initial access since, hackerone reports, exposed hosts