hunt-shadow-api
하는 일
이 스킬은 숨겨졌거나 오래된 API 버전을 찾고, 그 보안 규칙을 현재 버전과 비교합니다. 버전이 많거나 남은 엔드포인트가 있는 API를 허가받아 테스트할 때 사용합니다.
사용하는 경우
- ✓앱이 v1, v2처럼 버전이 있는 API 경로를 사용하고 둘 다 살아 있을 수 있을 때.
- ✓API 문서나 앱 패키지에 오래된 엔드포인트가 언급될 때.
- ✓여러 API 명세가 있고 버전이 서로 맞지 않는 경우.
스킬 링크
https://github.com/elementalsouls/Claude-BugHunter/blob/main/skills/hunt-shadow-api/SKILL.md복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.
사용 방법
가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.
바로 붙여넣을 수 있는 메시지
Claude Code, Codex, Cursor용입니다. 프로젝트 폴더에서 실행하면 스킬이 설치됩니다.
SKILL.md를 다운로드해 에이전트의 스킬 폴더에 넣으세요.
AI에게 요청하는 예시
“저희 API에는 v1과 v2 경로가 있습니다. 허가된 테스트에서 이전 v1이 여전히 같은 로그인 규칙을 적용하는지 확인해 주실 수 있나요?”
매주 새 스킬 5개. 읽는 데 1분.
작동 방식
에이전트는 흔한 버전 경로와 헤더를 테스트하고, 가능한 명세를 모은 뒤, 같은 작업을 오래된 버전과 최신 버전이 어떻게 처리하는지 비교합니다. 실제 보안 차이를 보고합니다.
기술 내용 (원본 SKILL.md)
작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.
OWASP API9 — Improper Inventory Management (Shadow / Zombie APIs)
As an API evolves, old versions and internal/staging routes routinely stay reachable without receiving the same security fixes as the current version — because nobody tracks that they still exist. The bug is rarely in one endpoint; it's in the delta between what an old version enforces and what the current version enforces on the same operation.
When to use
Trigger when:
- Versioned paths are visible (
/v1/,/v2/,/api/2023-01-01/) orAccept/X-API-Versionheaders are in play. - A changelog, release notes, or deprecation notice references removed/old API behavior.
- A mobile APK/IPA (via
apk-redteam-pipeline/ios-redteam-pipeline) hardcodes endpoints that look like an older backend version than the current web app calls. - Multiple OpenAPI/Swagger specs are discoverable, or
info.versionin one spec implies others exist.
DO NOT use for single-version APIs with no version history — there's nothing to diff; go
straight to hunt-api-misconfig for direct exploitation of the one surface that exists.
Stage 1 — Enumerate the Full Version Surface
# Path-based versioning
for v in v1 v2 v3 v4 beta alpha internal legacy old 2022-01-01 2023-01-01 2024-01-01; do
curl -s -o /dev/null -w "%{http_code} /api/$v/\n" "https://$TARGET/api/$v/"
done
# Header-based versioning
curl -s -H "X-API-Version: 1" https://$TARGET/api/users
curl -s -H "Accept: application/vnd.company.v1+json" https://$TARGET/api/users
# Subdomain-based versioning
for sub in api api-v1 api-v2 apiv1 apiv2 legacy-api old-api internal-api staging-api; do
curl -s -o /dev/null -w "%{http_code} $sub\n" "https://$sub.$TARGET/"
done
A 200/401/403 on an old version path (anything but 404/connection-refused) means the
version is still live and worth carrying into Stage 3, even if it demands auth.
Stage 2 — Pull Every Reachable Spec, Not Just the Linked One
for path in openapi.json swagger.json v1/swagger.json v2/swagger.json v3/api-docs \
api-docs.json swagger/v1/swagger.json .well-known/openapi.json; do
curl -s -o /dev/null -w "%{http_code} /$path\n" "https://$TARGET/$path"
done
# Wayback Machine — a DEPRECATED version's spec often stays indexed after the live link is removed
curl -s "http://web.archive.org/cdx/search/cdx?url=$TARGET/*swagger*&output=json&collapse=urlkey"
curl -s "http://web.archive.org/cdx/search/cdx?url=$TARGET/*openapi*&output=json&collapse=urlkey"
When more than one spec resolves (a current one and an archived/old one), diff the endpoint inventories directly:
jq -r '.paths | keys[]' v1-swagger.json | sort > /tmp/v1_paths.txt
jq -r '.paths | keys[]' v2-swagger.json | sort > /tmp/v2_paths.txt
comm -23 /tmp/v1_paths.txt /tmp/v2_paths.txt # in v1 only — candidates for "still live but forgotten"
For every path in that diff, confirm it's still reachable against the v1 base URL. A route
documented only in the old spec that still returns something other than 404 is a zombie-
endpoint candidate — carry it into Stage 3.
Stage 3 — Behavioral Diff Between Old and Current Version
For each operation that exists in both versions, compare security-relevant behavior, not response shape. Response shape differences are Informational; behavioral security regressions are the finding.
- Auth strength. Does the old version accept no token, an expired token, or a lower-
privilege token that the current version rejects?
curl -s -H "Authorization: Bearer $EXPIRED_TOKEN" https://$TARGET/api/v1/users/me -w '\n%{http_code}\n' curl -s -H "Authorization: Bearer $EXPIRED_TOKEN" https://$TARGET/api/v2/users/me -w '\n%{http_code}\n' - Rate limiting. Burst the same number of requests against both versions' equivalent
endpoint; a missing
429on the old version means rate-limiting was added later and never backported. - Input validation. Send the identical injection/oversized/malformed payload to both; the
old version accepting what the new one rejects means hardening happened forward-only —
chain into whichever injection class the payload targets (
hunt-sqli,hunt-idor, etc.). - Field exposure. Does the old version's response body include fields — internal IDs, other users' data, internal notes, PII — that the current version has since redacted?
Stage 4 — Deprecated / Internal Routes Never Referenced by the Current UI
- Gre
자주 묻는 질문
좀비 API란 무엇인가요?
더 이상 관리되지 않지만 여전히 접근 가능한 오래되었거나 내부용인 API 버전입니다.
여러 버전이 꼭 있어야 하나요?
네. 이 스킬은 버전 이력이 있는 API를 위한 것이며, 단일 버전 API는 일반 API 스킬로 테스트하는 것이 좋습니다.
보관된 명세도 사용할 수 있나요?
네. 일부 명세는 웹 아카이브에서 찾을 수 있다고 스킬은 설명합니다.
상세 정보
작성자의 원본 설명
Hunt shadow / zombie / undocumented API surface (OWASP API9 Improper Inventory Management) — enumerate the full API version history (v1/v2/beta/legacy paths, header- and subdomain-based versioning), pull and diff every reachable OpenAPI/Swagger spec (including ones only findable via the Wayback Machine), and behaviorally diff old vs. current versions for auth/rate-limit/validation regressions rather than just response-shape differences. Distinct from hunt-api-misconfig, which owns exploitation once you have a spec or endpoint (mass assignment, JWT, OData, Swagger-chain attacks); distinct from
인기도
- GitHub 스타
- 5.4k
- 순위
- #14931
- 라이선스
- MIT
- 업데이트
- 2026. 11. 2.
댓글
- …
이 저장소의 다른 스킬
apk-redteam-pipeline
5.4k에이전트가 APK 파일을 찾고 디컴파일하는 것부터 노출된 비밀 값을 확인하는 것까지, Android 앱의 보안 약점을 테스트하도록 돕습니다.
bugcrowd-reporting
5.4k에이전트가 올바른 범주를 고르고 범위 밖 이의에 답하며, Bugcrowd 취약점 보고서를 더 잘 쓰도록 돕습니다.
cloud-iam-deep
5.4k에이전트가 승인된 보안 테스트 중 찾은 클라우드 자격 증명이 AWS, Azure, Google Cloud에서 무엇에 접근할 수 있는지 확인하도록 돕습니다.
enterprise-vpn-attack
5.4k에이전트가 승인된 테스트 중 Cisco, Fortinet, Citrix 등의 VPN과 원격 접속 장비에서 알려진 약점을 확인하도록 돕습니다.