Claude Code Vulnerability May Let Attackers Steal Credentials From GitHub, Says Microsoft


Microsoft researchers disclosed a now-patched vulnerability in Anthropic’s Claude Code GitHub Motion that might have allowed attackers to reveal credentials saved in software program growth pipelines by manipulating the AI agent via malicious GitHub content material.

In a weblog submit on Friday, Microsoft warned that AI coding brokers working inside CI/CD workflows might create new safety dangers as a result of these environments typically have entry to API keys, cloud credentials, and different delicate data.

“We started this analysis after observing immediate injection makes an attempt in public repositories utilizing AI-assisted GitHub workflows throughout a number of distributors, the place attacker-controlled concern or [pull requests], content material is processed by the AI agent and will affect its device use,” Microsoft wrote.

Commercial

Commercial

On GitHub, a pull request permits builders to suggest adjustments to a code repository and have these adjustments reviewed earlier than they’re authorized and merged.

The report comes as immediate injection assaults have emerged as one of many greatest safety threats going through AI brokers. In a prompt injection assault, an attacker hides instructions in content material reminiscent of emails, paperwork, web sites, or code feedback, inflicting an AI system to observe these directions as an alternative of the person’s.

Launched in October, Claude Code is Anthropic’s AI coding agent for software program growth duties. The device drew scrutiny in March after Anthropic by chance leaked greater than 500,000 strains of its supply code, exposing particulars of its inside structure and prompting widespread evaluation by researchers and builders.

In keeping with Microsoft, attackers might use immediate injection assaults hidden in GitHub points, pull requests, or feedback to govern Claude Code into accessing recordsdata containing delicate credentials.

Commercial

Commercial

To check the vulnerability, Microsoft created a GitHub workflow and disguised malicious directions behind content material hosted on a site it managed, permitting the researchers to bypass Claude’s security protections. The immediate injection assault tricked Claude into studying delicate credentials and altering them to evade each Claude’s safeguards and GitHub’s secret-scanning instruments. Microsoft stated an attacker might then reconstruct the credential and exfiltrate it via concern feedback, workflow logs, net requests, or shell instructions.

AI Is Already Developing AI, Says Anthropic—And Humans May Be Slowing Things Down

“To bypass Sonnet’s refusal security mechanisms, we obscured the shell payload behind a response from our managed area,” the agency stated. “We additionally enabled the workflow to be triggered by customers with no ‘write’ permissions to make sure Anthropic’s atmosphere variables scrub mitigations have been lively throughout our exams.”

Anthropic patched the flaw on Might 5 with Claude Code model 2.1.128 after Microsoft disclosed the vulnerability via HackerOne on April 29.

Commercial

Commercial

Regardless of a number of layers of built-in safety controls, Microsoft discovered {that a} decided attacker might probably manipulate an AI agent into exposing delicate data.

“We’re coming into an period the place pure language is executable code, and untrusted inputs like GitHub points have to be handled as hostile by default,” it stated. “A single, fastidiously crafted remark mixed with a misunderstood belief boundary is all it takes to stroll away with manufacturing credentials.”