Signals/ Claude & Anthropic/ Brief /
A file in your Downloads folder can hijack Codex and Claude Code
Forever Security found a planted instructions file that tried to make a coding agent install malware. The fix is where you start the agent.
Security firm Forever Security reports that a coding agent on a customer’s machine tried to install a malicious npm package after reading an AGENTS.md file sitting in the Downloads folder. The agent was stopped before any code ran. Researchers could not say how the file got there.
Tools like Codex read the instruction files in the folder they start in and follow them as project rules. Forever says a web page can drop a file into Downloads without a prompt, and it built a demo page to show it. Whether real attackers use that route is unknown.
In lab tests, the file made Codex register a server in its machine-wide settings and install the package more than 90% of the time. A planted CLAUDE.md tried to point Claude Code’s traffic at an attacker’s server, which could leak a login token. It worked about half the time, and Claude often asks for approval or refuses odd changes.
The catch: Forever sells agent-monitoring software, and the reports include no statement from OpenAI or Anthropic. Forever argues the agents behaved as designed, so there is no patch to wait for.
What to do now
- Start coding agents inside a specific project folder, never in Downloads or your home folder.
- Read any AGENTS.md or CLAUDE.md you didn’t write before an agent follows it.
- Keep approval prompts and sandboxes on, and be suspicious of anything asking you to turn them off.
- If you find a planted file, assume your login token leaked and replace it.
Sources & links 2
More on Claude AI News, ChatGPT & OpenAI News, AI Agent News, AI Safety & Regulation News