A symlink trick beats six AI coding assistants, Wiz says
In short
- What it is: Wiz, a cloud-security company, says a malicious code repository can hide a symbolic link (a file that is only a pointer to another file) behind an ordinary name such as project_settings.json. When an AI coding assistant is asked to edit that file, the edit lands on a sensitive file outside the project, and in several tools the approval prompt never shows the real target.
- Who is affected: Wiz names six assistants: Amazon Q Developer, Anthropic's Claude Code, Augment, Cursor, Google Antigravity and Windsurf. It calls the pattern GhostApproval.
- Where it stands: by Wiz's table, AWS, Cursor and Google had fixed it, Augment and Windsurf were "In Progress", and Anthropic's entry read "Rejected". Anthropic told Wiz a symlink warning had already shipped before the report; see below.
- Catch: this is one security vendor's write-up of its own tests. The post gives no count of how many users were exposed, and no attack in the wild is mentioned.
What is the GhostApproval symlink attack?
AI coding assistants edit files for you. Most ask first: a dialog says which file the agent wants to change, and you click accept. Wiz's point is that this dialog is the safety control, so it has to show the truth.
The trick is old. A symbolic link, or symlink, is a file that points to another path. Wiz notes that symlink following is catalogued as CWE-61, "a well-documented attack primitive" for decades. Its proof of concept has two files in a repository:
- A symlink named project_settings.json that points to ~/.ssh/authorized_keys, the file that lists which keys may log in to the developer's machine over SSH.
- A README that tells whoever reads it to "update project_settings.json" with an attacker's public key.
A developer clones the repository and asks the assistant to "set up the workspace" or "follow the README". The agent writes the attacker's key through the link. Wiz says the attacker then has persistent, password-less SSH access to the machine. Wiz also describes a variant that writes to ~/.zshrc, a shell start-up file.
The assistants usually try to keep agents inside the project folder, the "workspace sandbox" (our wording). A symlink walks straight past a sandbox that checks the file's name but not where it really leads, which Wiz says it saw: "No warning, no path resolution, no sandbox enforcement."
Why the approval prompt matters
Wiz adds a second flaw on top, which it labels CWE-451, user-interface misrepresentation of critical information. In Claude Code, it says, the agent's own reasoning stated "I can see that project_settings.json is actually a zsh configuration file", yet the prompt asked only "Make this edit to project_settings.json?". In Wiz's words, "The agent knew. The user didn't."
Cursor's diff screen and Google Antigravity's dialog, it says, likewise showed the symlink's name rather than the resolved target. Two tools were worse: Amazon Q Developer and Windsurf wrote the file before the user could answer. Wiz says Amazon Q offered only an "Undo" button after the write, and in Windsurf the Accept/Reject buttons "appear after the damage is done". Augment, it says, followed links for both reads and writes with no confirmation at all; in one test it read a fake AWS-credentials file outside the workspace and quoted it in the chat.
Vendor status in Wiz's table
The severity ratings are Wiz's own. The disclosure timeline in the post runs as follows.
12 Feb 2026: Wiz reports the file-read issue to Augment; the file-write report follows on 14 February. 14 Feb 2026: Report goes to Anthropic, which answers on 15 February that it is "outside threat model" and closes the ticket as "Informative". 26 Feb 2026: Report goes to Google; Cursor's report follows on 27 February, Windsurf's (Cognition) on 2 March and AWS's on 5 March. 22 May 2026: Google deploys a fix; AWS follows on 27 May with language server 1.69.0. 5 Jun 2026: Cursor publishes CVE-2026-50549 and releases its fix. 23 Jun 2026: AWS assigns CVE-2026-12958; Cognition (Windsurf) acknowledges the report. 8 Jul 2026: Public disclosure.
Wiz says Augment and Windsurf acknowledged receipt and then gave no further update. (The post's calendar is a little loose here: it says the Windsurf report went in on 2 March but Windsurf acknowledged it only on 23 June.)
What Anthropic said
Anthropic's reply, as quoted by Wiz, was that the case "falls outside our current threat model": a user must first confirm they trust the directory, and the scenario involves the user "explicitly confirming a permission prompt inside of a directory containing a malicious symlink". Wiz closes the argument fairly: the consent is "formally present but substantively empty" if the prompt shows the wrong name, though it adds, "We don't claim to have the definitive answer."
The post also carries an update dated 7 July 2026. Anthropic told Wiz that a symlink warning in the Edit/Write permission dialog "shipped in v2.1.32 (Feb 5, 2026), nine days before this report was submitted", as part of internal security hardening, and that the "decline to comment" Wiz had received was an autoreply. Wiz's body text says current versions (2.1.173 and later) resolve symlinks and warn before writing to sensitive files. Why Wiz's table lists version 2.1.42, later than 2.1.32, with the same behaviour on screen is not explained in the post, and we did not test it. So "Rejected" describes the ticket's outcome, not necessarily the product today.
What Wiz recommends
- Resolve symlinks before showing a prompt.
- Warn explicitly when the resolved path is outside the workspace; a write to ~/.ssh/authorized_keys "should look very different" from a write to ./config.json.
- Never write before the user authorises it, so the dialog is "a gate, not an undo button".
Wiz also sells detection: its sensor alerts when a repository clones a symlink to a sensitive file and when authorized_keys changes. That is a product pitch and we did not assess it.
Terms in plain English
- Symlink (symbolic link): a file that holds only the path of another file; opening it opens the target.
- Workspace sandbox: a limit meant to keep an agent to the project folder (our wording).
- Human-in-the-loop: a design where a person approves each risky action.
- CWE-61 / CWE-451: entries in the public weakness catalogue: following a symlink, and a user interface that hides critical information.
- Pre-authorization write: the file is changed before the user has answered the prompt.
Where things stand
As of the post on 8 July 2026, Augment and Windsurf had no fix to report and Google's CVE was pending. We did not check later status pages.
Sources
- GhostApproval: A Trust Boundary Gap in AI Coding Assistants, Wiz, 8 July 2026
Sources
Related stories
- Qwen releases an open plugin to steer coding agents during long tasks
- docker cp flaw lets a container write files onto the host
- Cloudflare brings full post-quantum switch forward to 2027
- Anthropic says plain Claude Code review finds 11 of 21 logic bugs
- OpenSSL fixes Encrypted Client Hello bug allowing impersonation
- Anthropic posts quantum algorithms its authors call impractical