race-conditions
Use when testing for race conditions, single-packet attacks, TOCTOU vulnerabilities, limit-bypass via concurrent requests, coupon/voucher reuse, double-spend…
Skill by kalpmodi
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/kalpmodi-race-conditions
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: testing
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/race-conditions
What's inside
- Skill name
race-conditions- Description
- Use when testing for race conditions, single-packet attacks, TOCTOU vulnerabilities, limit-bypass via concurrent requests, coupon/voucher reuse, double-spend, rate limit bypass, or parallel request timing attacks. Also use when the user says "race condition", "single packet attack", "concurrent requests", "double spend", "limit bypass", or "TOCTOU".
- License
- MIT
- Instructions
- 434 lines in SKILL.md · view on GitHub
Before installing
- Instructions call the network
Files (1)
- SKILL.md
SKILL.md (first lines)
# Race Condition Attack Playbook
## Philosophy
Race conditions are invisible to static analysis and most scanners.
The gap between CHECK and USE is always exploitable if requests arrive simultaneously.
HTTP/2 single-packet attack sends all requests in ONE TCP frame = true simultaneity.
Never claim a race condition without repeatable proof - screenshot or log showing duplicate resource use.
## Arguments
`<target>` - domain (e.g. app.target.com)
`<focus>` - optional: COUPON / WALLET / RATE-LIMIT / TOCTOU / LIMIT-BYPASS / FULL
---
## Phase 0: Smart Intake
```bash
source ~/.claude/skills/_shared/phase0.sh
source ~/.claude/skills/_shared/signals.sh
p0_init_vars "$1"
p0_state_gate "HARVEST" || exit 0
p0_read_relay recon exploit
p0_read_memory
p0_read_hypotheses
# Narrow endpoints to race-relevant paths
RACE_TARGETS=$(echo "$INTERESTING_ENDPOINTS" | grep -iE "coupon|promo|voucher|redeem|claim|bonus|reward|withdraw|transfer|wallet|checkout|order|cart|limit|rate|reset|verify|otp" | head -20)
WAYBACK_ENDPOINTS=$(echo "$WAYBACK_ENDPOINTS" | grep -iE "coupon|redeem|transfer|withdraw|claim" | head -10)
TECH_STACK=$KNOWN_TECH
HTTP2_LIKELY=$(echo "$TECH_STACK" | grep -qi "nginx\|cloudflare\|h2\|http/2" && echo true || echo false)
echo "=== PHASE 0 RACE CONDITIONS INTAKE: $TARGET ==="
echo "State: $STATE | HTTP/2 likely: $HTTP2_LIKELY"
echo "Race-relevant endpoints found in recon: $(echo "$RACE_TARGETS" | grep -c . 2>/dev/null || echo 0)"
echo "Race targets: $RACE_TARGETS"
echo "ATW flagged (avoid): ${ATW_FLAGGED:-none}"
```
### Execution Manifest
One manifest item per endpoint type found. Do not run generic "test everything" - target specific endpoints extracted from recon.
```bash
# Build items dynamically based on RACE_TARGETS found above.
# Template - replace <endpoint> with actual URLs from RACE_TARGETS.
MANIFEST=$(cat << 'MANIFEST_EOF'
{
"phase": "race-conditions",
"generated_at": "YYYY-MM-DD HH:MM",
"items": [
{"id":"rc01","tool":"single-packet-race","target":"<coupon/redeem endpoint from recon>","reason":"coupon reuse = direct financial impact","priority":"MUST","status":"pending","skip_reason":"set to skipped if no coupon endpoint found"},
{"id":"rc02","tool":"single-packet-race","target":"<wallet/transfer endpoint from recon>","reason":"double-spend = critical financial impact","priority":"MUST","status":"pending","skip_reason":"set to skipped if no wallet endpoint found"},
{"id":"rc03","tool":"single-packet-race","target":"<otp/reset endpoint from recon>","reason":"rate limit bypass -> OTP brute force","priority":"SHOULD","status":"pending","skip_reason":"set to skipped if no OTP endpoint found"},
{"id":"rc04","tool":"endpoint-discovery","target":"<target>/api","reason":"find limit-enforcement endpoints not in recon intel","priority":"MUST","status":"pending","skip_reason":null},
{"id":"rc05","tool":"single-packet-race","target":"<checkout/order endpoint>","reason":"buy more than available qty","priority":"SHOULD","status":"pending","skip_reason":"set to skipped if no checkout endpoint found"},
{"id":"rc06","tool":"toctou-file-race","target":"<file upload endpoint>","reason":"AV scan window = malicious file delivery","priority":"IF_TIME","status":"pending","skip_reason":"skip if no file upload surface found"}
]
}
MANIFEST_EOF
)
jq --argjson m "$MANIFEST" '.scalpel.active_manifest = $m' $SESSION > /tmp/s.json && mv /tmp/s.json $SESSION
```
**Manifest adjustment rules:**
- If `RACE_TARGETS` contains coupon/redeem URLs: set rc01 target to those exact URLs
- If `RACE_TARGETS` contains wallet/transfer URLs: set rc02 target to those exact URLs
- If `RACE_TARGETS` is empty: rc01, rc02, rc05 remain pending but rc04 becomes MUST (discover endpoints first)
- If `HTTP2_LIKELY=false`: note that single-packet attack may require Burp Turbo Intruder fallback (Phase 3)
- If `STATE=DEEP` and existing confirmed vuln is financial: rc04, rc06 become IF_TIME only
---
## Phase 1 - Identify Race Condition Targets
**High-value targets - always test these first:**
```
CRITICAL TARGETS (one-time use resources):
- Coupon/promo code redemption
- Password reset token use
- Email verification token
- Referral bonus claim
- Gift card redemption
- One-time login links
HIGH VALUE (limit enforcement):
- Withdrawal / transfer (wallet balance check -> debit)
- Purchase of limited-quantity items
- Rate-limited API endpoints (forgot password, OTP, login)
- Free tier usage limits (API calls, downloads, exports)
- Like/vote/reaction (should be once per user)
MEDIUM (state transitions):
- Order cancellation after fulfillment starts
- Account deletion (deletes while logged in)
- Permission changes concurrent with permission check
- File upload + virus scan + availability window
```
```bash
# Find limit-enforcement endpoints from prior recon:
grep -i "coupon\|promo\|voucher\|redeem\|claim\|bonus\|reward\|withdraw\|transfer\|limit\|rate" \
~/pentest-toolkit/results/<target>/interesting_recon.md 2>/dev/null
# Also check: /api/v*/wallet, /api/v*/coupon, /api/v*/redeem, /api/v*/transfer
```
---
## Phase 2 - HTTP/2 Single-Packet Attack (James Kettle, Black Hat 2023)
**The gold standard.** All requests in ONE TCP segment = identical server arrival time.
```python
#!/usr/bin/env python3
# single_packet_race.py - HTTP/2 single packet race conditionFrom kalpmodi/akira, MIT.
More from kalpmodi/akira
- 0.552score
plan-engagement
kalpmodi
Use when starting any pentesting engagement, receiving a target domain or IP, saying "new engagement", "start a pentest", "plan this target", or beginning any…
SkillCFreshness: C★ 23Claude Code +9 - 0.491score
zerodayhunt
kalpmodi
Use when hunting for zero-days, backdoors, RCE, supply chain attacks, JWT vulnerabilities, cache poisoning, HTTP smuggling, dependency confusion, source map…
SkillDFreshness: D★ 23Claude Code +9 - 0.491score
oauth-attacks
kalpmodi
Use when attacking OAuth 2.0 or OIDC implementations, testing for authorization code interception, PKCE bypass, open redirect chains, token leakage via…
SkillDFreshness: D★ 23Claude Code +9 - 0.491score
recon
kalpmodi
Use when running reconnaissance on a pentest target, starting phase 1 of an engagement, gathering subdomains, DNS resolution, live hosts, port scan results…
SkillDFreshness: D★ 23Claude Code +9 - 0.491score
redteam
kalpmodi
Use when running APT-level red team operations, post-exploitation, lateral movement, credential harvesting, Active Directory attacks (Kerberoasting, DCSync…
SkillDFreshness: D★ 23Claude Code +9 - 0.491score
report
kalpmodi
Use when generating a pentest report, writing up findings from a completed assessment, converting triage output into a structured document, or producing an…
SkillDFreshness: D★ 23Claude Code +9 - 0.491score
triage
kalpmodi
Use when aggregating pentest findings across all phases, clustering vulnerabilities by severity, prioritizing findings for a report, or surfacing the top…
SkillDFreshness: D★ 23Claude Code +9 - 0.491score
ad-attacks
kalpmodi
Use when attacking Active Directory environments, hunting Kerberoastable accounts, AS-REP roasting, DCSync, Pass-the-Hash, Pass-the-Ticket, BloodHound path…
SkillDFreshness: D★ 23Claude Code +9 - 0.491score
compact
kalpmodi
Use when context is running long during a pentest engagement, at phase boundaries after completing a full phase, or when the user says "compact", "compress…
SkillDFreshness: D★ 23Claude Code +9 - 0.491score
exploit
kalpmodi
Use when running exploitation phase of a pentest, testing for SQL injection, XSS, SSRF, JWT confusion, deserialization, prototype pollution, HTTP smuggling…
SkillDFreshness: D★ 23Claude Code +9 - 0.487score
secrets
kalpmodi
Use when hunting for secrets, API keys, tokens, or credentials on a pentest target, running phase 2 of an engagement, scanning JS files for hardcoded secrets…
SkillDFreshness: D★ 23Claude Code +9 - 0.487score
ctf
kalpmodi
Use when working on CTF (Capture the Flag) challenges, HackTheBox machines, TryHackMe rooms, pwn challenges, reverse engineering, cryptography puzzles…
SkillDFreshness: D★ 23Claude Code +9
Signals
- Stars
- 23
- Forks
- 4
- Open issues
- 0
- Last commit (this folder)
- Apr 25, 2026 (6 months ago)
- Last release
- Apr 25, 2026 (6 months ago)
From GitHub (fetched Oct 24, 2026).
Details
- License
- MIT
- Repository
- github.com/kalpmodi/akira
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from kalpmodi
- 0.552score
plan-engagement
kalpmodi
Use when starting any pentesting engagement, receiving a target domain or IP, saying "new engagement", "start a pentest", "plan this target", or beginning any…
SkillCFreshness: C★ 23Claude Code +9 - 0.491score
exploit
kalpmodi
Use when running exploitation phase of a pentest, testing for SQL injection, XSS, SSRF, JWT confusion, deserialization, prototype pollution, HTTP smuggling…
SkillDFreshness: D★ 23Claude Code +9 - 0.491score
ad-attacks
kalpmodi
Use when attacking Active Directory environments, hunting Kerberoastable accounts, AS-REP roasting, DCSync, Pass-the-Hash, Pass-the-Ticket, BloodHound path…
SkillDFreshness: D★ 23Claude Code +9 - 0.491score
triage
kalpmodi
Use when aggregating pentest findings across all phases, clustering vulnerabilities by severity, prioritizing findings for a report, or surfacing the top…
SkillDFreshness: D★ 23Claude Code +9 - 0.491score
compact
kalpmodi
Use when context is running long during a pentest engagement, at phase boundaries after completing a full phase, or when the user says "compact", "compress…
SkillDFreshness: D★ 23Claude Code +9 - 0.491score
oauth-attacks
kalpmodi
Use when attacking OAuth 2.0 or OIDC implementations, testing for authorization code interception, PKCE bypass, open redirect chains, token leakage via…
SkillDFreshness: D★ 23Claude Code +9
Cite this page
race-conditions skill. Agent Mart. https://agentmart.dev/skills/kalpmodi-race-conditions (last updated 2026-10-24)