November 13, 2025 7m read

Cato CTRL™ Threat Research: Two Vulnerabilities in Anthropic’s MCP SDK Enable OAuth Token Theft and Supply Chain Attacks

Dr. Guy Waizel
Snir Aviv
Yuval Moravchick
Zvi Fried
Dr. Guy Waizel , Snir Aviv , Yuval Moravchick , Zvi Fried

Table of Contents

Wondering where to begin your SASE journey?

We've got you covered!
Listen to post:
Getting your Trinity Audio player ready...

Executive Summary 

The SolarWinds supply chain attack in 2020 reminded the world how a single weakness in trusted software can have global consequences. That incident reshaped how organizations view software integrity and the importance of securing every stage of the development pipeline.

Cato CTRL and Cato Application Security researchers have identified two vulnerabilities in Anthropic’s Model Context Protocol (MCP) software development kit (SDK) that could expose organizations to a similar class of risk. These flaws, found in the default configuration, could allow threat actors to hijack developer tokens and inject malicious code into automated build and release systems. We demonstrate this risk through a proof of concept in this blog. In environments where MCP-issued tokens are trusted by continuous integration (CI)/continuous delivery (CD) or code-signing processes, this could lead to tampered software being signed and distributed as legitimate updates. The findings highlight how even small configuration gaps can endanger the software supply chain in the era of AI-driven development.

Timeline & Disclosure 

  • July 8, 2025: Vulnerabilities reported by the Cato Application Security Team. 
  • July 10, 2025: Full technical report and proof-of-concept shared with Anthropic Security. 
  • July 11, 2025: Anthropic acknowledged receipt and initiated review with MCP maintainers. 
  • September 4, 2025: Anthropic acknowledged our findings and noted that they align with a security scenario described in their official specification under the “Confused Deputy Problem.” They also indicated that efforts are underway to provide clearer guidance and improved default settings in the SDKs to help developers avoid this configuration risk. 
2025 Cato CTRL™ Threat Report | Download the report

Technical Overview 

How a Misconfigured SDK Can Trigger a Supply Chain Attack 

In many organizations, Anthropic’s MCP SDK serves as the internal OAuth server connecting developers, automation agents, and systems such as Bitbucket or GitHub. The tokens it issues often carry broad permissions that allow developers to clone repositories, trigger builds, upload artifacts, or invoke code-signing steps within a CI/CD process.

Imagine a developer already signed in to their company’s single sign-on (SSO)-backed MCP environment during a normal workday. A malicious website takes advantage of the SDK’s permissive defaults, where sensitive endpoints such as /register, /authorize, and /token accept cross-origin requests from any domain, and redirect URIs are not strictly validated. With a single browser visit, the page silently registers a rogue client, completes the OAuth flow, and steals a valid developer access token.

From that moment, the threat actor effectively becomes the developer within every connected system that trusts MCP-issued tokens. They can access repositories, push code changes, or trigger automated builds that produce signed binaries. In many organizations, especially managed service providers (MSPs) and SaaS vendors, the CI/CD pipeline automatically builds, signs, and publishes these artifacts to a shared update repository that serves multiple customer environments. Because the process relies on authenticated commits and automated signing, the malicious binary passes through the pipeline undetected and is deployed to the vendor’s update server.

When customer tenants or connected systems fetch their next scheduled update from the vendor’s managed service, they may unknowingly install the threat actor’s version. The update is fully signed, fully trusted, and fully compromised, allowing the threat actor’s code to propagate across all customers that depend on the provider’s software distribution channel.

The attack unfolds through a simple but dangerous sequence: 

  1. Token Theft: The threat actor exploits insecure OAuth settings to obtain a valid developer token. 
  2. Repository Access: Using the stolen token, they access Bitbucket or another source control system. 
  3. Build Manipulation: They modify build scripts or source code to embed a malicious payload. 
  4. Automated Signing: The CI/CD pipeline, which trusts authenticated pushes, automatically signs the altered binary. 
  5. Distribution: The signed artifact is published to the vendor’s update or artifact server, which is used to deliver updates to customer environments. 
  6. Propagation: Customer tenants or connected systems automatically download and install the update, causing the compromise to spread through the software supply chain. 

This scenario is especially concerning because nothing is technically broken. The SDK operates as designed, but its permissive default configuration transforms convenience into exposure. There is no zero-day exploit or production vulnerability involved, only a quiet abuse of trust built into automation and identity handling.

The result is a form of trusted identity takeover that ripples across the software supply chain, converting legitimate update infrastructure into an attack channel similar in nature to the SolarWinds incident. In modern development ecosystems driven by agentic AI, automation frameworks, and SDK-based integrations, design defaults that seem harmless can become the first link in a global compromise chain. We illustrate this risk in Figure 1 below.

Figure 1. Illustration from token theft to software supply chain attack 

Anthropic’s MCP SDK analysis 

Our analysis of the Anthropic’s MCP SDK (v1.10.1) revealed two interconnected weaknesses that together enable browser-based token exfiltration and OAuth hijacking.

Insecure CORS Policy (CWE-352) 

By default, the SDK’s /register, /authorize, and /token endpoints are configured with: allow_origins=”*” 

This wildcard setting (Access-Control-Allow-Origin: *) allows any website to send cross-origin requests to sensitive endpoints, enabling a threat actor-controlled webpage to interact directly with the MCP server.

Unvalidated Redirect URIs (CWE-601) 

The SDK client registration process allows arbitrary redirect URIs and does not enforce validation by scheme, origin, or host. 

This means a threat actor can register their own client and set its redirect URI to a domain they control (e.g., http://evil.com), allowing OAuth tokens to be redirected and captured through request parameters in the browser. 

Proof-of-Concept (PoC) 

To demonstrate impact, we created a browser-based HTML exploit hosted on a threat actor-controlled domain. The code used in this proof of concept is shown in Figure 2, Figure 3, Figure 4, and in the video below.

When a victim – who is already logged in to their organization’s SSO-backed MCP OAuth provider – visits the page, the following occurs automatically:

  1. A malicious client is registered with a redirect URI pointing to the threat actor’s domain.
  2. The page initiates the OAuth /authorize flow.
  3. The victim unknowingly grants authorization. 
  4. The access token is exchanged via /token and exfiltrated to the threat actor’s server. 

In our PoC, the stolen token granted full Bitbucket API access to the victim’s repositories, which allowed listing, modification, and write actions through authenticated requests.

/register_request

Figure 2. /register request creating a new OAuth client and returning a client_id due to the insecure CORS configuration

Figure 3. /authorize redirect showing Bitbucket’s OAuth flow accepted the attacker-controlled redirect URI

Figure 4. /token request exchanging the authorization code for access and refresh tokens obtained by the attacker

Conclusion 

These findings underscore how default-permissive SDK configurations can open critical trust boundaries in modern automation environments.

When AI, automation, and developer identity converge, even small oversights in authentication logic can cascade into systemic risks-including software supply chain compromise.

As we continue to integrate AI agents and SDKs deeper into our workflows, the lesson is clear: security must be explicitly configured, not assumed.

 Protections 

For Developers  
Developers deploying the Anthropic MCP SDK should explicitly configure CORS and redirect URI validation to harden OAuth security. 

Secure Redirect URI Validation 

redirect_uri_validation=RedirectUriValidationOptions( 
allowed_schemes=[“https”], 
allowed_hosts=[“myapp.com”, “localhost”] 

This prevents open redirects, authorization code interception, and domain spoofing. 

Secure CORS Configuration 

cors_origins=[“https://myapp.com”, “https://admin.example.com”] 

This prevents cross-origin token theft and cross-site request forgery (CSRF)-based attacks on OAuth endpoints.

Both mitigations are detailed in Anthropic’s MCP documentation and should be enforced whenever the SDK is deployed in production environments.

For Cato Customers 

Beyond the secure configuration of the Anthropic MCP SDK itself, enterprises can further reduce risk by applying GenAI security controls through the Cato SASE Cloud Platform. These controls operate at the network layer and apply to all MCP traffic, including traffic generated by the Anthropic Python SDK or other MCP implementations. 

With these capabilities, enterprises can define security rules that inspect and control AI tool activity across the enterprise.

For example, administrators can create policies that block or alert on remote MCP tool calls such as createadd, or edit.

This approach helps enterprises: 

  • Enforce least privilege for AI-driven actions.
  • Detect and alert on suspicious prompt usage in real time.
  • Maintain detailed audit logs of MCP-related activity across the network.

By combining secure SDK configuration with GenAI security controls, enterprises gain both application-level and network-level protection against token theft, data exposure, and unauthorized AI tool execution.

Related Topics

Wondering where to begin your SASE journey?

We've got you covered!
Dr. Guy Waizel

Dr. Guy Waizel

Tech Evangelist

Dr. Guy Waizel is a Tech Evangelist at Cato Networks and a member of Cato CTRL. As part of his role, Guy collaborates closely with Cato's researchers, developers, and tech teams to bridge and evangelize tech by researching, writing, presenting, and sharing key insights, innovations, and solutions with the broader tech and cybersecurity community. Prior to joining Cato in 2025, Guy led and evangelized security efforts at Commvault, advising CISOs and CIOs on the company’s entire security portfolio. Guy also worked at TrapX Security (acquired by Commvault) in various hands-on and leadership roles, including support, incident response, forensic investigations, and product development. Guy has more than 25 years of experience spanning across cybersecurity, IT, and AI, and has held key roles at tech startups acquired by Philips, Stanley Healthcare, and Verint. Guy holds a PhD with magna cum laude honors from Alexandru Ioan Cuza University, his research thesis focused on the intersection of marketing strategies, cloud adoption, cybersecurity, and AI; an MBA from Netanya Academic College; a B.Sc. in technology management from Holon Institute of Technology; and multiple cybersecurity certifications.

Read More
Snir Aviv

Snir Aviv

Application Security Researcher

Snir Aviv is an application security researcher at Cato Networks and member of Cato CTRL. Snir specializes in penetration testing, vulnerability research, and development of offensive security tools. Prior to joining Cato in 2024, Snir built and led the penetration testing team at Clear Gate, delivering high-impact security assessments for clients across diverse industries. Snir holds the Burp Suite Certified Practitioner (BSCP) and Offensive Security Web Expert (OSWE) certifications, has published multiple CVEs, and is known for his practical approach to security challenges and his ability to uncover complex vulnerabilities.

Read More
Yuval Moravchick

Yuval Moravchick

Application Security TL

Yuval Moravchick is the Application Security Research Team Leader at Cato Networks. With over 10 years of technical experience in the cybersecurity industry, Yuval has built and led security teams at various organizations. He specializes in penetration testing, security research, and the development of offensive security tools. Before joining Cato Networks, Yuval held roles at Wix.com and ControlUp, where he led an application security research team, detected 0-day bugs, and managed the SSDLC activities. Prior to joining Wix.com and ControlUp, Yuval honed his expertise at BugSec in managing a team of skilled penetration testers and also conducted red team simulations, and developed malware. Yuval holds a B.Sc. in Industrial & Management Engineering and has several industry certifications, including Offensive Security Certified Professional (OSCP) and Offensive Security Web Expert (OSWE).

Read More
Zvi Fried

Zvi Fried

Staff Automation Engineer

Zvi Fried is a Staff Automation Engineer at Cato Networks, responsible for developing state-of-the-art Agentic AI systems that drive seamless IT security transformation. With over a decade of leadership experience in Israel's cybersecurity industry, Zvi has successfully led large-scale automation projects with significant organizational impact. His expertise lies at the intersection of automation and intelligence, delivering innovative, practical solutions to complex engineering challenges. Prior to joining Cato, Zvi served as Automation Technology Leader at Orca Security and previously held a similar role at Check Point Software Technologies.

Read More