2 Sources
[1]
This 'critical' Cursor security flaw could expose your code to malware - how to fix it
A new report has uncovered what it describes as "a critical security vulnerability" in Cursor, the popular AI-powered code-editing platform. The report, published Wednesday by software company Oasis Security, found that code repositories within Cursor that contain the .vscode/tasks.json
[2]
Cursor AI Code Editor Flaw Enables Silent Code Execution via Malicious Repositories
A security weakness has been disclosed in the artificial intelligence (AI)-powered code editor Cursor that could trigger code execution when a maliciously crafted repository is opened using the program. The issue stems from the fact that an out-of-the-box security setting is disabled by default,
Share
Copy Link
A significant security vulnerability in the Cursor AI-powered code editor could allow hackers to execute malicious code when users open crafted repositories. The flaw stems from a default setting that disables a crucial security feature, potentially exposing users to various cyber threats.

A significant security flaw has been uncovered in Cursor, the popular AI-powered code-editing platform, potentially exposing users to malware and unauthorized code execution. The vulnerability, described as "critical" by software company Oasis Security, could have far-reaching implications for developers and organizations using the tool
1
.The security issue stems from Cursor's default configuration, which has the "Workplace Trust" feature disabled. This setting allows code repositories containing a specific configuration file (.vscode/tasks.json) to automatically execute certain functions as soon as they are opened. Hackers could exploit this autorun feature to embed malware into the code, potentially compromising entire systems and networks
1
2
.The implications of this vulnerability are severe. Oasis Security warns that it could lead to:
Erez Schwartz, a researcher at Oasis Security, emphasized the gravity of the situation, stating that this flaw places Cursor users at "significant risk from supply chain attacks"
2
.In a statement to Oasis Security, Cursor acknowledged the issue but explained that the Workplace Trust feature is deactivated by default as it interferes with some core automated features that users routinely depend on. The company recommended either enabling Workspace Trust or using a basic text editor when working with suspected malicious repositories. Cursor also promised to publish updated security guidelines regarding the Workspace Trust feature
1
.This incident highlights a growing concern in the rapidly evolving landscape of AI-powered coding tools. While platforms like Cursor, Claude Code, and Windsurf have gained popularity among developers, they are not immune to security vulnerabilities. Recent incidents, such as Replit accidentally deleting a user's entire database, underscore the potential risks associated with these emerging technologies
1
.Related Stories
The Cursor vulnerability is part of a broader trend of security challenges facing AI-powered coding and reasoning agents. Prompt injections and jailbreaks have emerged as stealthy and systemic threats, allowing attackers to embed malicious instructions in subtle ways. These attacks can trick AI systems into performing malicious actions or leaking sensitive data from software development environments
2
.To protect against this vulnerability and similar threats, experts recommend the following:
1
2
As AI-driven development continues to accelerate, it's crucial for both developers and organizations to prioritize security measures and treat them as foundational elements rather than afterthoughts in their development processes.
Summarized by
Navi
02 Aug 2025•Technology

07 Dec 2025•Technology

08 Jul 2026•Technology

1
Science and Research

2
Policy and Regulation

3
Technology