diff --git a/CLAUDE.md b/CLAUDE.md index 851dd8f..2d60848 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -154,8 +154,8 @@ The `prompts/` directory contains specialized prompt templates for each testing - `exploit-*.txt` - Exploitation attempt prompts - `report-executive.txt` - Executive report generation prompts -### Claude Code SDK Integration -The agent uses the `@anthropic-ai/claude-code` SDK with maximum autonomy configuration: +### Claude Agent SDK Integration +The agent uses the `@anthropic-ai/claude-agent-sdk` with maximum autonomy configuration: - `maxTurns: 10_000` - Allows extensive autonomous analysis - `permissionMode: 'bypassPermissions'` - Full system access for thorough testing - Playwright MCP integration for web browser automation @@ -235,7 +235,7 @@ For detailed design, see `docs/unified-audit-system-design.md`. - **Configuration-Driven Architecture**: YAML configs with JSON Schema validation - **Modular Error Handling**: Categorized error types with retry logic - **Pure Functions**: Most functionality is implemented as pure functions for testability -- **SDK-First Approach**: Heavy reliance on Claude Code SDK for autonomous AI operations +- **SDK-First Approach**: Heavy reliance on Claude Agent SDK for autonomous AI operations - **Progressive Analysis**: Each phase builds on previous phase results - **Local Repository Setup**: Target applications are accessed directly from user-provided local directories @@ -278,7 +278,7 @@ src/ # Core modules ├── checkpoint-manager.js # Git-based checkpointing + rollback ├── queue-validation.js # Deliverable validation ├── ai/ -│ └── claude-executor.js # Claude Code SDK integration +│ └── claude-executor.js # Claude Agent SDK integration └── utils/ audit-logs/ # Centralized audit data (v3.0) └── {hostname}_{sessionId}/ diff --git a/Dockerfile b/Dockerfile index 1d35f1c..3933e7e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -97,7 +97,7 @@ COPY package*.json ./ # Install Node.js dependencies as root RUN npm ci --only=production && \ npm install -g zx && \ - npm install -g @anthropic-ai/claude-code && \ + npm install -g @anthropic-ai/claude-agent-sdk && \ npm cache clean --force # Copy application code diff --git a/mcp-server/package-lock.json b/mcp-server/package-lock.json index 68803f2..38044b8 100644 --- a/mcp-server/package-lock.json +++ b/mcp-server/package-lock.json @@ -8,18 +8,15 @@ "name": "@shannon/mcp-server", "version": "1.0.0", "dependencies": { - "@anthropic-ai/claude-code": "^1.0.96", + "@anthropic-ai/claude-agent-sdk": "^0.1.0", "zod": "^3.22.4" } }, - "node_modules/@anthropic-ai/claude-code": { - "version": "1.0.128", - "resolved": "https://registry.npmjs.org/@anthropic-ai/claude-code/-/claude-code-1.0.128.tgz", - "integrity": "sha512-uUg5cFMJfeQetQzFw76Vpbro6DAXst2Lpu8aoZWRFSoQVYu5ZSAnbBoxaWmW/IgnHSqIIvtMwzCoqmcA9j9rNQ==", + "node_modules/@anthropic-ai/claude-agent-sdk": { + "version": "0.1.25", + "resolved": "https://registry.npmjs.org/@anthropic-ai/claude-agent-sdk/-/claude-agent-sdk-0.1.25.tgz", + "integrity": "sha512-qwuydYaA3uamz4ivDzYXfL2PBjGwc0+beeIyo3nvtZQOtFLjH7xPdBK2w3+9KnB3L6V7VooAMdTXPpQyxCwcOg==", "license": "SEE LICENSE IN README.md", - "bin": { - "claude": "cli.js" - }, "engines": { "node": ">=18.0.0" }, @@ -30,6 +27,9 @@ "@img/sharp-linux-arm64": "^0.33.5", "@img/sharp-linux-x64": "^0.33.5", "@img/sharp-win32-x64": "^0.33.5" + }, + "peerDependencies": { + "zod": "^3.24.1" } }, "node_modules/@img/sharp-darwin-arm64": { diff --git a/package-lock.json b/package-lock.json index b3777f8..9266c5b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,7 +9,6 @@ "version": "1.0.0", "dependencies": { "@anthropic-ai/claude-agent-sdk": "^0.1.0", - "@anthropic-ai/claude-code": "^1.0.96", "ajv": "^8.12.0", "ajv-formats": "^2.1.1", "boxen": "^8.0.1", @@ -44,26 +43,6 @@ "zod": "^3.24.1" } }, - "node_modules/@anthropic-ai/claude-code": { - "version": "1.0.96", - "resolved": "https://registry.npmjs.org/@anthropic-ai/claude-code/-/claude-code-1.0.96.tgz", - "integrity": "sha512-xnxhYzuh6PYlMcw56REMQiGMW20WaLLOvG8L8TObq70zhNKs3dro7nhYwHRe1c2ubTr20oIJK0aSkyD2BpO8nA==", - "license": "SEE LICENSE IN README.md", - "bin": { - "claude": "cli.js" - }, - "engines": { - "node": ">=18.0.0" - }, - "optionalDependencies": { - "@img/sharp-darwin-arm64": "^0.33.5", - "@img/sharp-darwin-x64": "^0.33.5", - "@img/sharp-linux-arm": "^0.33.5", - "@img/sharp-linux-arm64": "^0.33.5", - "@img/sharp-linux-x64": "^0.33.5", - "@img/sharp-win32-x64": "^0.33.5" - } - }, "node_modules/@img/sharp-darwin-arm64": { "version": "0.33.5", "resolved": "https://registry.npmjs.org/@img/sharp-darwin-arm64/-/sharp-darwin-arm64-0.33.5.tgz", diff --git a/package.json b/package.json index 055af80..bb8b699 100644 --- a/package.json +++ b/package.json @@ -7,7 +7,6 @@ "start": "./shannon.mjs" }, "dependencies": { - "@anthropic-ai/claude-code": "^1.0.96", "@anthropic-ai/claude-agent-sdk": "^0.1.0", "ajv": "^8.12.0", "ajv-formats": "^2.1.1",