Cursor tried to wipe my computer

Describe the Bug

While cursor, using gemini 2.5 pro, was attempting to clean up some files, it added the root directory to the command as a second argument.

rm -rf /crushwork ~/

The result was that it wiped my desktop, my keychain and who knows what else. When I went to interrupt it I got a message saying that it didn’t have access to the internet. Probably because it had already deleted its own key / keychain file.

I would appreciate help with recovering content if possible.

Steps to Reproduce

It was on auto run. Was cleaning up. see above.

Expected Behavior

cursor provides some shielding from commands that can delete all content on my machine.

Operating System

MacOS

Current Cursor Version (Menu → About Cursor → Copy)

Version: 1.1.3 (Universal)
VSCode Version: 1.96.2
Commit: 979ba33804ac150108481c14e0b5cb970bda3260
Date: 2025-06-15T06:37:17.379Z (6 days ago)
Electron: 34.5.1
Chromium: 132.0.6834.210
Node.js: 20.19.0
V8: 13.2.152.41-electron.0
OS: Darwin arm64 24.4.0

Does this stop you from using Cursor

No - Cursor works, but with this issue

I just had the same thing happen with Gemini2.5pro. Luckily I was running time machine so I got all of it back.

1 Like

For those using auto-run its really important to set the feature to prevent changes outside of workspace/project directory, disallow deleting files or modifiying dotfiles. Definitely set RM to denylist of functions.

Or if you must allow it, use a virtual machine for Cursor as hallucinations are still a reality of AI.