Skip to main content
Glama
agent-guard-mcp
by liminalpepe

agent-guard-mcp

npm License: MIT

One line: Verify-before-act safety for AI agents — check packages, lockfiles, skill manifests, and CI workflows before install or merge. Zero API keys. Zero config.

Scores Cursor/Claude skill manifests + GitHub Actions workflows — not just npm dependencies.

When you…

Call

npm install foo / agent suggests a new dep

check_package

Review an LLM-generated lockfile

verify_lockfile

Install a Cursor skill or MCP plugin

score_manifest

Merge a PR touching .github/workflows/*

check_workflow

Call these before installing a dependency, merging a CI change, or installing a third-party skill/plugin — so an agent refuses hallucinated packages, typosquats, poisoned manifests, and compromised CI actions.

Exposes four MCP tools (also available as a plain HTTP service):

Tool

Use before…

Returns

check_package

adding a single npm/PyPI dependency

OK / SUSPICIOUS / DANGER + typosquat/slop flags

verify_lockfile

running npm/pip/yarn install

scans every direct + transitive dep in a lockfile

score_manifest

installing a Cursor/Claude skill or MCP/Smithery plugin

poison-signature + scope-overreach + drift score 0–100

check_workflow

merging a PR that touches CI

flags mutable action pins, compromised actions, curl|bash, pwn-requests, secret exposure

Why

AI agents routinely hallucinate package names (slopsquatting), trust LLM-generated lockfiles, install unvetted skill packs, and pin CI actions to mutable tags. Each is a live supply-chain vector. This server gives an agent a cheap "is this safe?" call before it acts.

Related MCP server: repo-seatbelt

Install (MCP client)

{
  "mcpServers": {
    "agent-guard": { "command": "npx", "args": ["-y", "@liminallablibs/agent-guard-mcp@0.2.1"] }
  }
}

Agent rule (paste into Cursor Rules / CLAUDE.md)

Before installing any npm/PyPI package, running install from a lockfile, installing a third-party skill/MCP plugin, or merging CI workflow changes, call the agent-guard MCP tools (check_package, verify_lockfile, score_manifest, check_workflow). If verdict is SUSPICIOUS, REVIEW, or BLOCK/DANGER, stop and show findings to the user — do not proceed.

Quick demo

npx -y @liminallablibs/agent-guard-mcp@0.2.1   # MCP clients spawn this via npx
# HTTP mirror:
npm run http && curl "http://localhost:8402/check?name=reactt&ecosystem=npm"
# → DANGER — typosquat of "react"

Or run directly:

npm install
node src/mcp-server.mjs        # stdio MCP server
npm run http                   # optional HTTP mirror on :8402

HTTP endpoints (mirror of the MCP tools)

  • GET /check?name=<pkg>&ecosystem=<npm|pypi>

  • POST /check-lockfile {lockfile_content, format} — format ∈ package-lock.json | yarn.lock | pnpm-lock.yaml | poetry.lock | requirements.txt

  • POST /score-manifest {manifest_type, manifest_content}

  • POST /check-workflow {workflow_content}

License

MIT.

Available Tools

4 tools
check_packageA

Check whether a single package exists and assess slopsquat/typosquat risk BEFORE installing it. Returns OK/SUSPICIOUS/DANGER + risk + flags. Nonexistent names are likely hallucinated; names 1-2 chars from a popular package are likely typosquats.

Inputs: name (required), ecosystem.

check_workflowA

Validate a CI workflow (GitHub Actions / GitLab CI YAML) BEFORE merging a PR that touches it. Flags mutable action pins, known-compromised actions, untrusted owners, curl|bash fetch-exec, pull_request_target pwn-requests, and secret exposure. Returns risk 0-100 + merge recommendation (PROCEED/REVIEW/BLOCK).

Inputs: workflow_content (required), platform.

score_manifestA

Score a Cursor/Claude skill or MCP/Smithery plugin manifest for poison/backdoor signatures, credential scope over-reach, and drift BEFORE installing a third-party agent extension. Returns risk 0-100 + install recommendation (PROCEED/REVIEW/BLOCK).

Inputs: manifest_type (required), manifest_content (required), declared_purpose, baseline_manifest.

verify_lockfileB

Scan an entire lockfile (direct + transitive deps) for hallucinated / typosquatted / suspicious packages BEFORE running install. Call this instead of trusting an LLM-generated lockfile.

Inputs: format (required), lockfile_content (required), ecosystem.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4/5.0

    Scored across 4 tools

    Disambiguation5/5

    Each tool targets a distinct security artifact (package, workflow, manifest, lockfile) with no overlap in purpose. An agent can clearly distinguish which tool to call for each verification task.

    Naming Consistency4/5

    Tool names follow a verb_noun pattern: 'check_package', 'check_workflow', 'score_manifest', 'verify_lockfile'. While 'check' is used twice, 'score' and 'verify' are different but still descriptive, maintaining a clear and predictable structure.

    Tool Count5/5

    With 4 tools, the set is concise and focused on common pre-installation and pre-merge security checks. Each tool addresses a specific need without unnecessary bloat, making the surface easy to navigate.

    Completeness4/5

    The tool set covers major security vetting areas: package typosquatting, CI workflow integrity, manifest backdoor analysis, and lockfile scanning. Minor gaps like environment or dependency drift checks exist, but the core use cases are well-addressed.

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      B
      maintenance
      MCP security server for AI coding agents. 12 tools: pre-install guardian, vulnerability audit, supply-chain attack detection via static code analysis, and CycloneDX 1.6 SBOM generation. Zero runtime dependencies.
      15
      109 npm
      15
      Apache 2.0
    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables AI coding agents to scan projects or changed files for risky leftovers like hallucinated packages, exposed secrets, truncated code, and unfinished stubs, and to verify that packages exist before installing them.
      17 npm
      MIT