dev-vulnerability-patterns
程式碼漏洞模式資料庫。提供 Python/JS/Java/Go 語言特定的漏洞程式碼模式、CWE 分類、安全替代方案與嚴重度評估標準。適用於「漏洞模式」、「CWE」、「SQL Injection」、「XSS」、「安全漏洞」、「安全編碼」、「漏洞程式碼」等安全性審查任務。強化 security-analyst…
Skill by vincent119
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/vincent119-dev-vulnerability-patterns
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: backend, security
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/dev-vulnerability-patterns
What's inside
- Skill name
dev-vulnerability-patterns- Description
- 程式碼漏洞模式資料庫。提供 Python/JS/Java/Go 語言特定的漏洞程式碼模式、CWE 分類、安全替代方案與嚴重度評估標準。適用於「漏洞模式」、「CWE」、「SQL Injection」、「XSS」、「安全漏洞」、「安全編碼」、「漏洞程式碼」等安全性審查任務。強化 security-analyst 的分析能力。注意:滲透測試執行與 WAF 設定不在此技能範圍內。
- License
- Apache-2.0
- Instructions
- 257 lines in SKILL.md · view on GitHub
Files (1)
- SKILL.md
SKILL.md (first lines)
# Vulnerability Patterns — 程式碼漏洞模式資料庫
security-analyst 在安全性審查時使用的漏洞程式碼模式、CWE 分類與安全替代方案參考。
## 此技能的功能
- 提供 CWE Top 25 漏洞分類與優先偵測目標
- 提供 Python、JavaScript/TypeScript、Java、Go 的語言特定漏洞模式
- 每個漏洞附上安全替代方案
- 提供 CVSS v3.1 嚴重度評估標準
## 適用時機
- 執行安全性程式碼審查
- 識別特定語言的漏洞模式
- 搭配 `dev-code-reviewer` 技能使用
## 觸發範例
- 「這段 Python 程式碼有 SQL Injection 風險嗎?」
- 「檢查這個 Go 程式碼的 Path Traversal 漏洞」
- 「列出這段程式碼的 CWE 分類」
- 「這個 API 有沒有認證缺陷?」
---
## 漏洞分類系統(CWE Top 25)
### 優先偵測目標
| CWE | 名稱 | 嚴重度 | 頻率 |
|-----|------|--------|------|
| CWE-89 | SQL Injection | Critical | 高 |
| CWE-78 | OS Command Injection | Critical | 中 |
| CWE-798 | Hardcoded Credentials | Critical | 高 |
| CWE-862 | Missing Authorization | Critical | 高 |
| CWE-306 | Missing Authentication | Critical | 中 |
| CWE-502 | Insecure Deserialization | Critical | 中 |
| CWE-79 | XSS (Cross-Site Scripting) | High | 極高 |
| CWE-22 | Path Traversal | High | 中 |
| CWE-352 | CSRF | High | 高 |
| CWE-918 | SSRF | High | 中 |
---
## 語言特定漏洞模式
### Python
#### SQL Injection(CWE-89)
```python
# 漏洞
query = f"SELECT * FROM users WHERE name = '{user_input}'"
cursor.execute(query)
# 安全
cursor.execute("SELECT * FROM users WHERE name = %s", (user_input,))
# 或使用 ORM(SQLAlchemy、Django ORM)
```
#### Command Injection(CWE-78)
```python
# 漏洞
os.system(f"ping {user_input}")
subprocess.call(f"ls {user_input}", shell=True)
# 安全
subprocess.run(["ping", user_input], shell=False)
```
#### Path Traversal(CWE-22)
```python
# 漏洞
file_path = os.path.join(BASE_DIR, user_input)
open(file_path).read()
# 安全
file_path = os.path.realpath(os.path.join(BASE_DIR, user_input))
if not file_path.startswith(os.path.realpath(BASE_DIR)):
raise ValueError("Invalid path")
```
#### YAML Deserialization(CWE-502)
```python
# 漏洞
data = yaml.load(user_input) # 可能執行任意程式碼
# 安全
data = yaml.safe_load(user_input)
```
---
### JavaScript / TypeScript
#### XSS(CWE-79)
```javascript
// 漏洞(React)
<div dangerouslySetInnerHTML={{ __html: userInput }} />
// 安全
<div>{userInput}</div> // React 自動跳脫
// 必要時使用 DOMPurify
import DOMPurify from 'dompurify';
<div dangerouslySetInnerHTML={{ __html: DOMPurify.sanitize(userInput) }} />
```
#### Prototype Pollution(CWE-1321)
```javascript
// 漏洞
function merge(target, source) {
for (let key in source) {
target[key] = source[key]; // __proto__ 污染
}
}
// 安全
function merge(target, source) {
for (let key of Object.keys(source)) {From vincent119/ai-rules-kit, Apache-2.0.
More from vincent119/ai-rules-kit
- 0.526score
financial-health-risk
vincent119
財務健康風險分析完整流程。讀入財務報表(PDF 或數字),分析流動性、獲利能力、槓桿、現金流、Altman Z-Score、成長性,產出多維度風險評估報告與改善建議。適用於「財務健康檢查」、「分析這份財報」、「financial risk…
SkillBFreshness: BClaude Code +9 - 0.526score
sdd-skill
vincent119
SDD(Spec Driven Development)工作流程。用於在實作前建立 .specs 下的 requirements.md、design.md、tasks.md,規劃功能邊界、驗收條件、技術設計與實作任務,並在實作過程中依 tasks 追蹤進度。
SkillBFreshness: BClaude Code +9 - 0.524score
skill-creator
vincent119
Guide for creating effective skills.
SkillBFreshness: BClaude Code +9 - 0.523score
readme
vincent119
建立、改善或稽核 GitHub 專案的 README。僅在使用者明確要求 README、README 正確性、可讀性、範例或 README 稽核時使用;不處理完整文件站、純 API reference 或廣泛 repository 審查。
SkillBFreshness: BClaude Code +9 - 0.523score
technical-writing
vincent119
建立、改善或稽核 README 以外的技術文件,例如架構文件、操作手冊、教學、ADR 與概念說明。僅在使用者明確要求此類文件時使用;README 需求應使用 readme skill。
SkillBFreshness: BClaude Code +9 - 0.521score
pres-presentation-designer
vincent119
簡報設計完整製作流程。協調 5 個製作階段:故事結構 → 資訊設計 → 視覺設計 → 講者備稿 → 品質審查,最終產出完整的簡報套件。適用於「製作簡報」、「Presentation 規劃」、「PPT 製作」、「Slide Deck…
SkillBFreshness: BClaude Code +9 - 0.521score
pres-slide-layout-patterns
vincent119
投影片版面模式庫。提供 20 種投影片類型的最佳版面配置、格線系統、色彩與字型設計 Token。適用於「投影片版面」、「Slide Layout」、「設計系統」、「格線」、「字型」、「色彩規範」等投影片視覺設計任務。強化 visual-designer 的設計能力。注意:PPT/Keynote…
SkillBFreshness: BClaude Code +9 - 0.521score
dev-code-reviewer
vincent119
自動化程式碼審查完整流程。協調 4 個審查領域:風格、安全性、效能、架構,最終產出綜合審查報告。適用於「review this code」、「看一下這段程式碼」、「程式碼審查」、「PR review」、「程式碼品質分析」、「安全性審查」、「效能審查」、「架構審查」、「程式碼風格檢查」等任務。支援指定單一領域審查。注意…
SkillBFreshness: BClaude Code +9 - 0.521score
dev-refactoring-catalog
vincent119
程式碼重構目錄。提供基於 Martin Fowler 的重構模式、程式碼異味偵測到重構的對應、SOLID 原則違反識別,以及複雜度量測標準。適用於「重構」、「程式碼異味」、「SOLID 違反」、「複雜度」、「設計模式」、「程式碼品質」等程式碼結構改善審查任務。強化 architecture-reviewer 與…
SkillBFreshness: BClaude Code +9 - 0.521score
pres-data-visualization-guide
vincent119
資料視覺化圖表選擇指南與資訊架構設計。提供圖表選擇矩陣、LATCH 資訊組織原則、數字格式化規範與色彩無障礙標準。適用於「圖表選擇」、「資料視覺化」、「資訊設計」、「Chart 類型」、「數據說故事」等視覺化表達任務。強化 info-architect 的設計能力。注意:圖表 BI 工具操作不在此技能範圍內。
SkillBFreshness: BClaude Code +9 - 0.518score
react-hooks-state
vincent119
React Hooks 與狀態管理模式。用於自訂 Hooks 設計、useReducer 複雜狀態、Context 架構、Server State 整合、表單狀態處理。
SkillBFreshness: BClaude Code +9 - 0.518score
release-workflow
vincent119
Standard release workflow - Test, tag, push.
SkillBFreshness: BClaude Code +9
Signals
- Stars
- 0
- Forks
- 0
- Open issues
- 0
- Last commit (this folder)
- Sep 8, 2026 (1 month ago)
From GitHub (fetched Oct 24, 2026).
Details
- License
- Apache-2.0
- Repository
- github.com/vincent119/ai-rules-kit
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from vincent119
- 0.526score
financial-health-risk
vincent119
財務健康風險分析完整流程。讀入財務報表(PDF 或數字),分析流動性、獲利能力、槓桿、現金流、Altman Z-Score、成長性,產出多維度風險評估報告與改善建議。適用於「財務健康檢查」、「分析這份財報」、「financial risk…
SkillBFreshness: BClaude Code +9 - 0.526score
sdd-skill
vincent119
SDD(Spec Driven Development)工作流程。用於在實作前建立 .specs 下的 requirements.md、design.md、tasks.md,規劃功能邊界、驗收條件、技術設計與實作任務,並在實作過程中依 tasks 追蹤進度。
SkillBFreshness: BClaude Code +9 - 0.524score
skill-creator
vincent119
Guide for creating effective skills.
SkillBFreshness: BClaude Code +9 - 0.523score
readme
vincent119
建立、改善或稽核 GitHub 專案的 README。僅在使用者明確要求 README、README 正確性、可讀性、範例或 README 稽核時使用;不處理完整文件站、純 API reference 或廣泛 repository 審查。
SkillBFreshness: BClaude Code +9 - 0.523score
technical-writing
vincent119
建立、改善或稽核 README 以外的技術文件,例如架構文件、操作手冊、教學、ADR 與概念說明。僅在使用者明確要求此類文件時使用;README 需求應使用 readme skill。
SkillBFreshness: BClaude Code +9 - 0.521score
pres-presentation-designer
vincent119
簡報設計完整製作流程。協調 5 個製作階段:故事結構 → 資訊設計 → 視覺設計 → 講者備稿 → 品質審查,最終產出完整的簡報套件。適用於「製作簡報」、「Presentation 規劃」、「PPT 製作」、「Slide Deck…
SkillBFreshness: BClaude Code +9
Cite this page
dev-vulnerability-patterns skill. Agent Mart. https://agentmart.dev/skills/vincent119-dev-vulnerability-patterns (last updated 2026-10-24)