daily brief · Oct 28, 2026
Planted AGENTS.md File in Downloads Folder Tried to Make Codex Install Malware
Forever Security found a planted AGENTS.md in a user's Downloads folder telling Codex to install malware. How it works and how to protect yourself.
Don’t start Codex, Claude Code or any coding agent inside your Downloads folder. Security firm Forever Security says it caught a planted AGENTS.md file there that told OpenAI’s Codex to install a known malicious npm package called function-color. It stopped the install before any code ran.
AGENTS.md is an instructions file that coding agents read and follow when they open a folder. Forever says a web page can save a file to Downloads without a click, so the web can plant orders an agent will obey. How this particular file arrived is unknown.
In Forever’s own tests, Codex ran the malware in more than 90% of attempts, and the change was written to its machine-wide config. A similar CLAUDE.md trick got Claude Code to send its login token to an outside server about half the time. Forever says there is nothing for OpenAI or Anthropic to patch, because the agents work as designed.
Quick answers
How do I check if I'm affected?
Look for AGENTS.md or CLAUDE.md files you didn't write, unexpected servers in `~/.codex/config.toml`, or an `ANTHROPIC_BASE_URL` you didn't set. If you find one, rotate your tokens.
Was anyone actually hacked?
Forever says it blocked the real attempt before code ran. The token theft was shown in its own tests.
AGENTS.md Downloads folder attacksecurityAI coding agentsOpenAI CodexClaude Codeprompt injectionnpm malware
More on: OpenAI · Anthropic and Claude · AI agents · AI coding · AI security · All Security briefings