SuperAPI AI 工具集

V3 Security Overhaul

安全与审计

查看项目

更新于 10-15 13:52

技能介绍

V3 Security Overhaul 是一个针对 claude-flow v3 的安全改造技能,目标是修复关键漏洞并建立以安全为先的开发实践。它通过 v3 安全专用智能体来编排整体安全改造工作。

用途 该技能用于对 claude-flow v3 进行全面的安全架构改造,处理关键漏洞(CVE-1、CVE-2、CVE-3),并推行默认安全的开发模式。

主要能力

  1. 安全架构设计:设计 v3 威胁模型与安全边界。
  2. CVE 修复:修复 CVE-1、CVE-2、CVE-3 关键漏洞。
  3. 安全测试:实现 TDD London School 安全框架。

使用方式 技能提供并行初始化的快速开始方式,通过 Task 调用不同安全智能体:

Initialize V3 security domain (parallel)

Task("Security architecture", "Design v3 threat model and security boundaries", "v3-security-architect") Task("CVE remediation", "Fix CVE-1, CVE-2, CVE-3 critical vulnerabilities", "security-auditor") Task("Security testing", "Implement TDD London School security framework", "test-architect")

关键安全修复 CVE-1:存在漏洞的依赖 npm update @anthropic-ai/claude-code@^2.0.31 npm audit --audit-level high

CVE-2:弱密码哈希 旧做法(不安全):使用 SHA-256 加硬编码盐 // ❌ Old: SHA-256 with hardcoded salt const hash = crypto.createHash('sha256').update(password + salt).digest('hex');

新做法(安全):使用 bcrypt,12 轮 // ✅ New: bcrypt with 12 rounds import bcrypt from 'bcrypt'; const hash = await bcrypt.hash(password, 12);

CVE-3:硬编码凭据 生成安全的随机凭据: // ✅ Generate secure random credentials const apiKey = crypto.randomBytes(32).toString('hex');

安全模式 输入校验(Zod): import { z } from 'zod';

const TaskSchema = z.object({ taskId: z.string().uuid(), content: z.string().max(10000), agentType: z.enum(['security', 'core', 'integration']) });

路径净化: function securePath(userPath: string, allowedPrefix: string): string { const resolved = path.resolve(allowedPrefix, userPath); if (!resolved.startsWith(path.resolve(allowedPrefix))) { throw new SecurityError('Path traversal detected'); } return resolved; }

安全命令执行: import { execFile } from 'child_process';

// ✅ Safe: No shell interpretation const { stdout } = await execFile('git', [userInput], { shell: false });

成功指标 安全评分:90/100(npm audit + 自定义扫描) CVE 解决:100% 关键漏洞已修复 测试覆盖率:安全关键代码 >95% 实施:所有安全模式均已文档化并测试

适用场景 适用于需要对 claude-flow v3 进行安全架构改造、修复关键 CVE、引入默认安全模式与安全测试框架的项目或团队。

限制 资料未提供该技能的具体运行环境要求、依赖版本范围、支持的平台、收费方式、价格及实际效果数据,这些信息暂未提供。