GitHub - NVIDIA/SkillSpector: Security scanner for AI agent skills. Detect vulnerabilities, malicious patterns, and security risks.

Open original

SkillSpector scans AI agent skills for vulnerabilities, malicious patterns, and CVEs before installation. It combines fast static checks with optional LLM analysis, covers 64 patterns across 16 categories, and outputs risk scores and detailed reports.

  • SkillSpector scans AI agent skills before installation, checking 64 vulnerability patterns across 16 categories (prompt injection, data exfiltration, privilege escalation, etc.) plus real-time CVE lookups via OSV.dev.
  • It runs a fast static scan by default, with an optional deeper LLM-based semantic check using providers like OpenAI, Anthropic, or NVIDIA's build.nvidia.com.
  • Scans output a 0-100 risk score with severity labels and suggested fixes, in formats including JSON, Markdown, or SARIF for CI/CD pipelines.
  • Even without LLM analysis (--no-llm flag), it still catches known code patterns and CVEs.

SkillSpector is a CLI tool from NVIDIA that scans AI agent skills—those plug-in modules used by systems like Claude Code, Codex CLI or Gemini CLI—for security flaws before you install them. It flags 64 vulnerability patterns in 16 categories, including prompt injection, data exfiltration, privilege escalation, supply-chain risks, dangerous code, taint tracking and YARA signature matches. A two-stage pipeline runs a fast static scan and, if you allow it, a deeper LLM-based semantic check. It also queries OSV.dev in real time for CVEs, with an offline fallback when you’re not connected. Installation works via a Python virtual environment or Docker. Clone the repo, activate your venv (or build the Docker image from the included Dockerfile), then run “skillspector scan” against a directory, single file, zip or Git URL. Output formats include terminal-friendly text, JSON, Markdown or SARIF for CI/CD integration. Each scan assigns a 0–100 risk score, labels severity and suggests fixes. For semantic analysis you point SkillSpector at an OpenAI-compatible LLM: providers include OpenAI (gpt-5.4), Anthropic (claude-opus-4-6) or NVIDIA’s build.nvidia.com service (deepseek-v4-flash). You set SKILLSPECTOR_PROVIDER and the relevant API key in your environment or a .env file. If you skip LLM checks with --no-llm, the tool still catches code patterns and known CVEs. The README lists every pattern by ID (P1 through R beyond), severity level and a one-line description. Patterns cover things like P2 Hidden Instructions, E2 Env Variable Harvesting, SC2 External Script Fetching, EA1 Unrestricted Tool Access and MP1 Persistent Context Injection. With those definitions on hand, you can tailor your skill vetting process, automate scans in CI or build custom extensions via the provided analyzer pipeline documentation.

Ask about this article