Logo Repo Security Audit

Repo Security Audit

Cộng đồng
valorisa
repo-security-audit

Use this skill when the user asks to "audit repo", "analyze repository", "find bugs", "find gaps", "review codebase", "check code quality", or wants to analyze a repository for bugs, missing features, test coverage gaps, security issues and create GitHub issues for findings. Performs a deep technical audit and optionally opens GitHub issues for high-priority problems.

Tổng quan

Nhà phát hànhvalorisa
Kho mãClaude-Skills
Tên kỹ năngrepo-security-audit
Sao
20
Bản fork
5
Tệp đi kèm
Chỉ có hướng dẫn
Giấy phépMIT
Liên kết
  • Hướng dẫn bằng Markdown

    Tệp SKILL.md được mô hình tải khi cần, nên chỉ tốn token khi có yêu cầu thực sự phù hợp.

  • Dùng được với mọi LLM

    Kỹ năng AI dùng hướng dẫn viết bằng Markdown thay vì mã dành riêng cho một nhà cung cấp, nên dùng được với GPT, Claude, Gemini, Grok hoặc mô hình cục bộ.

  • Hướng dẫn có đủ mọi thứ cần thiết

    Mọi thứ mô hình cần đều nằm trong hướng dẫn — không có tệp bổ sung cần đồng bộ.

  • Mã nguồn mở

    Được valorisa công bố trên GitHub. Hãy đọc các tệp nguồn trước khi cài đặt.

Cài đặt

Cài đặt kỹ năng AI Repo Security Audit trong TypingMind để dùng với bất kỳ LLM nào, hoặc thêm vào một tác nhân AI khác có thể đọc SKILL.md.

1

Cài đặt trong TypingMind

TypingMind cài đặt kỹ năng trực tiếp từ thư mục GitHub — đọc SKILL.md, đóng gói các tệp tài nguyên và lưu kết quả trên máy.

  1. Mở ứng dụng và vào Plugin → Kỹ năng.
  2. Chọn "Cài đặt từ GitHub".
  3. Dán URL của thư mục kỹ năng được hiển thị bên dưới rồi xác nhận.
    https://github.com/valorisa/Claude-Skills/tree/main/skills/repo-security-audit
  4. Bật kỹ năng trong từng cuộc trò chuyện mà bạn muốn sử dụng kỹ năng đó.
Plugin → Kỹ năng → Thêm kỹ năng → Từ URL GitHub, sau đó dán URL thư mục và nhấn Tiếp tục.
2

Cài đặt trong tác nhân AI khác

Bất kỳ tác nhân AI nào đọc được định dạng Agent Skills đều có thể dùng kỹ năng này — hãy sao chép thư mục vào thư mục kỹ năng của tác nhân AI đó.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/valorisa/Claude-Skills.git /tmp/Claude-Skills
mkdir -p .claude/skills
cp -r /tmp/Claude-Skills/skills/repo-security-audit .claude/skills/repo-security-audit
Khởi động lại Claude Code sau khi sao chép để ứng dụng nhận kỹ năng mới.

Sử dụng trong TypingMind

Bật Repo Security Audit trong bất kỳ cuộc trò chuyện nào trên TypingMind, mô hình sẽ tự xử lý phần còn lại. Tên và mô tả của kỹ năng nằm trong prompt hệ thống. Ngay khi có yêu cầu phù hợp, mô hình tự tải toàn bộ hướng dẫn — bạn không cần gọi thủ công và kỹ năng không tốn token cho đến khi thực sự được dùng.

Mô hình tự nạp Repo Security Audit ngay khi có yêu cầu phù hợp.

Dùng được với mọi mô hình AI

Kỹ năng AI là các hướng dẫn Markdown thuần túy, không phải mã dành riêng cho một nhà cung cấp, nên bạn có thể dùng Repo Security Audit với cả những mô hình khác ngoài mô hình ban đầu. Chỉ cần cài đặt một lần trong TypingMind rồi dùng với GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama hoặc mô hình cục bộ do bạn tự chạy — tất cả đều dùng khóa API của riêng bạn.

  • Chỉ tải khi cần

    Prompt hệ thống chỉ chứa tên và mô tả. Hướng dẫn được tải khi có yêu cầu phù hợp đầu tiên, nên khi kỹ năng chưa được dùng, bạn không tốn token cho phần hướng dẫn.

  • Đổi mô hình ngay trong cuộc trò chuyện

    Vì kỹ năng là hướng dẫn chứ không phải mã, việc đổi mô hình không làm kỹ năng ngừng hoạt động — mô hình tiếp theo vẫn đọc cùng tệp SKILL.md.

Hướng dẫn của kỹ năng

Đây là nội dung SKILL.md mà mô hình tải. Hãy đọc trước khi cài đặt — kỹ năng là những hướng dẫn mà mô hình của bạn sẽ làm theo.

Repo Audit

Perform a deep technical audit of a repository: find bugs, gaps, missing tests, security issues, and API design problems. Optionally create GitHub issues for findings.

Make a todo list and track progress through all steps.


Step 0 — Determine target

If the user provided a GitHub URL (e.g. https://github.com/owner/repo), extract owner/repo.

If the user provided a local path, use that directly.

If neither was provided, use the current working directory as the target.

Ask the user: "Should I create GitHub issues for high-priority findings?" before proceeding if not already specified.


Step 1 — Explore repository structure

Read the repository to understand its purpose and architecture:

bash
gh repo view <owner/repo>

Then explore locally (if available) or via GitHub API:

  1. Read README.md to understand the project's goals and documented features
  2. Read pyproject.toml / package.json / go.mod / Cargo.toml to identify language, dependencies and version
  3. List source files and test files to understand coverage ratio
  4. Read the main entry point and core modules

Build a mental model of:

  • What the project does
  • Tech stack and architecture
  • Execution modes or major features
  • How tests are organized

Step 2 — Deep code analysis

Systematically read and analyze the source code. For each module, check for:

Bugs

  • Logic errors in conditionals, setters, or property accessors
  • Incorrect use of standard library (e.g. isinstance with typing types instead of abc)
  • Wrong argument order in function calls
  • sys.modules or import cache misuse
  • Race conditions in threaded/async code
  • Off-by-one errors in counters or indices

Performance Issues

  • Busy-wait loops (while loops without sleep/blocking)
  • Missing connection pooling or caching
  • Redundant re-computation inside loops
  • Unbounded memory growth (queues, lists, caches)

Security Issues

  • Dynamic code execution (exec, eval, exec_module) without input validation
  • World-readable file/directory creation without permission mode
  • Serialization of untrusted data (pickle, JSON from user input)
  • Credentials or secrets hardcoded or logged

API Design Issues

  • Return type annotations that don't match actual return values
  • Inconsistent method naming or behavior across similar methods
  • Methods that silently swallow exceptions during retries
  • Missing input validation at public API boundaries
  • Unclear or undocumented side effects

Test Coverage Gaps

  • Features documented in README but with no tests
  • CLI commands with no integration tests
  • Timeout and retry logic with no verification tests
  • Platform-specific code paths never exercised

Documentation Gaps

  • Features implemented but not mentioned in README
  • Behavior that contradicts documentation
  • Missing examples for non-obvious configuration options

Step 3 — Compile findings

Organize findings into four severity tiers:

Critical (runtime failures, data loss, security)

These break the software or expose serious vulnerabilities. Include:

  • File path and line number
  • What the bug is
  • Why it fails
  • Suggested fix (code snippet)

High Priority (incorrect behavior, performance, API breakage)

These cause incorrect behavior under common use cases or degrade performance significantly.

Medium Priority (missing features, coverage gaps, bad UX)

These don't break existing functionality but limit reliability or usability.

Low / Nice-to-have (style, docs, minor improvements)

Small improvements that improve maintainability or developer experience.


Step 4 — Present summary to user

Show a structured report:

## Audit Summary — <repo name>

### Critical Bugs (N)
- [file.py:line] Short description

### High Priority (N)
- [file.py:line] Short description

### Medium Priority (N)
- Short description

### Test Coverage Gaps (N)
- Short description

### Security Concerns (N)
- Short description

Ask the user: "Which severity levels should I open GitHub issues for?" Default (if not specified): Critical + High Priority only.


Step 5 — Create GitHub issues (if confirmed)

For each finding in the selected severity tiers, create a GitHub issue using:

bash
gh issue create --repo <owner/repo> \
  --title "<short descriptive title>" \
  --body "<full markdown body>"

Each issue body must follow this structure:

markdown
## Description

<One paragraph explaining the problem clearly.>

## Location

`<file/module>` line ~<N>

## Current Behavior

<Code snippet showing the problematic code>

<Explanation of what it does wrong>

## Expected Behavior

<What it should do instead>

## Suggested Fix

<Code snippet with the fix>

## Impact

<Who is affected and how severely>

## Priority

<Critical / High / Medium>

Rules:

  • Write all issues in English
  • One issue per finding (do not bundle unrelated problems)
  • Do not mention AI or automated tools in the issue body
  • Keep titles under 80 characters, specific and actionable
  • Use inline code formatting for file paths and function names

Step 6 — Final report

After creating all issues, show the user a summary table:

IssueTitleSeverity
#NtitleCritical
#NtitleHigh

Then suggest next steps:

  • Which critical bugs to fix first
  • Whether a 1.0 release is advisable given the findings
  • Any architectural changes worth considering

Voici une version corrigée en un seul bloc, avec les blancs nécessaires autour des titres et des listes pour satisfaire MD022 et MD032.

markdown
---
allowed-tools: Bash(gh issue create:*), Bash(gh issue list:*), Bash(gh repo view:*), Bash(gh api:*), Bash(git log:*), Bash(git diff:*), Bash(find:*), Bash(cat:*), Bash(grep:*), Bash(jq:*), Read, Glob, Grep, Agent, WebFetch
description: Use this skill when the user asks to "audit repo", "analyze repository", "find bugs", "find gaps", "review codebase", "check code quality", or wants to analyze a repository for bugs, missing features, test coverage gaps, security issues and create GitHub issues for findings. Performs a deep technical audit and optionally opens GitHub issues for high-priority problems.
version: 1.0.0
---

# Repo Audit

Perform a deep technical audit of a repository: find bugs, gaps, missing tests, security issues, and API design problems. Optionally create GitHub issues for findings.

Make a todo list and track progress through all steps.

---

## Step 0 — Determine target

If the user provided a GitHub URL (e.g. `https://github.com/owner/repo`), extract `owner/repo`.

If the user provided a local path, use that directly.

If neither was provided, use the current working directory as the target.

Ask the user: **"Should I create GitHub issues for high-priority findings?"** before proceeding if not already specified.

---

## Step 1 — Explore repository structure

Read the repository to understand its purpose and architecture:

```bash
gh repo view <owner/repo>

Then explore locally (if available) or via GitHub API:

  1. Read README.md to understand the project's goals and documented features
  2. Read pyproject.toml / package.json / go.mod / Cargo.toml to identify language, dependencies and version
  3. List source files and test files to understand coverage ratio
  4. Read the main entry point and core modules

Build a mental model of:

  • What the project does
  • Tech stack and architecture
  • Execution modes or major features
  • How tests are organized

Step 2 — Deep code analysis

Systematically read and analyze the source code. For each module, check for:

Bugs

  • Logic errors in conditionals, setters, or property accessors
  • Incorrect use of standard library (e.g. isinstance with typing types instead of abc)
  • Wrong argument order in function calls
  • sys.modules or import cache misuse
  • Race conditions in threaded/async code
  • Off-by-one errors in counters or indices

Performance Issues

  • Busy-wait loops (while loops without sleep/blocking)
  • Missing connection pooling or caching
  • Redundant re-computation inside loops
  • Unbounded memory growth (queues, lists, caches)

Security Issues

  • Dynamic code execution (exec, eval, exec_module) without input validation
  • World-readable file/directory creation without permission mode
  • Serialization of untrusted data (pickle, JSON from user input)
  • Credentials or secrets hardcoded or logged

API Design Issues

  • Return type annotations that don't match actual return values
  • Inconsistent method naming or behavior across similar methods
  • Methods that silently swallow exceptions during retries
  • Missing input validation at public API boundaries
  • Unclear or undocumented side effects

Test Coverage Gaps

  • Features documented in README but with no tests
  • CLI commands with no integration tests
  • Timeout and retry logic with no verification tests
  • Platform-specific code paths never exercised

Documentation Gaps

  • Features implemented but not mentioned in README
  • Behavior that contradicts documentation
  • Missing examples for non-obvious configuration options

Step 3 — Compile findings

Organize findings into four severity tiers:

Critical (runtime failures, data loss, security)

These break the software or expose serious vulnerabilities. Include:

  • File path and line number
  • What the bug is
  • Why it fails
  • Suggested fix (code snippet)

High Priority (incorrect behavior, performance, API breakage)

These cause incorrect behavior under common use cases or degrade performance significantly.

Medium Priority (missing features, coverage gaps, bad UX)

These don't break existing functionality but limit reliability or usability.

Low / Nice-to-have (style, docs, minor improvements)

Small improvements that improve maintainability or developer experience.


Step 4 — Present summary to user

Show a structured report:

markdown
## Audit Summary — <repo name>

### Critical Bugs (N)
- [file.py:line] Short description

### High Priority (N)
- [file.py:line] Short description

### Medium Priority (N)
- Short description

### Test Coverage Gaps (N)
- Short description

### Security Concerns (N)
- Short description

Ask the user: "Which severity levels should I open GitHub issues for?"

Default (if not specified): Critical + High Priority only.


Step 5 — Create GitHub issues (if confirmed)

For each finding in the selected severity tiers, create a GitHub issue using:

bash
gh issue create --repo <owner/repo> \
  --title "<short descriptive title>" \
  --body "<full markdown body>"

Each issue body must follow this structure:

markdown
## Description

<One paragraph explaining the problem clearly.>

## Location

`<file/module>` line ~<N>

## Current Behavior

<Code snippet showing the problematic code>

<Explanation of what it does wrong>

## Expected Behavior

<What it should do instead>

## Suggested Fix

<Code snippet with the fix>

## Impact

<Who is affected and how severely>

## Priority

<Critical / High / Medium>

Rules:

  • Write all issues in English
  • One issue per finding (do not bundle unrelated problems)
  • Do not mention AI or automated tools in the issue body
  • Keep titles under 80 characters, specific and actionable
  • Use inline code formatting for file paths and function names

Step 6 — Final report

After creating all issues, show the user a summary table:

IssueTitleSeverity
#NtitleCritical
#NtitleHigh

Then suggest next steps:

  • Which critical bugs to fix first
  • Whether a 1.0 release is advisable given the findings
  • Any architectural changes worth considering

Câu hỏi thường gặp

Kỹ năng AI Repo Security Audit làm được gì?

Use this skill when the user asks to "audit repo", "analyze repository", "find bugs", "find gaps", "review codebase", "check code quality", or wants to analyze a repository for bugs, missing features, test coverage gaps, security issues and create GitHub issues for findings. Performs a deep technical audit and optionally opens GitHub issues for high-priority problems.

Vì sao nên dùng Repo Security Audit trên TypingMind?

Vì bạn chỉ cần cài một lần rồi dùng với bất kỳ mô hình nào. Repo Security Audit là nội dung Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên cùng một kỹ năng có thể chạy trên GPT-5, Claude, Gemini, Grok hoặc mô hình trên thiết bị — và bạn có thể đổi mô hình ngay trong cuộc trò chuyện mà kỹ năng vẫn hoạt động. TypingMind dùng khóa API riêng của bạn, nên bạn thanh toán trực tiếp cho nhà cung cấp thay vì trả phí thuê bao theo suất người dùng, đồng thời kỹ năng và các cuộc trò chuyện vẫn nằm trong bộ lưu trữ của bạn.

Làm thế nào để cài Repo Security Audit trong TypingMind?

Mở Plugin → Kỹ năng → Cài đặt từ GitHub trong TypingMind rồi dán https://github.com/valorisa/Claude-Skills/tree/main/skills/repo-security-audit. TypingMind đọc tệp SKILL.md rồi cài đặt kỹ năng để bạn có thể bật cho từng cuộc trò chuyện.

Những mô hình AI nào có thể dùng Repo Security Audit?

Bất kỳ mô hình nào bạn kết nối trong TypingMind. Kỹ năng AI là các hướng dẫn bằng Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên GPT, Claude, Gemini, Grok và các mô hình chạy trên thiết bị đều có thể tải kỹ năng này khi có yêu cầu phù hợp.

Có thể dùng Repo Security Audit với bao nhiêu mô hình AI?

Bao nhiêu cũng được. Miễn là mô hình hỗ trợ kỹ năng, bạn có thể dùng Repo Security Audit với mô hình đó — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama và nhiều mô hình khác — tất cả đều trên TypingMind với khóa API riêng của bạn.

Kỹ năng AI Repo Security Audit có miễn phí không?

Có. Kỹ năng này được valorisa phát hành trên GitHub theo giấy phép MIT. Bạn chỉ trả tiền cho nhà cung cấp AI của mình theo số token đã dùng.

Kỹ năng AI là gì?

Kỹ năng AI là một gói hướng dẫn có thể tái sử dụng, chỉ cho mô hình AI cách thực hiện một tác vụ cụ thể. Kỹ năng tuân theo định dạng mở Agent Skills: một tệp SKILL.md chứa tên và mô tả, cùng các tập lệnh, mẫu hoặc tệp tham khảo mà mô hình có thể cần. Mô hình chỉ đọc hướng dẫn khi yêu cầu của bạn phù hợp với kỹ năng, nên kỹ năng đã cài đặt không phát sinh chi phí cho đến khi được sử dụng.

Kỹ năng AI khác gì với plugin hoặc máy chủ MCP?

Plugin hoặc máy chủ MCP cung cấp các công cụ mới mà mô hình có thể gọi. Khi mô hình gọi một công cụ, mã của công cụ đó chạy ở đâu đó và trả về kết quả. Còn kỹ năng AI cung cấp kiến thức và quy trình: cách tiếp cận tác vụ, các bước cần thực hiện và những tiêu chí mà kết quả cần đáp ứng. Kỹ năng chỉ là nội dung Markdown, nên không cần máy chủ, khóa API hay môi trường thực thi và hoạt động với mọi mô hình.

Xem tất cả

Tạo ngay không gian làm việc AI riêng

Đăng ký bản tin của chúng tôi để nhận thông báo về tính năng mới và các đợt tặng quà sắp tới 👇