Ahmad-progr

Claude Leaked Files — Security skill for Claude Code

Security community intermediate

Mirrored snapshot of Claude Code's source (exposed 2026-03-31) preserved for educational purposes, defensive security research, and software supply-chain analysis.

How to install Claude Leaked Files

This entry records only its repository, not the path inside it, so there is no exact command to give. Open Ahmad-progr/claude-leaked-files and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

What Claude Leaked Files does

Mirrored snapshot of Claude Code's source (exposed 2026-03-31) preserved for educational purposes, defensive security research, and software supply-chain analysis.

Alternatives in Security

  • Maestro Odyssey — Long-running iterative cycle — one entry, seven modes (debug improve planex review security defensive ui) 530 ★
  • Agentseal — Security toolkit for AI agents 344 ★
  • Security Check — Scan project for security issues — exposed secrets, missing .gitignore entries, unsafe patterns 335 ★

README

Claude Code Source Snapshot (For Security Research)

This repository mirrors a publicly exposed snapshot of Claude Code’s source that became accessible on **March 31, 2026**, due to a source map exposure in the npm package.

It is preserved strictly for:

  • Educational purposes
  • Defensive security research
  • Software supply-chain analysis

[!CAUTION] This repository does not claim ownership of the original code and is not an official Anthropic repository.


Research Background

This repository is maintained by a university student researching:

  • Software supply-chain leaks and build artifact exposure
  • Secure software engineering practices
  • Architecture of agent-based developer tools
  • Defensive analysis of real-world CLI systems

The archive supports:

  • Academic study
  • Hands-on security research
  • Architectural review
  • Discussion of packaging and release-process failures

How the Source Became Public

On March 31, 2026, **Chaofan Shou (@Fried_rice)** reported that Claude Code source files were accessible through a `.map` file included in the npm distribution.

“Claude code source code has been leaked via a map file in their npm registry!” — **@Fried_rice**, March 31, 2026

The source map pointed to unobfuscated TypeScript source files hosted in Anthropic’s R2 storage bucket, making the entire `src/` directory publicly downloadable.


What This Repository Contains

Claude Code is Anthropic’s command-line interface for interacting with Claude to perform software engineering tasks such as:

  • Editing files
  • Running shell commands
  • Searching codebases
  • Managing workflows
  • Coordinating multiple agents

Snapshot details:

  • Public exposure date: 2026-03-31
  • Language: TypeScript
  • Runtime: Bun
  • Terminal UI: React + Ink
  • Size: ~1,900 files, 512,000+ lines of code

Directory Structure Overview

src/
├── main.tsx                 # CLI entrypoint and orchestration
├── commands.ts              # Slash command registry
├── tools.ts                 # Tool registry
├── Tool.ts                  # Tool type definitions
├── QueryEngine.ts           # Core LLM query engine
├── context.ts               # Context collection logic
├── cost-tracker.ts          # Token cost tracking
│
├── commands/                # Slash command implementations (~50)
├── tools/                   # Tool implementations (~40)
├── components/              # Ink UI components (~140)
├── hooks/                   # React hooks
├── services/                # External service integrations
├── screens/                 # Full-screen UIs (Doctor, REPL, Resume)
├── types/                   # Type definitions
├── utils/                   # Utilities
│
├── bridge/                  # IDE and remote control bridge
├── coordinator/             # Multi-agent coordination
├── plugins/                 # Plugin system
├── skills/                  # Skill workflows
├── keybindings/             # Keybinding configs
├── vi