Skip to main content
Glama

depguard_exposure

Check if a machine was hit by an npm supply-chain attack. Scans lock files, global packages, and cache for known malicious versions and reports remediation steps.

Instructions

Answer "was this machine hit?" after an npm supply-chain incident (worm, hijacked maintainer, malicious release). Scans every lock file under the given paths (npm, pnpm, yarn classic/berry, bun; nested copies included), globally installed packages, and the npm download cache, and matches each exact installed version against ~35k known-malicious npm packages. Reports where each malicious version was found, whether it is installed on disk, whether it runs install scripts, when its tarball was downloaded, and the remediation steps (credential rotation, cleanup). Use this when the user asks whether they are affected by an attack, or as a periodic check. Only exact version matches are reported; clean versions of previously compromised packages are never flagged.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathsNoDirectories to search for lock files (absolute paths). Default: the user's home directory.
maxDepthNoDirectory depth to search below each path (default: 8)
includeCacheNoScan the npm download cache (default: true)
includeGlobalNoScan globally installed npm packages (default: true)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.15.2

TDQS

A3.9/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden and does substantial work: it discloses the exact-version matching rule, the explicit false-positive policy ('clean versions of previously compromised packages are never flagged'), and the reporting contents (on-disk presence, install scripts, tarball download time, remediation steps). It does not state whether the operation is read-only or whether it requires network access to refresh the malicious-package list, which are the remaining behavioral gaps.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the question the tool answers, then scope, then matching semantics, then usage trigger. Every sentence carries information, but the single dense paragraph packs scope, output, and guidance together without visual separation, which slightly hurts scannability.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema and no annotations, the description compensates well: it enumerates what is scanned (lock files across five package managers, nested copies, globals, cache) and what is reported (location, on-disk presence, install scripts, tarball timestamps, remediation). Only the operational profile (read-only? network required? runtime cost) is left unstated.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100% (paths, maxDepth, includeCache, includeGlobal each documented with types and defaults), so the schema already does the heavy lifting. The description only restates 'under the given paths' and the cache/global scanning scope at a high level, adding no format or semantics beyond the schema. Baseline 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a precise verb+resource: scanning every lock file, global install, and npm cache and matching exact installed versions against ~35k known-malicious npm packages, framed as answering 'was this machine hit?'. The scope is unusually specific and unambiguous. It does not name or contrast with the many similar-sounding siblings (depguard_audit, depguard_sweep, depguard_verify), so it falls short of a 5.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly states when to use it: 'when the user asks whether they are affected by an attack, or as a periodic check.' That is a clear trigger condition. It offers no exclusions or alternative tools for adjacent needs (e.g. auditing a single project vs. the whole machine), which keeps it from a 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.