← Back to context

Comment by Gazoche

21 hours ago

Until it decides to delete your home directory:https://old.reddit.com/r/ClaudeAI/comments/1pgxckk/claude_cl...

You're not running it on a filesystem that takes snapshots and is easily reversible?

  • Many moons ago, I accidentally rm -rf'd the wrong directory with all my code inside poof, gone. I still had PyCharm open, I checked its built-in version tracker and lo and behold, my code as it was before I rm -rf'ed up my code. I believe Claude has ways to undo file changes, but something like rm is just outside of its scope.

This could be avoided by aliasing rm to something else that stops you from deleting stupid things like your entire home directory / partition root.

  • What if the LLM detects this, and chooses to run /bin/rm directly? Or worse, writes a program that calls unlink.

    • I mean, you can always purge /bin/rm, but at this point since you're not satisfied, sounds like you want SELinux ;)

      If Claude is writing a program to go that low level I'd pay money to watch that.

      4 replies →

You can use the /hookify plugin to add hooks for preventing dangerous commands like this.

Is it worth the risk? For me yes. Today Claude decided to checkout a git commit from yesterday and all local unstaged changed were lost. Annoying mistake. Lost 6 hours of work I think. Nevertheless I still prefer giving all access to Claude. Also root. It can do everything.