Skip to main content
ExploitPublished

Three Flaws in Anthropic MCP Git Server Enable File Access and Code Execution

Source The Hacker News

0

Mentioned vulnerabilities

Severity
Medium

Rated by Threat Radar

Data as of 26 Jan 2026, 20:50 UTC

What to do

AI-suggested

European organizations should immediately update to the latest patched versions of mcp-server-git (2025.12.18 or later) that remove the vulnerable git_init tool and add strict path validation. They should audit all AI assistant inputs, especially those that parse or interact with Git repositories, to detect and block malicious prompt injections such as poisoned README files or issue descriptions. Implement strict input sanitization and validation on all user-controlled data fed into AI models or MCP servers. Restrict the MCP server's filesystem permissions to limit repository creation and modification to trusted directories only. Monitor Git repository activities for unusual operations, such as unexpected repository creations or modifications to .git/config and .gitattributes files. Employ runtime application self-protection (RASP) or behavior-based anomaly detection to identify suspicious Git command executions triggered by AI interactions. Conduct regular security reviews of AI integration points and consider isolating AI-assisted development environments from critical production systems. Finally, engage with Anthropic and the MCP community to stay informed about further security updates and best practices.

Description

A set of three security vulnerabilities has been disclosed in mcp-server-git, the official Git Model Context Protocol (MCP) server maintained by Anthropic, that could be exploited to read or delete arbitrary files and execute code under certain conditions. "These flaws can be exploited through prompt injection, meaning an attacker who can influence what an AI assistant reads (a malicious README,

References

Community reviews

Loading reviews…