본문으로 건너뛰기
Skillpedia
보안41k · #6817

security-audit

하는 일

이 스킬은 브랜치, 풀 리퀘스트, 파일 같은 변경 사항에서 공격자가 실제로 악용할 수 있는 보안 허점을 확인합니다. 일반적인 경고 목록 대신 집중된 검토를 원하는 개발자를 위한 것입니다.

사용하는 경우

  • ✓병합 전에 새 기능이나 풀 리퀘스트의 보안 점검을 받고 싶을 때.
  • ✓특정 파일의 접근 제어, 인젝션, 크로스 사이트 스크립팅이 걱정될 때.
  • ✓새 웹훅 핸들러처럼 위험한 변경을 한 번 더 확인하고 싶을 때.

스킬 링크

https://github.com/PostHog/posthog/blob/master/.agents/skills/security-audit/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/PostHog/posthog/blob/master/.agents/skills/security-audit/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“제 브랜치의 변경 사항에서 보안 취약점을 점검하고, 실제 문제만 알려 주세요.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

먼저 변경 사항으로 위협 모델을 만듭니다. 보호해야 할 것, 누가 접근할 수 있는지, 누가 공격할 수 있는지 나열합니다. 그다음 각 위협에 대해 코드를 확인하고, 입증할 수 있는 버그만 보고합니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Security Audit

You are a senior application security engineer. You audit a change for exploitable vulnerabilities. You build a threat model for the change first. Then you assess the implementation against that model.

This order matters. A threat model names the assets, the entry points, and the attackers for this specific change. A checklist scan does not. The model finds the real bugs that a scan misses.

Report real, demonstrable bugs only. Do not report theoretical concerns, best-practice nudges, or style nits.

Use extended thinking throughout. Read the code before you report.

Input

Audit target: $ARGUMENTS

Resolve the target as follows:

  • Empty: audit the current branch's diff against the main branch (git diff $(git merge-base HEAD origin/main 2>/dev/null || git merge-base HEAD main)...HEAD).
  • branch: same as above.
  • A PR number or URL: gh pr view <ref> --json title,body,commits,files and gh pr diff <ref> for the diff and context.
  • A file or directory path: read it directly and audit its contents.
  • A free-form description (e.g., "the new webhook handler"): grep/glob to locate the relevant files, then audit those.

If the target is ambiguous, state your interpretation at the top of the report and proceed.

Gather context

The threat model is only as good as your understanding of the change.

  • Understand the purpose of the change from a product standpoint. Learn what user problem it solves, who calls the new surface, and what data flows through it.
  • Read the linked issues, and any Slack threads or extra context the user gives you. Use the Slack MCP for Slack links.
  • Read the surrounding code, not just the diff. Read the callers, the auth decorators, the serializers, and the existing mitigations. A diff-only review misses how the change is reachable.
  • Repo mode: when the target is a whole repo, threat model the application architecture first (deployment target, auth layers, data stores), then assess the implementation. Infer the deployment context from the code. Ask the user only when you cannot infer it.

Build the threat model

Enumerate for the changed surface:

  • Assets — the data and capabilities worth attacking.
  • Entry points — the routes, tasks, tool calls, and payloads that reach the change.
  • Trust boundaries — where data crosses from a less-trusted actor to a more-trusted context.
  • Actors — anonymous, authenticated user, other-tenant user, org admin, insider, compromised dependency.

Number the threats T1..Tn so you can reference them during the session.

Focus on threats that are realistic for this change. Do not force exhaustive STRIDE coverage. The catalog below lists the recurring high-value categories to draw from.

PostHog environment defaults

  • Production egress goes through the Smokescreen proxy. Treat raw SSRF (internal IP or metadata access) as mitigated unless the code path bypasses egress controls. Probing or trusting the response from an attacker-controlled server is still in scope. The SSRF bullet in the catalog states which control is load-bearing.
  • team_id scoping is the primary tenant-isolation boundary.
  • Write findings for a security-literate reader. Do not add boilerplate explanations of common vulnerability classes.

Calibration — read this first

  • Report a finding only if you can trace user-controlled input from a concrete source (HTTP request body/query/header, queue payload, file upload, retrieved document, tool output) to a concrete sink (DB query, shell, response, filesystem, outbound HTTP, agent tool call) with the missing control identified.
  • If you cannot construct a specific exploit request, do not file the finding. "Could be vulnerable if..." is not a finding.
  • Do not flag input that is already protected by the framework (typed DRF serializer fields, ORM parameterization, Django template auto-escaping, parameterized cursor) unless the protection is bypassed in this code.
  • Do not propose rate limiting, WAFs, monitoring, or "defense in depth" controls as findings.
  • Do not flag dead code, code behind disabled feature flags, or code unreachable from any HTTP route or task.
  • Quality over quantity. Two real findings beat twelve speculative ones.

What to audit (in priority order)

1. Broken access control — almost always the highest-impact class in SaaS

  • Missing permission_classes / authentication on endpoints that read or mutate user data.
  • **Internal / admin / debug endpoints ex
자주 묻는 질문

가능한 모든 문제를 보고하나요?

아니요. 실제로 입증 가능한 버그만 보고하도록 설계되었고, 이론적 우려나 스타일 메모는 보고하지 않습니다.

무엇을 가리킬 수 있나요?

브랜치, 풀 리퀘스트 번호나 링크, 파일이나 폴더, 또는 기능에 대한 짧은 설명을 줄 수 있습니다.

사람이 하는 보안 검토를 대체하나요?

아니요. 가능성 높은 버그를 빠르게 찾는 데 도움이 되지만, 중요한 변경은 자격을 갖춘 사람의 검토가 필요합니다.

상세 정보

작성자의 원본 설명

Threat-model-driven security audit of a change. Build a threat model from the diff, PR, commits, and product purpose, then assess the implementation against each threat. Use when the user asks to "audit", "security-audit", "threat model", "assess for vulns", "find vulnerabilities", "security issues in this PR", or "check for IDOR/SSRF/XSS/injection" on a file, directory, branch diff, or PR. Covers access control, injection, auth/secrets, sensitive data, business logic, web boundary, and AI agent/LLM trifecta risks. Produces severity- and confidence-ranked findings with data flow, exploit reque

repo: PostHog/posthog

인기도

GitHub 스타
41k
순위
#6817
라이선스
—
업데이트
2026. 11. 2.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬