🔍

10轮迭代 · 5分钟部署前安全卡点

Ralph Quick Security Check · v2.0.0
开发 安全 A 级 作者 dorukardahan 公开目录收录
1.4k 下载 0 安装 6.3k 收藏 2 浏览

简介

5-10分钟快速安全巡检,覆盖密钥泄露、OWASP基础漏洞、认证鉴权等10项核心检查,适合部署前卡点或日常安全 hygiene。

原始描述

Fast security spot-check with 10 iterations (~5-10 min). Use when user says 'quick security check', 'pre-deploy audit', 'ralph quick', 'fast security scan',...

通过你的 Agent 添加

安装目录:ralph-quick/(目录名取自 SKILL.md 的 frontmatter name,不是 URL 里的 slug)。

点「快速安装」复制一段指令贴给你的 Agent:它会先下载到 /tmp、把文件清单和校验值给你看,你确认之后才解压安装。不会一步装完、也不改系统其它位置。

或者手动安装

Claude Code~/.claude/skills/ralph-quick-security-check/
Codex CLI~/.codex/skills/ralph-quick-security-check/
DeepSeek Harness~/.agents/skills/ralph-quick-security-check/

包是「根级 SKILL.md + 作者附带的文件」,解压到上面的 <slug>/ 目录即可; 目录名不用换,也不要把包直接解压到 skills 根目录。 技能申请的权限由作者决定:装之前先看清单里有没有脚本、它会读写什么。

中文使用说明 来自收录源

核心用法

Ralph Quick 是一个轻量级安全巡检框架,专为 CI/CD 卡点、部署前快速审计和日常安全 hygiene 设计。执行引擎采用严格的 10 轮迭代循环(每轮约 30-60 秒),覆盖密钥管理、OWASP 基础漏洞、容器安全等关键维度。

检查清单

迭代 检查项 技术深度
1 技术栈自动识别 环境感知
2 .env 是否在 .gitignore Git 安全基础
3 硬编码密钥扫描 静态分析
4 DEBUG 模式检测 配置安全
5-6 SQL/命令注入模式匹配 SAST 轻量版
7-8 敏感端点认证与限流检查 业务逻辑安全
9 容器 root 运行风险 云原生安全
10 汇总报告与修复建议 可执行输出

显著优点

  1. 时间可控:明确承诺 5-10 分钟,适合快节奏发布流程
  2. 置信度分级:独创四级置信度(VERIFIED → NEEDS_REVIEW),避免误报疲劳
  3. 零配置启动:自动检测技术栈,跳过不适用检查
  4. 可执行产出:生成结构化 .ralph-report.md,直接对接 Jira/飞书

潜在局限

  • 非深度扫描:基于模式匹配而非完整 AST 分析,复杂业务逻辑漏洞可能遗漏
  • 无动态测试:不含 fuzzing 或运行时检测,无法发现条件竞争类漏洞
  • 置信度依赖人工:NEEDS_REVIEW 项仍需安全工程师二次确认

适合人群

  • DevOps 工程师:在 GitHub Actions/GitLab CI 中设置 pre-deploy gate
  • 全栈开发者:缺乏专职安全团队时的自我兜底工具
  • 安全工程师:作为 /ralph-security 深度审计的前置筛选器

常规风险

风险类型 说明
假阴性风险 模式匹配无法覆盖变种攻击(如编码后的 SQL 注入)
生产环境误触 第 4 项 DEBUG 检测若读取真实环境变量,可能触发告警
报告累积 历史报告未自动清理,长期运行可能占用存储

建议将 Ralph Quick 定位为安全门禁而非合规审计工具,配合 SonarQube、Semgrep 等 SAST 工具形成分层防护。

技能正文


name: ralph-quick description: "Fast security spot-check with 10 iterations (~5-10 min). Use when user says 'quick security check', 'pre-deploy audit', 'ralph quick', 'fast security scan', 'spot check before deploy', or 'daily security check'. Covers secrets, OWASP basics, auth, rate limiting, and containers." metadata: { "openclaw": { "emoji": "🔍" }, "author": "dorukardahan", "version": "2.0.0", "category": "security", "tags": ["security", "audit", "owasp", "pre-deploy"] }

Ralph Quick — 10 Iterations (~5-10 min)

Fast security spot-check for pre-deployment or daily security hygiene.

Instructions

Execution Engine

YOU MUST follow this loop for EVERY iteration:

  1. STATE: Read current iteration (start: 1)
  2. ACTION: Perform ONE check from current phase
  3. VERIFY: Before reporting FAIL — read actual code, check if a library handles it, check DB constraints, check if dev-only
  4. REPORT: Output iteration result in the format below
  5. INCREMENT: iteration = iteration + 1
  6. CONTINUE: IF iteration <= 10 GOTO Step 1
  7. FINAL: Generate summary report saved to .ralph-report.md

Critical rules:

  • ONE check per iteration (not all at once)
  • ALWAYS show iteration counter [QUICK-X/10]
  • NEVER skip iterations
  • If VERIFY is inconclusive: mark NEEDS_REVIEW, not FAIL

Per-Iteration Output

[QUICK-{N}/10] {check_name}
Target: {file or system component}
Result: {PASS|FAIL|WARN|N/A}
Confidence: {VERIFIED|LIKELY|PATTERN_MATCH|NEEDS_REVIEW}
Finding: {description or "Clean"}
───────────────────────────────

Persona

Senior security engineer — evidence-based, critical focus, maximum efficiency.

Phase Structure

Iter Check
1 Auto-detect stack, infra, git sync
2 .env in .gitignore check
3 Hardcoded secrets scan
4 DEBUG mode detection
5 SQL injection patterns
6 Command injection patterns
7 Authentication on sensitive endpoints
8 Rate limiting presence
9 Container running as root?
10 Summary & recommendations

Auto-Detect (Iteration 1)

Deterministic order:

  1. git rev-parse --show-toplevel
  2. Stack: package.json, pyproject.toml, requirements.txt, go.mod
  3. Infra: Dockerfile, docker-compose.yml, k8s manifests
  4. CI/CD: .github/workflows, .gitlab-ci.yml
  5. Skip non-applicable checks, mark N/A

Confidence Levels

Level Meaning
VERIFIED Confirmed with code reading or PoC
LIKELY Strong evidence, no PoC
PATTERN_MATCH Keyword match only — flag for human review
NEEDS_REVIEW Inconclusive

Severity

Level CVSS Response
CRITICAL 9.0-10.0 Stop and fix immediately
HIGH 7.0-8.9 Fix before deployment
MEDIUM 4.0-6.9 Schedule fix
LOW 0.1-3.9 Note for later

Report File

On start: if .ralph-report.md exists, rename to .ralph-report-{YYYY-MM-DD-HHmm}.md. Save final report at end.

Parameters

Param Default Options
--iterations 10 1-20
--focus all secrets, owasp, infra, all

Note: Parameters are AI-interpreted instructions, not parsed CLI args.

When to Use

  • Pre-deployment quick check
  • Daily security spot-check
  • Verifying a specific fix

For deeper audits: /ralph-security (100), /ralph-ultra (1,000), /ralph-promax (10,000).

正文来自原始发布页, 版权归作者所有,许可未标注。 权利人认为有不妥,可申请下架。

标签

securityauditowasppre-deployci-cdspot-checkcontainer-securitysecrets-scanning

同类 Skill