ต้นแบบ · รุ่นทดลอง: มีทุก server ในทะเบียนทางการ อัปเดตทุก 30 นาที เข้าสู่ระบบด้วย Google เพื่อเขียนรีวิวได้แล้ว
PopNx MCPที่รวม MCP สำหรับคนใช้ AI · อธิบายเป็นภาษาคน

Safeinstall

โดย Mickdownunderรุ่น 0.12.0i★ 3iรันบนเครื่อง
ชื่อใน registryio.github.Mickdownunder/safeinstall

วิธีติดตั้ง

ภาพรวม

คำอธิบายจากผู้ทำ (ภาษาอังกฤษตามต้นฉบับ)

Local-first supply-chain security gate for npm/pnpm/bun: typosquat, release age, provenance checks

ใช้ทำอะไรได้

ตัวนี้ยังไม่ได้เรียบเรียงเป็นภาษาไทย ด้านล่างคือข้อเท็จจริงที่เราอ่านจาก registry

  • การเชื่อมต่อ: รันบนเครื่อง
  • ช่องทาง (transport): stdio
  • หมวด: ความปลอดภัยไซเบอร์

ติดตั้ง

เลือกโปรแกรม AI ที่คุณใช้ แล้วคัดลอกค่าตั้งไปวาง

ผลตรวจผ่าน 3/3 · ทำงานบนเครื่องคุณ

ขั้นแรก: คุณใช้ AI ตัวไหน

เลือกแอปที่คุณใช้ ขั้นตอนจะขึ้นด้านล่าง

ต่อกับ Claude ได้ แต่ต้องเตรียมก่อน

ต้องลง Node.js ในเครื่องก่อน (ทำครั้งเดียว) · ใช้ได้เฉพาะแอป Claude บนคอม (Windows หรือ Mac) ไม่ใช่บนเว็บหรือมือถือ

  1. ลง Node.js ในเครื่อง

    ทำครั้งเดียว ใช้ได้กับทุกตัวที่ต้องใช้ Node.js

    เปิดหน้าดาวน์โหลด Node.js ↗

  2. เปิดไฟล์ตั้งค่าของแอป Claude บนคอม

    SettingsDeveloperEdit Config

  3. วางค่าตั้งนี้แล้วบันทึกไฟล์

    {
      "mcpServers": {
        "safeinstall": {
          "command": "npx",
          "args": [
            "-y",
            "safeinstall-cli",
            "mcp"
          ]
        }
      }
    }
  4. ปิดแอป Claude แล้วเปิดใหม่

  5. ลองเลย

    ใช้ Safeinstall บอกหน่อยว่าทำอะไรให้ฉันได้บ้าง แล้วลองทำให้ดูหนึ่งอย่าง

    ✓ ถ้า Claude บอกว่ากำลังใช้ Safeinstall หรือมีชื่อเครื่องมือของ Safeinstall ขึ้นในคำตอบ แปลว่าต่อสำเร็จ

ชื่อเมนูตรวจกับหน้าช่วยเหลือของ Anthropic เมื่อ 11 พ.ย. 2569 · หน้าจอของคุณอาจต่างเล็กน้อยตามรุ่นของแอป

ChatGPT ยังต่อ Safeinstall ไม่ได้

Safeinstall ต้องติดตั้งในเครื่องคุณ แต่ ChatGPT ต่อได้เฉพาะตัวที่ทำงานบนเว็บ

คุณทำแบบนี้แทนได้

ก · ใช้แอปที่ต่อ Safeinstall ได้

  • ต้องลง Node.js ในเครื่องก่อน (ทำครั้งเดียว) · ใช้ได้เฉพาะแอป Claude บนคอม (Windows หรือ Mac) ไม่ใช่บนเว็บหรือมือถือ
  • ต้องลง Node.js ในเครื่องก่อน (ทำครั้งเดียว)
  • ต้องลง Node.js ในเครื่องก่อน (ทำครั้งเดียว)
  • ต้องลง Node.js ในเครื่องก่อน (ทำครั้งเดียว)

ข · ตัวอื่นในหมวด ความปลอดภัยไซเบอร์ ที่ต่อกับ ChatGPT ได้

เลือกจากตัวที่ใช้มากในหมวดเดียวกัน เฉพาะตัวที่ต่อด้วยที่อยู่ได้โดยไม่ต้องใส่คีย์

ต่อกับ Claude Code ได้ แต่ต้องเตรียมก่อน

ต้องลง Node.js ในเครื่องก่อน (ทำครั้งเดียว)

  1. ลง Node.js ในเครื่อง

    ทำครั้งเดียว ใช้ได้กับทุกตัวที่ต้องใช้ Node.js

    เปิดหน้าดาวน์โหลด Node.js ↗

  2. เปิด Terminal

    Mac: กด Command+Space พิมพ์ Terminal · Windows: เปิด PowerShell

  3. วางคำสั่งนี้แล้วกด Enter

    claude mcp add safeinstall -- npx -y safeinstall-cli mcp
  4. พิมพ์ /mcp ใน Claude Code

    ต้องเห็น Safeinstall ในรายการและขึ้นว่าเชื่อมต่อแล้ว

  5. ลองเลย

    ใช้ Safeinstall บอกหน่อยว่าทำอะไรให้ฉันได้บ้าง แล้วลองทำให้ดูหนึ่งอย่าง

    ✓ ถ้า Claude Code บอกว่ากำลังใช้ Safeinstall หรือมีชื่อเครื่องมือของ Safeinstall ขึ้นในคำตอบ แปลว่าต่อสำเร็จ

ชื่อเมนูตรวจกับหน้าช่วยเหลือของ Anthropic เมื่อ 11 พ.ย. 2569 · หน้าจอของคุณอาจต่างเล็กน้อยตามรุ่นของแอป

ต่อกับ Cursor ได้ แต่ต้องเตรียมก่อน

ต้องลง Node.js ในเครื่องก่อน (ทำครั้งเดียว)

  1. ลง Node.js ในเครื่อง

    ทำครั้งเดียว ใช้ได้กับทุกตัวที่ต้องใช้ Node.js

    เปิดหน้าดาวน์โหลด Node.js ↗

  2. กดปุ่มนี้เพื่อเปิด Cursor

    เปิดใน Cursor

    Cursor จะถามยืนยันการติดตั้ง ให้กด Install

  3. เปิดแชตของ AI ใน Cursor โหมด Agent

  4. ลองเลย

    ใช้ Safeinstall บอกหน่อยว่าทำอะไรให้ฉันได้บ้าง แล้วลองทำให้ดูหนึ่งอย่าง

    ✓ ถ้า Cursor บอกว่ากำลังใช้ Safeinstall หรือมีชื่อเครื่องมือของ Safeinstall ขึ้นในคำตอบ แปลว่าต่อสำเร็จ

ชื่อเมนูตรวจกับหน้าช่วยเหลือของ Cursor เมื่อ 11 พ.ย. 2569 · หน้าจอของคุณอาจต่างเล็กน้อยตามรุ่นของแอป

ต่อกับ VS Code ได้ แต่ต้องเตรียมก่อน

ต้องลง Node.js ในเครื่องก่อน (ทำครั้งเดียว)

  1. ลง Node.js ในเครื่อง

    ทำครั้งเดียว ใช้ได้กับทุกตัวที่ต้องใช้ Node.js

    เปิดหน้าดาวน์โหลด Node.js ↗

  2. กดปุ่มนี้เพื่อเปิด VS Code

    เปิดใน VS Code

    VS Code จะถามยืนยันการติดตั้ง ให้กด Install

  3. เปิดแชตของ AI ใน VS Code โหมด Agent

  4. ลองเลย

    ใช้ Safeinstall บอกหน่อยว่าทำอะไรให้ฉันได้บ้าง แล้วลองทำให้ดูหนึ่งอย่าง

    ✓ ถ้า VS Code บอกว่ากำลังใช้ Safeinstall หรือมีชื่อเครื่องมือของ Safeinstall ขึ้นในคำตอบ แปลว่าต่อสำเร็จ

ชื่อเมนูตรวจกับหน้าช่วยเหลือของ VS Code เมื่อ 11 พ.ย. 2569 · หน้าจอของคุณอาจต่างเล็กน้อยตามรุ่นของแอป

โปรแกรมอื่นที่ใช้ MCP ได้ เช่น Windsurf, Zed หรือ Gemini CLI มีวิธีเพิ่มต่างกัน ดูวิธีของแต่ละตัวในหน้ารวมโปรแกรม

ดูโปรแกรมที่ใช้ MCP ทั้งหมด →

ค่าตั้งแบบไฟล์ JSON อยู่ในหัวข้อ “สำหรับคนเขียนโค้ด” ด้านล่าง

ติดตรงไหน? ถามคนที่ใช้ Safeinstall อยู่💬 พูดคุย →
สำหรับคนเขียนโค้ด: คำสั่ง Terminal และค่าตั้ง JSON

ติดตั้งในเครื่อง

Claude Code

claude mcp add safeinstall -- npx -y safeinstall-cli mcp

Claude Desktop (claude_desktop_config.json)

{
  "mcpServers": {
    "safeinstall": {
      "command": "npx",
      "args": [
        "-y",
        "safeinstall-cli",
        "mcp"
      ]
    }
  }
}

Cursor (~/.cursor/mcp.json)

{
  "mcpServers": {
    "safeinstall": {
      "command": "npx",
      "args": [
        "-y",
        "safeinstall-cli",
        "mcp"
      ]
    }
  }
}

VS Code (mcp.json)

{
  "servers": {
    "safeinstall": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "safeinstall-cli",
        "mcp"
      ]
    }
  }
}

ค่าตั้งนี้สร้างจากข้อมูลใน registry ของผู้ทำ ถ้าไม่ตรงกับ README ให้เชื่อ README

สรุป

ดาวน์โหลดต่อสัปดาห์i
143/สัปดาห์
การเชื่อมต่อ
รันบนเครื่อง
รุ่นล่าสุดi
0.12.0
ส่งเข้า registryi
11 ก.ค. 2569
แก้โค้ดล่าสุดi
8 ต.ค. 2569
ผู้ทำ
Mickdownunder
แพ็กเกจ
npm: safeinstall-cli
สถานะใน registry
ใช้งานอยู่

ใช้กับโปรแกรมไหนได้

ดูจากแบบการต่อของ server ตัวนี้ และเอกสารของผู้ทำโปรแกรมแต่ละตัว ตรวจเมื่อ 10 พ.ย. 2569

ติดตั้งบนเครื่องได้ใน

ClaudeGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatRaycast

ดูโปรแกรมทั้งหมดพร้อมข้อดีข้อเสีย →

คู่มือที่เกี่ยวข้อง

ทำอะไรได้บ้าง

รันในเครื่องคุณ รายการเครื่องมือจะขึ้นในแอป AI หลังติดตั้ง

ผลตรวจเบื้องต้นi

เราตรวจจากข้อมูลที่ใครก็เปิดดูได้ ยังไม่ได้อ่านโค้ด ข้อที่ไม่เกี่ยวกับตัวนี้ไม่นับในตัวหาร · ตรวจเมื่อ 11 พ.ย. 2569

  • ✓ ผ่าน

    ตัวตนผู้ทำตรงกับ repo

    ชื่อใน registry ยืนยันด้วยบัญชี GitHub Mickdownunder ซึ่งเป็นเจ้าของ repo

  • ✓ ผ่าน

    ยังมีคนดูแล

    มีการแก้โค้ดล่าสุด 34 วันที่ผ่านมา

  • ✓ ผ่าน

    มีสัญญาอนุญาต (license)

    ใช้ MIT

  • – ไม่เกี่ยว

    endpoint ตอบ

    ตัวนี้รันบนเครื่องคุณ ไม่มี endpoint บนอินเทอร์เน็ต

  • – ไม่เกี่ยว

    ล็อกอินแบบ OAuth

    ตัวนี้รันบนเครื่อง ใช้ค่าที่ตั้งในเครื่องแทน

  • … ยังไม่ตรวจ

    คำอธิบายเครื่องมือไม่มีคำสั่งแอบแฝง

    รันในเครื่องคุณ เราอ่านรายการเครื่องมือได้เฉพาะตัวที่มี endpoint บนอินเทอร์เน็ต

พูดคุย

ถาม แชร์เคล็ดลับ หรือแจ้งว่าใช้ไม่ได้ เรียงตามที่คนกดว่ามีประโยชน์

ยังไม่มีใครโพสต์ ถามหรือแชร์เป็นคนแรกได้เลย

ข้อความในส่วนนี้เขียนโดยผู้ใช้ ไม่ใช่ทีม PopNx

เข้าสู่ระบบด้วย Google เพื่อโพสต์

รีวิวจากผู้ใช้

ยังไม่มีรีวิว

เข้าสู่ระบบด้วย Google เพื่อเขียนรีวิว

เทียบกับตัวอื่นในหมวด ความปลอดภัยไซเบอร์i

  • ดาวมากกว่า 86% ของอีก 1034 ตัวในหมวดนี้
  • ส่งรุ่นใหม่เข้า registry ล่าสุดกว่า 26% ของอีก 1034 ตัวในหมวดนี้
  • ผลตรวจเบื้องต้นดีกว่าหรือเท่ากับ 100% ของอีก 1034 ตัวในหมวดนี้

เทียบกับทุก server ที่ยังใช้งานในหมวดนี้ทั้งทะเบียน ดาวนับเฉพาะเมื่อผู้ลงทะเบียนเป็นเจ้าของ repo

คำถามที่พบบ่อย

Safeinstall ปลอดภัยไหม?

จากการตรวจเบื้องต้นของเรา ผ่าน 3 จาก 3 ข้อที่ตรวจได้ เรายังไม่ได้อ่านโค้ด ก่อนใส่กุญแจหรือ token ให้ดูว่า server ขอสิทธิ์อะไร และเลือกกุญแจที่ทำได้เท่าที่จำเป็น

ต้องใช้กุญแจหรือรหัสอะไรบ้าง?

registry ไม่ได้ระบุว่าต้องใช้กุญแจ แต่บางตัวจะขอให้ล็อกอินตอนใช้ครั้งแรก

ตัวนี้รันบนเครื่องหรือบนคลาวด์?

รันบนเครื่องของคุณ โปรแกรม AI จะเปิด server ขึ้นมาเองเมื่อใช้ ข้อมูลไม่ต้องผ่านเซิร์ฟเวอร์ของผู้ทำ (ยกเว้นตัวที่ไปเรียกบริการออนไลน์ต่อ)

ยังมีคนดูแลอยู่ไหม?

repo บน GitHub มีการแก้โค้ดล่าสุด 34 วันที่ผ่านมา และส่งรุ่นล่าสุด (0.12.0) เข้า registry 4 เดือนที่ผ่านมา

ใช้กับโปรแกรมไหนได้บ้าง?

โปรแกรมที่รองรับ MCP เช่น Claude Desktop, Claude Code, Cursor และ VS Code ตัวนี้ต้องมี Node.js ในเครื่องด้วย

มีตัวไหนใช้แทนได้บ้าง?

ในหมวดเดียวกันมี Robin: AI-Powered Dark Web OSINT, HOL Guard, UniFi Network MCP

ตัวที่ใช้แทนได้

server หมวดเดียวกันจากผู้ทำคนอื่น เรียงตามดาว

อ่านการ์ด:↓ ดาวน์โหลดต่อสัปดาห์i★ ดาว GitHubiสามเสา: รีวิว · ผลตรวจ · การใช้งานiอัปเดต = วันที่ส่งรุ่นล่าสุดเข้า registryi

Robin: AI-Powered Dark Web OSINT

Dark web OSINT over Tor: search onion engines, scrape pages, report with your own model.

โดย apurvsinghgautamกำลังโต★ 8Kอัปเดต 39 วันที่ผ่านมา

รันบนเครื่อง

HOL Guard

Local-first AI agent security evidence and approval workflows through HOL Guard's stdio MCP server.

โดย hashgraph-onlineใช้กันมาก↓ 7.1K/สัปดาห์★ 1.1Kอัปเดต 6 วันที่ผ่านมา

รันบนเครื่อง

UniFi Network MCP

Manage UniFi Network devices, clients, firewall, VLANs, VPNs, and more via MCP.

โดย sirkirbyใช้กันมาก↓ 11.3K/สัปดาห์★ 1K ดาวรวมทั้งรีโปอัปเดต 8 เดือนที่ผ่านมา

รันบนเครื่อง

README จากผู้ทำ

เปิดอ่าน README

ส่วนนี้คัดจาก repo ของผู้ทำตามต้นฉบับ PopNx MCP ไม่ได้ตรวจหรือรับรองเนื้อหา ตัด HTML รูปภาพ และสคริปต์ออกแล้ว ลิงก์จะพาออกนอกเว็บ

SafeInstall

Supply-chain security for the AI-agent era.

The artifact-bound install gate for npm and pnpm — for the humans who type install , the AI agents that run it for them, and the config that programs those agents.

Policy runs first. Then your package manager. Not the other way around.

Local-first · No cloud · No account · MIT · Free forever


What it does

SafeInstall runs your policy before your package manager — locally, blocking by default. One tool, three layers of defense:

  • 🧑💻 For the humans who install — prefix supported install commands: safeinstall pnpm add axios. Policy runs first; the resolved lockfile is then checked against the approved version and SHA-512 before the frozen install. Release age, install scripts, untrusted sources, typo-squats, and cryptographic provenance are policy checks.
  • 🤖 For the AI agents that install for you — an MCP tool agents can call, plus a shell guard that intercepts install commands in Claude Code, Codex, and Cursor *before they run*. Best-effort shell interception — one defense layer that fires even when the agent isn't cooperating, not a lossless guarantee.
  • 🔒 For the files that program the agents — the Agent Trust Surface: a committed hash baseline of your config, hooks, rules, and MCP files, reconciled locally and re-verified in CI, so tampering with the rules surfaces as drift instead of silently owning every future session — with a fully consistent rewrite caught by human review of the diff, not the automated check alone.

Why SafeInstall

AI coding tools suggest packages in seconds. They don't check publish dates. They don't read install scripts. They don't verify the source. You type "yes" and move on.

SafeInstall is the gate between suggestion and execution.

$ safeinstall pnpm add compromised-pkg@9.9.9

Install blocked.

  • compromised-pkg@9.9.9 Blocked: release too new (published 3 hours ago; minimum is 72 hours). Blocked: install script present (has postinstall).

No dashboard. No account. No cloud. One command prefix — policy runs locally, blocks by default, then invokes the real tool.


Catching a maintainer-compromise attack

A valid Sigstore signature is not enough. An attacker who compromises an npm maintainer account can publish a malicious version of a package you already trust, and the attestation on that malicious version will cryptographically verify — signed by a GitHub Actions workflow the attacker controls in a fork of the real repository.

SafeInstall catches this. Pin the expected source repository with provenance.trustedPublishers and any build that comes from anywhere else is blocked, even if the signature is valid:

$ safeinstall check

Using config: ./safeinstall.config.json Check blocked.

  • axios@1.99.0 Blocked: publisher mismatch for axios (expected axios/axios, got evil-org/axios). Suggestion: Verify the package source. Update provenance.trustedPublishers only if the change is intentional.

This is the only check of its kind in an install-time policy gate. CVE scanners look for known vulnerabilities. Content analyzers look for suspicious code. SafeInstall enforces that the cryptographic chain of trust points at the repository you agreed to trust — and refuses anything else, no matter how legitimate it looks.

SafeInstall itself is published with a Sigstore attestation. You can eat your own dog food: enable provenance verification, pin safeinstall-cli to Mickdownunder/SafeInstall, and watch SafeInstall verify its own trust chain against the public Sigstore transparency log.

$ safeinstall check

Using config: ./safeinstall.config.json Info: safeinstall-cli: provenance verified from Mickdownunder/SafeInstall via .github/workflows/release.yml. Check passed: no direct dependency policy violations found.


Install

npm install -g safeinstall-cli

Node.js >=20 · macOS, Linux, Windows · Command: safeinstall

Quickstart

safeinstall init                      # config + agent guard hooks + trust lock, in one command

safeinstall pnpm add axios # policy runs, then pnpm safeinstall npm install # lockfile-aware project install safeinstall check # audit direct deps against policy


How it works

Resolve → Policy → Lockfile-only preparation → Verify artifact binding → Frozen install

Any failed policy or binding check → Exit 2 (blocked)

  1. Resolves the requested version and captures the registry's tarball URL and SHA-512
  2. Fetches registry metadata (publish time, declared scripts)
  3. Evaluates policy rules
  4. For explicit package additions, pins the evaluated version and runs a scripts-disabled, lockfile-only preparation
  5. Checks every direct registry dependency in the affected lockfile scope against its evaluated version, SHA-512, and tarball URL where recorded; applies configured transitive checks
  6. Runs npm ci or pnpm install --frozen-lockfile with scripts disabled and the configured registry enforced; rejects manifest/lockfile changes during evaluation or installation

No registry proxy. No tarball rewriting. No cloud dependency.


Policy defaults

RuleDefaultBlock message
Release age72 hours minimumBlocked: release too new
Lifecycle scriptspreinstall, install, postinstall blockedBlocked: install script present
Source typesregistry, workspace, file, directory allowedBlocked: untrusted source
Trust downgradeDetects registry→git/url or new scripts on updateBlocked: trust level dropped
Typo-squat detectionOff by default; opt in via typoSquat.modeBlocked: suspected typo-squat
Provenance verificationOff by default; opt in via provenance.modeBlocked: attestation missing/invalid/publisher mismatch
Transitive dependenciesOff by default; opt in via transitive.modeBlocked: transitive install script / untrusted source
Provenance continuityOff by default; opt in via continuity.modeBlocked: provenance downgrade / identity discontinuity

All rules are configurable. Ambiguous or incomplete metadata blocks instead of allowing.

Provenance continuity — catching what npm defaults can't

This is SafeInstall's most distinctive check, and the one no other consumer-side tool does. npm verifies provenance at *publish* time and binds a package to a source repository — but it does not enforce continuity between versions. A compromised maintainer account can publish a new version with *no* attestation (from a stolen token), or from a *different* repository, and npm raises no alarm. This is the signature of the 2026 attack wave (Mastra, the dormant-account republishes).

Continuity learns a per-package trust baseline from the provenance identity of recent versions, then blocks deviations:

  • `provenance-downgrade` — recent versions were attested, this one isn't. The fingerprint of an account-compromise publish from a personal token. *(This is the Mastra case.)*
  • `identity-discontinuity` — this version is attested from a different source repository than the established baseline.

Because the baseline is learned per package, there are no false positives on the large majority of packages that never adopted provenance — they simply have no baseline and the check stays silent. No global "require provenance" sledgehammer.

It reads npm's published attestation metadata, so it works without the optional sigstore package. Opt in with continuity.mode set to "warn" or "block".

Honest limit: continuity does not catch an attack that comes *through* a legitimately-compromised CI workflow with valid provenance from the real repository (e.g. the Shai-Hulud worm class). There is no identity discontinuity to detect there. SafeInstall raises the bar against the dominant 2026 attack pattern; it does not close every door.

Transitive dependencies

By default SafeInstall evaluates direct dependencies. Most supply-chain attacks, though, reach you through a *transitive* dependency — a package you never chose, pulled in several levels deep. Enable transitive mode to walk the full lockfile tree.

Two checks run transitively, both read directly from the lockfile with zero extra registry calls:

  • `install-script` — flags transitive packages that declare a lifecycle script (the ua-parser-js attack class: a deeply nested dependency running code at install time). npm records this in the lockfile; pnpm lockfiles do not, so this check is npm-only for now.
  • `untrusted-source` — flags transitive packages resolving from git, url, or tarball sources instead of the registry. Works for both npm and pnpm.

Release-age, typo-squat, and provenance are deliberately not run transitively — they would either flood you with noise or require a registry round-trip per package. Transitive evaluation applies to safeinstall check, project installs, and the prepared lockfile for explicit npm/pnpm additions.

{

"transitive": { "mode": "warn", "checks": ["install-script", "untrusted-source"] } }

Typo-squat detection

Flags install requests whose package name is a close-but-not-exact match to a well-known popular package — the most common supply-chain attack pattern: lodsh for lodash, axois for axios, raect for react, and so on.

  • Algorithm: Damerau-Levenshtein distance (transpositions count as a single edit)
  • Target list: curated set of popular ecosystem packages, embedded at build time (no runtime network fetch)
  • Default mode: "off" — opt in with typoSquat: { "mode": "warn" } or "block"
  • False-positive mitigation: exact matches to the list are never flagged, short names (< 4 chars) are skipped, per-project ignore list is supported
Provenance verification

Cryptographically verifies the npm provenance attestation for registry installs and optionally pins the source repository via per-package trusted publisher patterns.

  • Fetches the attestation bundle from the npm registry's /-/npm/v1/attestations/ @ endpoint
  • Verifies the Sigstore bundle via the official sigstore package (signatures, Rekor transparency log, Sigstore public trust root)
  • Extracts source repository, commit ref, and workflow path from the SLSA v1 provenance statement
  • Matches the source repository slug against per-package trustedPublishers patterns — catching not only tampered tarballs but also **maintainer-compromis

ตัดมาแค่ช่วงต้น อ่านต่อใน repo