Skip to content
Back to skills

License Audit

ASecurity

Use to audit the open-source licenses of every direct dependency in this project before shipping. Flags GPL/AGPL as BLOCKED, unknown as WARN. Triggers on /license-audit.

  • 206 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added May 26, 2026
developmentgobash

Works with

  • claude code

Security analysis

A92/100
  • mediumInstalls packages at runtime which could introduce malicious dependencies

Pro scans all 4 files and shows the line behind each finding

Scanned May 27, 2026

npx -y skills add garagon/nanostack --skill license-audit --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of License Audit?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for License Audit
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/garagon-license-audit/badge)](https://www.skillsdirectory.com/skills/garagon-license-audit)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: license-audit
description: Use to audit the open-source licenses of every direct dependency in this project before shipping. Flags GPL/AGPL as BLOCKED, unknown as WARN. Triggers on /license-audit.
concurrency: read
depends_on: [build]
summary: "License compliance check across npm/pip/go dependencies, part of the compliance-release stack."
estimated_tokens: 200
---

# /license-audit — Dependency License Audit

You audit the open-source licenses of this project's dependencies. The point is compliance: some licenses (GPL, AGPL) force the project that uses them to be open-source under the same terms. This skill runs before `/release-readiness` so the gate has license evidence to compose.

This is the `license-audit` skill from the compliance-release stack. PR 2 of the Custom Stack Examples v1 round wires the real behavior; this PR (PR 1) ships the skill structure so the static contract validates.

## Process

### 0. Resolve paths (host-agnostic)

```bash
NANOSTACK_ROOT="${NANOSTACK_ROOT:-$HOME/.claude/skills/nanostack}"
SKILL_DIR="${SKILL_DIR:-$HOME/.claude/skills/license-audit}"
```

Some agents (including Claude Code) execute each tool call in a fresh bash process, so each snippet redefines the env vars it uses.

### 1. Run the audit

```bash
SKILL_DIR="${SKILL_DIR:-$HOME/.claude/skills/license-audit}"
"$SKILL_DIR/bin/audit.sh"
```

The helper detects the project stack (npm, pip, go) from manifest files, classifies each direct dependency's license into a family (permissive, weak copyleft, strong copyleft, unknown), and prints a JSON object with counts and a `flagged` list.

### 2. Save the artifact

```bash
NANOSTACK_ROOT="${NANOSTACK_ROOT:-$HOME/.claude/skills/nanostack}"
"$NANOSTACK_ROOT/bin/save-artifact.sh" license-audit \
  '{"phase":"license-audit","summary":{"status":"OK","headline":"...","counts":{...},"flagged":[]},"context_checkpoint":{"summary":"License audit completed.","key_files":["package.json"]}}'
```

Status rules:
- `OK` — every direct dependency has a known permissive or weak-copyleft license.
- `WARN` — at least one license is `unknown`. The composer in `/release-readiness` rolls this up.
- `BLOCKED` — at least one direct dependency is GPL or AGPL.

### 3. Headline

```
[license-audit] OK: 12 deps scanned, 0 GPL/AGPL flagged.
```

Use `WARN` or `BLOCKED` instead of `OK` when the status field above is not OK.

## Gotchas

- This skill walks **direct dependencies only**. Transitive dependencies are out of scope; pair with a deep auditor if your compliance bar requires that.
- "Unknown license" means the manifest declares the package but no license metadata is parseable from the manifest itself. Unknown is treated as `WARN`, not `OK`. The user decides whether to upgrade or replace.
- This skill never rewrites your code, edits package.json, or runs `npm install`. It is read-only.

Files in this skill

  • SKILL.md2.8 KB
  • agents/openai.yaml323 B
  • bin/audit.sh5.9 KB
  • bin/smoke.sh4.8 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in development →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.