hunt-dependency-confusion

Validates whether build configurations expose internal package names to unauthorized registry resolution.

10|3|Updated Aug 10, 2026
One-click install
npx skills add https://github.com/baiqigo/baiqi-redteam-lab --skill hunt-dependency-confusion-baiqigo
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: hunt-dependency-confusion
Source: https://github.com/baiqigo/baiqi-redteam-lab/tree/main/.agents/skills/hunt-dependency-confusion
Command: npx skills add https://github.com/baiqigo/baiqi-redteam-lab --skill hunt-dependency-confusion-baiqigo

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Organizations risk dependency confusion attacks when internal package names, registry priorities, or lockfile settings allow external registries to resolve private dependencies. This Skill plans an evidence-gated, authorized validation of those supply-chain boundaries without publishing packages or triggering builds. ## Core Features & Use Cases - Static Configuration Audit: Reviews package manifests, lockfiles, registry mappings, and CI dependency install configs in read-only mode. - Local Resolution Simulation: Uses a local resolver model to test whether internal dependencies would incorrectly resolve to unauthorized registries. - Strict Evidence Gating: Treats WAF blocks, timeouts, and scanner hits as inconclusive, and stops immediately on third-party data or irreversible side effects. - Use Case: A security team suspects their npm scope is misconfigured. The Skill audits the registry config and lockfile, simulates resolution priority locally, and produces owner-confirmed evidence without registering or publishing any package name. ## Quick Start Use hunt-dependency-confusion to plan an authorized, read-only validation of whether our internal package names could be resolved from public registries.

Frequently Asked Questions about hunt-dependency-confusion

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I test for dependency confusion vulnerabilities safely?

Audit package manifests, lockfiles, and registry configurations in read-only mode, then simulate resolution priority with a local resolver model. Never publish, register, or squat package names on public registries during validation.

What is a dependency confusion attack in package management?

Dependency confusion occurs when a package manager resolves an internal package name from a public registry instead of the private one, due to registry priority misconfiguration. Attackers exploit this by publishing malicious packages under the same name.

Does this validation publish packages or trigger CI builds?

No. The Skill explicitly prohibits publishing, registering, or reserving package names, modifying CI, triggering production builds, or reading registry tokens. All validation is static, read-only, and locally simulated.

What evidence confirms a dependency confusion finding?

A valid finding requires consistent evidence from a controlled local resolution model and build configuration showing internal dependencies resolve to an unauthorized registry, plus owner confirmation that the namespace belongs to the organization.

When should dependency confusion testing stop immediately?

Stop when encountering third-party data, shared infrastructure, or irreversible side effects. WAF blocks, timeouts, single anomalies, and scanner hits are treated as inconclusive rather than confirmed findings.