verify-security
Featured安全校验关卡。自动扫描代码安全漏洞,检测危险模式,确保安全决策有文档记录。当用户提到安全扫描、漏洞检测、安全审计、代码安全、OWASP、注入检测、敏感信息泄露时使用。在新建模块、安全相关变更、攻防任务、重构完成时自动触发。
AI & Automation 5,403 stars
413 forks Updated 2 days ago MIT
Install
Quality Score: 99/100
Stars 20%
Recency 20%
Frontmatter 20%
Documentation 15%
Issue Health 10%
License 10%
Description 5%
Skill Content
# ⚖ 校验关卡 · 安全校验
## 核心原则
```
安全即道基,破则劫败
安全决策必须可追溯
Critical/High 问题必须修复后才能交付
```
## 自动扫描
运行安全扫描脚本(跨平台):
```bash
# 在 skill 目录下运行
node scripts/security_scanner.js <扫描路径>
node scripts/security_scanner.js <扫描路径> -v # 详细模式
node scripts/security_scanner.js <扫描路径> --json # JSON 输出
node scripts/security_scanner.js <扫描路径> --exclude vendor # 排除目录
```
## 检测范围
### 自动检测的漏洞类型
| 类别 | 检测项 | 严重度 |
|------|--------|--------|
| **注入** | SQL 注入、命令注入、代码注入 | 🔴 Critical |
| **敏感信息** | 硬编码密钥、AWS Key、私钥 | 🔴 Critical |
| **XSS** | innerHTML、dangerouslySetInnerHTML | 🟠 High |
| **反序列化** | pickle.loads、yaml.load | 🟠 High |
| **路径遍历** | 未验证的文件路径操作 | 🟠 High |
| **SSRF** | 未验证的 URL 请求 | 🟠 High |
| **XXE** | 不安全的 XML 解析 | 🟠 High |
| **弱加密** | MD5、SHA1 用于安全场景 | 🟡 Medium |
| **不安全随机** | random 模块用于安全场景 | 🟡 Medium |
| **调试代码** | console.log、print、debugger | 🔵 Low |
### 文档层面检查
安全相关代码必须在 DESIGN.md 中记录:
- [ ] **威胁模型** — 防御哪些攻击
- [ ] **安全决策** — 为何选择此方案
- [ ] **安全边界** — 信任边界在哪里
- [ ] **已知风险** — 接受了哪些风险
## 危险模式速查
### Python
```python
# 🔴 危险 - 触犯道基
eval(), exec(), os.system()
subprocess(..., shell=True)
pickle.loads(), yaml.load()
cursor.execute(f"SELECT * FROM t WHERE id = {id}")
# ✅ 安全替代 - 道基稳固
ast.literal_eval()
subprocess([...], shell=False)
yaml.safe_load()
cursor.execute("SELECT * FROM t WHERE id = %s", (id,))
```
### JavaScript
```javascript
// 🔴 危险 - 触犯道基
eval(), innerHTML, document.write()
new Function(userInput)
// ✅ 安全替代 - 道基稳固
JSON.parse(), textContent
模板引擎自动转义
...
Details
- Author
- fengshao1227
- Repository
- fengshao1227/ccg-workflow
- Created
- 4 months ago
- Last Updated
- 2 days ago
- Language
- Go
- License
- MIT
Similar Skills
Semantically similar based on skill content — not just same category
AI & Automation Listed
security
Security review skill: comprehensive security checklist and patterns. Use when adding authentication, handling user input, working with secrets, or creating API endpoints.
42 Updated 1 months ago
xiaobei930 DevOps & Infrastructure Listed
node.js-
检查 RCE、SSRF、SQL 注入、路径穿越等安全问题,支持 Express/Koa/NestJS
834 Updated 4 days ago
TencentBlueKing Testing & QA Listed
security-specialist
安全专家。专注于应用安全、威胁建模、安全合规和数据保护。提供安全审查、漏洞扫描、安全配置和合规检查。用于构建安全可靠的应用系统。
36 Updated yesterday
huangwb8 AI & Automation Listed
security
Security Baseline
9 Updated 2 days ago
pcliangx AI & Automation Solid
verify-module
模块完���性校验关卡。扫描目录结构、检测缺失文档、验证代码与文档同步。当用户提到模块校验、文档检查、结构完整性、README检查、DESIGN检查时使用。在新建模块完成时自动触发。
5,403 Updated 2 days ago
fengshao1227