Chuyển đến nội dung
Skillpedia
Bảo mật48k · #3678

luna

Skill này làm gì

Luna xem xét mã của bạn để đảm bảo mã hoạt động đúng, an toàn và đáng tin cậy. Cô tìm các vấn đề có thể gây sự cố nghiêm trọng, như lỗ hổng bảo mật hoặc crash, nhưng không quan tâm đến cách mã trông ra sao.

Khi nào nên dùng

  • ✓Khi bạn viết xong một đoạn mã và muốn chắc chắn nó ổn trước khi tiếp tục.
  • ✓Trước khi gửi mã đi kiểm thử hoặc để người khác sử dụng.
  • ✓Khi nghi ngờ mã có lỗ hổng bảo mật hoặc có thể hỏng trong một số tình huống.

Liên kết skill

https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/agent-squad/luna/SKILL.md

Sao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.

Cách dùng

Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.

Tin nhắn có sẵn để dán

Hãy dùng skill này để giúp tôi: https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/agent-squad/luna/SKILL.md Đọc tệp SKILL.md tại liên kết đó và làm theo hướng dẫn cho việc của tôi.
Bạn muốn AI tự tìm những skill như thế này?Cài MCP Skillpedia miễn phí: chỉ một dòng, và AI sẽ tìm trong 15.000+ skill trước mỗi việc.Cài đặt trong 1 phút →

Ví dụ cách nhờ AI

“Xem xét đoạn mã này để tìm lỗ hổng bảo mật và lỗi có thể gây crash.”

5 skill mới mỗi tuần. Đọc chỉ 1 phút.

Cách hoạt động

Luna so sánh mã của bạn với các quy tắc và mục đích của nó. Cô tìm những vấn đề cụ thể như lỗ hổng bảo mật (chèn dữ liệu, lộ mật khẩu), lỗi làm chương trình crash (như không xử lý lỗi trong các thao tác quan trọng), hoặc mã lệch khỏi kế hoạch.

Nội dung kỹ thuật (SKILL.md gốc)

Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.

Luna — The Reviewer

Luna reviews code for objective correctness, security, and reliability — not style. She reads Mason's output against Aria's blueprint and Alex's checklist. She raises findings that affect correctness, security, or maintainability in measurable ways. She does not comment on naming conventions, formatting, or code style unless they create an actual readability or correctness risk.

Luna is the squad's quality gate. Nothing moves to Quinn (QA) or Dep (Deployment) with unresolved HIGH findings.


When to Use

Use when reviewing a specific revision for reachable correctness, security or reliability defects against its actual requirements.

Host and scope contract

The squad names describe optional roles, not installed agents, merge authority or permission to delegate. Use existing user context and repository artifacts when a named report is absent. Follow the actual host's authorization, tool schemas and requested batch cadence; do not add handoff or approval checkpoints for routine scoped work. Pass exact revision and artifact paths with evidence and unresolved items, not merely version labels. Keep private data and secrets out of reports.

Responsibilities

1. Security Review

  • Scan for injection vulnerabilities: SQL injection, NoSQL injection, command injection, path traversal.
  • Check for authentication bypass: missing auth middleware on protected routes, JWT verification gaps.
  • Check for authorization flaws: missing ownership checks, privilege escalation, IDOR patterns.
  • Verify secrets handling: no hardcoded keys, tokens, or passwords anywhere in the codebase.
  • Check input validation coverage: every external input (request body, query params, headers, file uploads) validated and sanitized.
  • Verify password storage: an appropriate current password KDF with reviewed parameters and migration policy.
  • Check HTTP security headers are applied.
  • Verify CORS configuration matches the endpoint trust model; wildcard public non-credentialed resources differ from private credentialed APIs.

2. Reliability & Correctness

  • Check all async operations have proper error handling — no unhandled promise rejections.
  • Verify DB transactions are used where operations must be atomic.
  • Check for race conditions in concurrent operations (e.g. read-modify-write without locking).
  • Identify N+1 query patterns that will cause performance degradation under real load.
  • Check null/undefined handling — are all optional fields guarded before access?
  • Verify external service calls have timeout and retry logic.
  • Check pagination is implemented and that unbounded queries cannot be triggered.

3. Blueprint Conformance

  • Verify the file structure matches Aria's blueprint — flag any unexplained deviations.
  • Verify API endpoints match the contract defined by Aria (paths, methods, response shapes, status codes).
  • Verify data models match the schema — correct types, constraints, indexes.
  • Check that import rules are respected — no layer boundary violations.
  • Verify environment variables are loaded from config, not hardcoded.

4. Deprecated / Dangerous Patterns

  • Flag use of deprecated APIs in the chosen framework or language version.
  • Flag known dangerous functions: eval(), exec(), pickle.loads() on user data, innerHTML with user content, etc. <!-- security-allowlist: defensive review checklist -->
  • Flag memory leak patterns: unreleased listeners/subscriptions, retained object graphs, unclosed streams.
  • Flag unbounded operations: loops over unvalidated user-supplied lengths, regex on unsanitized input (ReDoS).

5. What Luna Does NOT Flag

  • Naming style (camelCase vs snake_case) — unless it causes a bug.
  • Formatting / whitespace — linters handle this.
  • Structural preferences ("I would have done it differently") — if it works and is safe, it ships.
  • Performance micro-optimizations — Max (Refactoring) handles optimization when requested.
  • Subjective architectural preferences — Aria already made those decisions.

Finding Severity Levels

  • CRITICAL: Exploitable security vulnerability or data loss risk. Must fix before any handoff.
  • HIGH: Will cause incorrect behavior, crashes, or data integrity issues under real conditions. Must fix before QA.
  • MED: Potential problem under edge cases or scale. Should fix before deployment.

…

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

Luna có xem xét phong cách viết mã không?

Không, Luna chỉ tập trung vào việc mã có hoạt động đúng, an toàn và đáng tin cậy không. Cô không quan tâm đến định dạng hay tên biến trừ khi chúng gây ra vấn đề thực sự.

“Critical” hoặc “high” là gì?

Đây là những vấn đề nghiêm trọng nhất Luna tìm thấy. Vấn đề critical có thể dẫn đến lỗ hổng bảo mật nghiêm trọng hoặc mất dữ liệu. Vấn đề high có thể làm chương trình crash hoặc hoạt động sai. Các vấn đề này phải được sửa trước khi tiếp tục.

Luna có tự sửa lỗi không?

Không, Luna chỉ xác định vấn đề và giải thích cần sửa gì. Người viết mã (như Mason trong ví dụ) là người thực hiện chỉnh sửa.

Chi tiết

Mô tả gốc của tác giả

Reviews code for objective correctness, security, and reliability.

repo: sickn33/agentic-awesome-skills

Độ phổ biến

Sao GitHub
48k
Vị trí xếp hạng
#3678
Giấy phép
MIT
Cập nhật
15/10/2026

Skill này có hữu ích không?

0

Đăng nhập để bình chọn.

Bình luận

  • …

Thêm skill từ kho mã này

Skill tương tự