SafeDep Vet MCP

io.github.safedep由 GitHub 账号 safedep 发布v1.20.0更新于 Oct 24, 2026

Protect your AI agents and IDEs from malicious open-source packages.

概览

AI 生成的概览

SafeDep Vet MCP 让助手调用 vet 扫描器,检查依赖、CI 工作流和 AI 代理配置中的恶意包与漏洞。

可以做什么
  • 扫描目录、git 仓库、容器镜像、SBOM 或单个包,查找恶意包、已知漏洞和高风险 GitHub Actions 工作流
  • 读取 npm、PyPI、Go、Maven、Gradle、Cargo、RubyGems、NuGet、Packagist、Pub 等生态的锁文件与清单,以及 AI 代理配置,但不安装也不运行它们
  • 用 CEL 编写策略即代码规则来决定扫描何时失败,并可在已保存的扫描上测试规则
  • 生成 SARIF 报告,以及记录 AI 库和加密算法使用情况的 CycloneDX xBOM 与 CBOM 清单
  • 审计开发机上的 AI 工具、MCP 服务器、编辑器扩展和全局 npm 包
适用场景
适合在依赖、拉取请求改动或 CI 工作流进入生产前让助手做安全核查,或依据恶意软件与漏洞发现来卡住构建。也适合盘点 AI 与加密使用情况,或审计机器上安装的工具。
运行要求
以本地 stdio 进程运行,以容器镜像(ghcr.io/safedep/vet)通过 Docker 启动;README 另列 Homebrew、mise 和 Go 安装方式。未声明需要账号、API 密钥或环境变量。需要网络访问以查询 SafeDep 威胁数据。
安装前请注意
会把每个包的身份信息(生态、名称和版本)发送给 SafeDep 以获取数据,但不发送源代码和文件内容。扫描会读取项目文件,端点审计还会枚举机器上安装的工具。策略规则可使构建失败,使用前应审阅。

安装

在 SourceWeft 中

  1. 打开 控制台中的 SafeDep Vet MCP,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

[SafeDep vet]

Find malicious packages, vulnerabilities and risky CI workflows before they reach production.

[!NOTE] This branch is vet v2, in alpha. vet v1 is on main and stays the latest release. The v2.0.0 release notes map each v1 command and flag to v2.

Why vet

Your dependencies, your GitHub Actions workflows and your AI agent configs run code that you did not write. vet finds the risk in them.

  • Malicious packages. vet checks each package against SafeDep Threat Intel. Threat Intel analyzes new package versions when the registries publish them.
  • Known vulnerabilities, with the fixed version to upgrade to.
  • Risky workflows. Dangerous triggers, template injection, exposed secrets and actions with no pinned commit SHA.
  • Lockfile tampering and fresh versions. Entries from an untrusted registry, and versions inside the cooldown window.
  • Policy as code. Rules in CEL decide when a scan fails. You can test a rule on a saved scan.
  • AI and crypto inventory. vet lists the AI libraries and the crypto algorithms that your code calls, and writes a CycloneDX xBOM and CBOM.

vet needs no account and sends no source code.

Quick start

bash
brew install --cask safedep/tap/vet@edgevet scan

[vet scan finds a malicious package, vulnerabilities and workflow injection]

bash
vet scan --fail-on high                         # exit 1 on a high or critical findingvet scan --base-ref origin/main --fail-on high  # report only what a pull request changesvet report show --report sarif=vet.sarif        # write SARIF from the saved scan, with no new scan

Install

ChannelCommand
Homebrewbrew install --cask safedep/tap/vet@edge
misemise use -g 'github:safedep/vet[prerelease=true]@2'
Gogo install github.com/safedep/vet/v2/cmd/vet@latest
Containerdocker run --rm -v "$PWD:/src" -w /src ghcr.io/safedep/vet:v2-latest scan

mise installs a release one day after its publication. install.md has the command for the newest build, the release binaries and the build attestations.

What vet scans

TargetExample
A directory (the default)vet scan, vet scan ./service
A git repositoryvet scan https://github.com/safedep/vet
A container imagevet scan oci://alpine:3.20, vet scan image.tar
An SBOM (CycloneDX or SPDX)vet scan sbom.cdx.json
One packagevet scan pkg:npm/[email protected]
The tools on this machinevet endpoint audit

vet reads the lockfiles and manifests of npm, PyPI, Go, Maven, Gradle, Cargo, RubyGems, NuGet, Packagist, Pub and more. It also reads the GitHub Actions workflows and the AI agent configs of the target. It does not install or run any of them. Controls turn this data into findings. See controls.md.

Policy

A policy decides when a scan fails. Save this file as vet-policy.yml:

yaml
version: 2rules:  - id: no-malware    description: A malicious or suspicious package fails the build.    when: finding.family == "malware"    action: fail  - id: no-workflow-injection    when: finding.control_id in ["dangerous-trigger", "template-injection"]    action: fail  - id: no-critical-vulnerability    when: finding.control_id == "vulnerability" && finding.severity == "critical"    action: fail  - id: new-dependency-age    description: A pull request cannot add a version that is less than 14 days old.    when: package.change == "ADDED" && has(package.days_since_publish) && package.days_since_publish < 14    action: failsuppressions:  - purl: pkg:npm/[email protected]    reason: The upgrade to 4.18.1 is in pull request 42.    expires: 2026-12-31

Test it on the last scan, with no new scan. Then apply it to a pull request:

bash
vet report show last --policy vet-policy.ymlvet scan --base-ref origin/main --policy vet-policy.yml

After its expiry date, the suppression no longer hides the finding. Read policy.md for the rule fields, more rules and the Agent Skill that writes a policy for you.

Use cases

  • Pull request check. The vet GitHub Action comments on a pull request that adds a package, a workflow or a finding, and fails the check on an attack. vet ci init adds it to a repository.
  • CI gate. Exit codes, SARIF for GitHub code scanning, GitLab and Bitbucket reports. See ci.md.
  • Pull request review. --base-ref reports only the packages and workflows that a change adds.
  • xBOM and CBOM. A CycloneDX 1.7 inventory of the AI libraries and the crypto that your code uses. See inventory.md.
  • AI agents. vet finds Claude Code and other agents, and then writes JSON and never prompts.
  • Endpoint audit. vet endpoint audit lists the AI tools, MCP servers, editor extensions and global npm packages on a developer machine, and checks them for malware.

Documentation

PageRead it for
InstallAll channels and how to verify a release
CommandsEvery command, its flags and its exit codes
ControlsThe controls and their options
PolicyRules, suppressions and the gate
OutputReport formats, saved scans and configuration
CI and AI agentsGitHub Actions, GitLab, Bitbucket and agent mode
InventoryCode usage, AI and crypto, xBOM and CBOM

Privacy

vet sends the identity of each package (its ecosystem, name and version) to SafeDep to get the data about it. vet sends no source code and no file content.

Community

vet also runs in the cloud. SafeDep Cloud runs vet on your repositories, with no infrastructure to manage.

[Contributors to vet]

来源:README.md,提交 b62453f

工具

0
SourceWeft 尚未在沙箱中启动过该软件包,因此其工具未知。

版本历史

3
  1. v1.20.0最新Oct 7, 2026
  2. v1.19.1Sep 16, 2026
  3. v1.19.0Sep 16, 2026

评分

已满足适用检查项的 50%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分

    请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。

  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具15 分

    请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。

  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分