SafeWeave

dev.safeweave由 safeweave.dev 發布官方發布者v0.7.5更新於 Oct 27, 2026

Security scanner for AI-written code: SAST, secrets, dependencies, IaC, containers and DAST.

已驗證Streamable HTTP可網頁執行開發者工具安全與監控

概覽

AI 產生的概覽

SafeWeave 是針對 AI 撰寫程式碼的安全掃描器,讓助理掃描專案中的漏洞、外洩密鑰、風險相依套件、IaC 與容器問題,並在同一輪對話中修正。

可以做什麼
  • 掃描原始碼中的 SQL 注入、XSS、SSRF、路徑穿越與不安全加密等漏洞
  • 偵測原始碼中硬編碼的密鑰、API key、權杖與私鑰
  • 檢查 npm、pip、Go 與 Cargo 相依套件的已知 CVE 與高風險授權
  • 掃描 Terraform、Dockerfile、Kubernetes 設定、容器映像與 API 安全態勢
  • 套用 standard、hardened、owasp、soc2、pci-dss、hipaa 等合規設定檔
  • 在付費雲端方案下對執行中的應用程式進行 DAST 執行期掃描
適用情境
適合在提交、推送或建立 PR 之前,讓助理檢查剛寫好的程式碼並當場修正問題;也適合在支援 MCP 的編輯器中定期檢查相依套件、密鑰與基礎設施設定。
執行需求
可作為遠端端點使用,也可透過 npx 執行本機 npm 套件 safeweave-mcp,或以 Docker 搭配 SSE 執行。宣告需要 OAuth;SAFEWEAVE_LICENSE_KEY 為選用(無金鑰為 10 次試用,免費帳號可解鎖 7 個本機掃描器,付費方案提供 DAST 與託管掃描)。首次使用會下載掃描器二進位檔,需要網路連線;支援 macOS、Linux 與 Windows x64。
安裝前請注意
伺服器會下載並執行第三方掃描器二進位檔(gitleaks、trivy、opengrep)到本機快取,使用前應了解此行為。掃描會讀取專案目錄,雲端方案會將掃描資料傳送至託管服務。選用的 Claude Code skill 會在 git 提交、推送或建立 PR 前自動掃描,並可能因重大或高風險問題阻擋推送。付費方案為每月 29 或 59 美元。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 SafeWeave,將其新增到工作區。
  2. 連接 所需的 憑證。它們會被私密儲存,絕不會在公開頁面上展示。
  3. 為需要使用其工具的對話啟用該服務。

Web executable,透過 Streamable HTTP。 遠端服務在工作區中設定後即可從網頁執行環境執行。

交給代理程式安裝

把這段提示詞貼上到 Claude Code、Codex、Cursor 等代理程式,或 SourceWeft 對話中。代理程式會讀取該伺服器的安裝指南,先向你展示發布者、端點和登入方式,經你同意後再把它新增到你的客戶端。金鑰不會寫進任何命令。

閱讀 https://sourceweft.com/mcp/dev.safeweave%2Fsafeweave/install.md,並按其中說明把這個 MCP 伺服器接入我的客戶端。修改任何設定之前,先告訴我它的發布者、端點和登入方式,等我確認。不要把 API 金鑰寫進命令或我會提交的檔案;問我金鑰應從哪裡取得。

檢視代理程式所依據的安裝指南

其他 MCP 客戶端

把它新增到你客戶端的 mcpServers 設定中。 客戶端會在首次連接時完成 OAuth 登入。

{
  "mcpServers": {
    "safeweave": {
      "type": "http",
      "url": "https://mcp.safeweave.dev/mcp"
    }
  }
}

README

SafeWeave

Security scanner for AI-written code. SafeWeave runs inside your AI editor over MCP (Claude Code, Cursor, VS Code, Windsurf) and checks your code for vulnerabilities, leaked secrets, risky dependencies, IaC and container issues, so your assistant can fix findings in the same turn.

This repository is the open-core part of SafeWeave: the scanner engines (packages/scanners), the scan gateway (packages/gateway), shared types (packages/common), Docker files and the Claude Code skill. The MCP server itself ships on npm.

Quick Start

Run one command. It downloads the scanners and configures every editor it finds:

bash
npx -y safeweave-mcp

Or add it to your editor's MCP config yourself:

json
{  "mcpServers": {    "safeweave": {      "command": "npx",      "args": ["-y", "safeweave-mcp"],      "env": {        "SAFEWEAVE_LICENSE_KEY": "your-license-key-here"      }    }  }}

The key is optional. Without one you get a 10-scan trial (SAST, secrets and dependencies). A free account at safeweave.dev/signup unlocks unlimited local scans with 7 scanners.

Plans

PlanPriceWhere scans runScanners
No keyFreeLocal, 10-scan trial3 (SAST, secrets, dependencies)
Free accountFreeLocal7 (everything except DAST)
Cloud$29/moLocal + hostedAll 8, plus PR checks, website scans and AI-builder rules
Cloud Plus$59/moLocal + hostedAll of Cloud, plus teammates

See safeweave.dev/pricing for details.

Alternative: Docker

If you prefer running via Docker:

bash
git clone https://github.com/nickfluxk/safeweave.gitcd safeweavecp .env.example .env   # Edit with your license key and SCAN_DIRdocker compose up

How Scanner Binaries Work

SafeWeave automatically downloads and manages the scanner binaries it needs on first use.

ToolVersionPurpose
gitleaks8.21.2Secret and credential detection
trivy0.58.0Container vulnerability and IaC misconfiguration scanning
opengrep1.16.3SAST analysis (Semgrep-compatible, standalone binary)
  • Binaries are resolved in order: system PATH → ~/.safeweave/bin/ cache → auto-download
  • If you already have gitleaks or trivy installed via Homebrew/apt, those are used (never shadowed)
  • For SAST, system semgrep is preferred; if not found, opengrep (a standalone Semgrep-compatible fork) is downloaded — no Python required
  • Downloads happen in the background at startup — the server is ready immediately
  • Versions are pinned and updated with each SafeWeave release
  • If a download fails (no internet), that scanner is skipped gracefully

Supported platforms: macOS (arm64, x64), Linux (arm64, x64), Windows (x64)

Cache location:

~/.safeweave/  bin/       # Downloaded binaries  meta/      # Version metadata (JSON)

To force a re-download: rm -rf ~/.safeweave/bin ~/.safeweave/meta

What's Included

ScannerWhat it detectsPlan
SASTSQL injection, XSS, SSRF, path traversal, insecure cryptoFree
SecretsAPI keys, tokens, passwords and private keys in sourceFree
DependenciesKnown CVEs in npm, pip, Go and Cargo packagesFree
IaCTerraform, Dockerfile and Kubernetes misconfigurationsFree account
ContainerVulnerabilities in container imagesFree account
LicenseGPL, AGPL and other risky dependency licensesFree account
PostureMissing auth, rate limiting, CORS and security headersFree account
DASTRuntime API security issues in a running appCloud

MCP Integration

Works with any MCP-compatible editor — Cursor, Claude Code, VS Code, Windsurf, and more.

Once configured (see Quick Start above), ask your AI:

  • "Scan this project for security vulnerabilities"
  • "Check my dependencies for CVEs"
  • "Scan for hardcoded secrets"
  • "Run an IaC misconfiguration scan"

If running via Docker, use the SSE transport instead:

json
{  "mcpServers": {    "safeweave": {      "url": "http://localhost:9000/sse"    }  }}

HTTP API

Health Check

bash
curl http://localhost:9000/api/health

Run a Scan

bash
curl -X POST http://localhost:9000/api/scan \  -H 'Content-Type: application/json' \  -d '{"directory": "/path/to/project"}'

Scan Specific Scanners

bash
curl -X POST http://localhost:9000/api/scan \  -H 'Content-Type: application/json' \  -d '{"directory": "/path/to/project", "scanners": ["sast", "secrets"]}'

Compliance Profiles

Built-in profiles: standard, hardened, owasp, soc2, pci-dss, hipaa

Set via MCP set_profile tool or create a custom .safeweave/profile.yaml in your project.

Configuration

Environment Variables

VariableRequiredDescription
SAFEWEAVE_LICENSE_KEYNoYour license key from safeweave.dev. Without it: a 10-scan trial
SCAN_DIRDocker onlyHost directory to mount for scanning
SAFEWEAVE_LICENSE_URLNoLicense server URL (defaults to https://license.safeweave.dev)

Claude Code Skill: Auto-Scan Before Push

SafeWeave includes a Claude Code skill that automatically scans your code before every git commit, git push, or PR creation.

Install the skill

Copy the skill to your Claude Code skills directory:

bash
mkdir -p ~/.claude/skills/secure-before-pushcurl -sL https://raw.githubusercontent.com/nickfluxk/safeweave/main/skills/secure-before-push/SKILL.md \  -o ~/.claude/skills/secure-before-push/SKILL.md

Or clone and copy:

bash
git clone https://github.com/nickfluxk/safeweave.git /tmp/safeweavecp -r /tmp/safeweave/skills/secure-before-push ~/.claude/skills/

What happens after install

Once installed, Claude Code automatically runs a SafeWeave scan whenever you say "commit", "push", "ship it", or "create a PR":

SeverityActionBlocks push?
Critical / HighFix immediately, re-scanYes
MediumWarns, asks confirmationUser decides
Low / InfoNo actionNo

Prerequisites

SafeWeave MCP server must be configured. Run npx safeweave-mcp to set it up automatically.

Verify

Start a new Claude Code session and ask it to commit code. You should see a SafeWeave scan run before the git operation.

License

MIT. See LICENSE.

來源:README.md,提交 8cb96a9

工具

0
該伺服器需要登入,因此 SourceWeft 無法在沒有帳號的情況下讀取其工具,也未收錄。已連接帳號所能看到的內容可能因帳號及其權限而異。

版本歷史

2
  1. v0.7.5最新Oct 20, 2026
  2. v0.7.4Oct 19, 2026

評分

已滿足適用檢查項的 85%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通必需25 分
  • 已宣告認證方式必需10 分
  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分