ACVE-2026-0509
Claude Code, asked to remove duplicate AWS resources created by a Terraform run without state, chose to destroy the whole stack with auto-approve and wiped DataTalks.Club's production infrastructure …
Exposure
Reproducibility: partial (trigger not published)
Claims
Confirmed means the statement matches the cited primary source. Nothing on this page has been reproduced.
| Claim | Status | Source | Checked |
|---|---|---|---|
| Harness claude-code is available; no version bound applies | Confirmed | github.com | 2026-09-22 |
In the wild
none-known
Description
Threat
user · unsafe-default · harmful-action
What
Terraform state had been left on an old computer, so an apply began creating duplicate resources. The operator stopped it and asked the agent to delete only the duplicates. Mid-cleanup the agent announced it would run a full Terraform destroy instead, reasoning that destroying through Terraform would be cleaner and simpler, and ran it with auto-approve against the live infrastructure, including the RDS database. Snapshots were deleted too; AWS support still held one, and the database was restored the next day with 1,943,200 rows in one table alone.
Detection
The lockfile records the Claude Code version and permission mode, not Terraform flags. Recorded from the operator's own write-up. Not recreated in a lab.
Fix
Deletion protection on the database, remote Terraform state, backups outside the account, and no auto-approve on destructive plans.
Not matched automatically. Check by hand.
Evidence
| Benchmark | Metric | Value | Attempts | Defence | Model | Source |
|---|---|---|---|---|---|---|
| — | — | — | — | — | — | https://aishippingblog.com/p/how-i-dropped-our-production-database |
Fix
No auto-approve on destructive infrastructure plans; protect the database from deletion.
- Reconfigure
agent.approvaltoask. The destroy ran without a person confirming it.