HawkScan Skill
This skill enables Claude to act as the security testing orchestrator in an agentic
coding loop. The core workflow is:
Code changes → Start Application/API → Configure HawkScan → Run scan → Parse findings → Generate fix tasks → Repeat
Prerequisites (preflight — run before anything else)
This skill requires hawk v6.0.0 or newer. Verify:
hawk version
hawk config --help >/dev/null 2>&1 || echo "MISSING: hawk config — upgrade hawk to v6.0.0+"
[ -n "${HAWK_API_KEY:-}" ] || [ -f ~/.hawk/hawk.properties ] || echo "MISSING: credentials — set HAWK_API_KEY (headless) or run hawk init --browser (interactive)"
hawk skills status
If hawk is older than 6.0.0 or hawk config --help fails, stop and tell the user to upgrade first.
Do not inline auth recipes from memory — they live in hawk config show and are stale by design when hardcoded.
hawk skills status reports whether the installed StackHawk agent skills are current.
If it lists anything out of date, surface the exact upgrade command it prints (e.g.
/plugin marketplace update stackhawk && /plugin update hawkscan) and recommend the user
update before continuing — a stale skill may be missing fixes for the very issues you'll hit.
It's a recommendation, not a hard stop: proceed if the user prefers. (If the subcommand isn't
recognized, the installed hawk predates it — skip this check.)
See references/installation.md for upgrade and install instructions.
Companion Skills
The api skill wraps read-only StackHawk platform lookups via the hawk CLI (hawk op …):
| Purpose | Command |
|-------------------------------|----------------------------------------------------------------------------------|
| Check if App exists | hawk op app list --format json |
| Check if Env exists | hawk op env list --app <NAME\|UUID> --format json |
| Get findings with triage | hawk op scan get --app <NAME\|UUID> --detail full --format json |
| List ASM repos | hawk op repo list --format json |
| Link app to ASM repo | hawk op repo link --repo-id <ID> --app-id <ID> |
| Get tech flags | hawk op app tech-flags get --app <NAME\|UUID> --format json |
| Disable all tech flags | hawk op app tech-flags disable-all --app <NAME\|UUID> --yes |
| Set specific tech flags | hawk op app tech-flags set --app <NAME\|UUID> Key=true |
| Triage a finding | hawk op scan triage --scan <ID> --hash <HASH> --status false-positive --note "" |
| Bulk triage from file | hawk op scan triage --scan <ID> --from-file triage.yaml |
| Annotate w/o triage perm | hawk op finding note --scan <ID> --hash <HASH> --note "..." |
| Get scanned URIs | hawk op scan uris <scanId> --format json (skip if the subcommand errors) |
| Get effective scan config | hawk op scan config <scanId> (skip if the subcommand errors) |
These reads require the combined hawk CLI; the api skill covers setup (hawk init --browser or the HAWK_API_KEY env var).
Selecting an app: --app takes an application name or UUID — pass whichever you have (e.g. the applicationId from stackhawk.yml, or the app's name). No separate flag is needed. Also parse --format json output defensively — a "skills out of date" banner may precede the JSON.
The stackhawk-data-seed skill sets up checked-in backend seed data via hawk perch seed.
Hand off to it when authentication fails because the backend has no valid credential
(Phase 1c.6), or after a scan when auth succeeded but endpoints returned empty data
(Step 6). This skill then consumes its .data-seed-credentials.env handoff.
StackHawk Platform Model (read this first)
Before running a scan, understand these four layered objects:
- Organization (
orgId): the tenant. Implicit viaHAWK_API_KEY. - Application (
applicationId, UUID): long-lived; holds tech flags and metadata. One App spans many Environments. - Environment (
env, string name): scan context under an App. Findings compare scan-to-scan within the same env. - Scan: a single run. Tagged with commit SHA and branch for traceability.
Non-negotiable rules: Apps are reused, not created per scan. Envs group history — pick
names deliberately. Findings have a lifecycle (NEW, FALSE_POSITIVE, RISK_ACCEPTED, ASSIGNED) — respect it.