Find Security Vulnerabilities In Code

作者 usestrix469529068290Apache-2.067K 個星標收錄於 2026年10月8日更新於 2026年10月8日儲存庫今天更新

Find security vulnerabilities in a codebase or repository with Strix — a white-box AI security review that reads your source, reasons about the actual data flow and authorization model, then exploits what it finds in a live sandbox so every reported issue has a working proof-of-concept instead of a noisy static-analysis alert. Covers injection, XSS, SSRF, broken access control and IDOR, insecure deserialization, secrets in code, unsafe dependencies, and business-logic flaws. Use when the user asks to security-scan, security-review, or audit their code, repo, or pull request for vulnerabilities.

僅含說明Security
AI 產生的概覽

指導使用 Strix 進行白箱 AI 安全審查,在程式碼庫中找出並驗證可利用的漏洞。

功能
此技能指導代理對本機工作目錄、GitHub 儲存庫或特定服務子目錄執行白箱安全審查工具 Strix。代理會閱讀原始碼以建立路由、危險匯點與授權檢查的模型,接著在沙箱中嘗試實際利用,產出附有概念驗證證據的發現。輸出會寫入執行目錄,包括滲透測試報告、每個發現的 Markdown 檔案、JSON/CSV 漏洞清單與 SARIF 檔案。內容也涵蓋審查範圍界定、以差異為基礎的審查、結果解讀,以及互補的相依性與機密掃描。
適用情境
當使用者要求對程式碼庫、儲存庫或提取要求進行安全掃描、安全審查或漏洞稽核時使用。適用於注入、XSS、SSRF、存取控制缺陷與 IDOR、不安全反序列化、程式碼中的機密、不安全的相依套件,以及業務邏輯缺陷的檢查。它著重於經漏洞利用驗證的審查,而非窮盡式清單。
執行需求
需要 Strix 執行檔;本機執行還需要 Docker 與 LLM 金鑰。受管雲端路徑不需要 Docker 與 LLM 金鑰,但需要 Strix 雲端登入。存取遠端儲存庫與使用雲端服務需要網路連線。此技能未附帶指令碼,僅提供說明與命令範例。

Find security vulnerabilities in code

White-box security review with Strix: the agents read the source to build a model of routes, sinks, and authorization checks, then attempt real exploitation. Findings come with a proof-of-concept, so the output is a short list of proven issues rather than the hundreds of "potential" hits a pattern-matching scanner produces.

Install, LLM setup, all flags, and the managed-cloud path are in the penetration-testing-with-strix skill. For a run with no Docker and no LLM key, the same binary drives the managed platform: strix cloud login, then strix cloud scans start ... (details in managed-pentesting-with-strix).

Run it

bash
# Local working treestrix -n -t ./ --scan-mode standard --max-budget 15
# A GitHub repo directlystrix -n -t https://github.com/org/app --max-budget 15
# Monorepo: point at the service that matters, not the whole treestrix -n -t ./services/checkout --max-budget 20
# Only what a branch changed (whole-repo review is wasteful on a large repo)strix -n -t ./ --scope-mode diff --diff-base origin/main --max-budget 10

A local path is mounted into the sandbox writable, so the agents can modify it. Run against a clean checkout.

Two things sharply improve results:

  1. Add a running instance of the app. -t ./ -t http://host.docker.internal:3000 lets the agents confirm exploitability against live behavior instead of reasoning about it statically — this is the difference between "this looks unsafe" and a validated finding. If nothing is running, static-only findings should be described as unconfirmed.
  2. Scope the review. Point at the risky subtree and say what matters:
    bash
    strix -n -t ./services/api --max-budget 15 \  --instruction "Focus on the authorization layer in src/auth and every route under src/routes/admin. Multi-tenant app: tenant id comes from the JWT. Flag any query that filters by object id without also filtering by tenant."
    Tenancy model, trust boundaries, and which inputs are attacker-controlled are things the agents cannot infer reliably — tell them.

Reviewing a pull request instead of the whole repo

For diff-scoped review of a branch or PR (and blocking merges on findings), use ci-security-scanning-with-strix — it covers diff scoping, PR comments, and SARIF upload to GitHub code scanning. The managed platform can also review PRs directly via API (managed-pentesting-with-strix).

Read the results

In strix_runs/<run>/: penetration_test_report.md (start here), vulnerabilities/*.md (one per finding, with PoC and remediation), vulnerabilities.json / .csv, findings.sarif (upload to code scanning), run.json.

Before reporting to the user, open each finding and check the PoC actually demonstrates impact. Report file and line alongside the exploit so the fix is obvious.

Exit 0 means nothing exploitable was proven in what was analyzed — not that the codebase is clean. Check run.json status and cost against --max-budget, and note which paths went unreviewed if the run was capped.

Complementary tooling

This is exploit-validated review, not an exhaustive inventory. Keep a dependency scanner (SCA) and secret scanning in place for complete coverage of known-CVE dependencies and committed credentials; use this for the logic, authorization, and injection bugs those tools structurally cannot find.

Fix and verify

Hand results to fix-security-vulnerabilities-with-strix: patch the root cause (the shared authorization helper, not the one route), then re-run Strix to prove the exploit no longer works.

來源與署名

來源:usestrix/strix位於skills/find-security-vulnerabilities-in-code提交4695290

授權條款: Apache-2.0

內容歸原作者所有。SourceWeft 從公開儲存庫中收錄這些內容。

檢舉或申請下架