hunt-csrf

hunt-csrf is a skill for Claude Code, Codex from uphiago/recon-skills. It costs 188 tokens per session (6,651 once invoked), scanned D, original, MIT.

A security-testing guide for finding cross-site request forgery, or CSRF. CSRF tricks a logged-in user's browser into sending unwanted changes to a website, such as changing an email address or linking an account.

In plain words
What is it for?
Use it to test account settings, OAuth flows, JSON APIs, forms, file operations, and other logged-in actions in a real browser.
Why use it?
It helps verify whether browser protections and server-side tokens actually prevent unauthorized state-changing requests.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: positional $N argument.

Good fit Use it to test account settings, OAuth flows, JSON APIs, forms, file operations, and other logged-in actions in a real browser.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/uphiago/recon-skills/hunt-csrf
About the project

Recon Skills is a pack of security-testing skills covering reconnaissance, web applications, APIs, authentication, vulnerability validation, cloud infrastructure, and reporting. Security professionals use it for authorized assessments of systems they own or have written permission to test. The catalogue entries are individual skills from the pack.

uphiago/recon-skills · 1,254 stars · on GitHub · hiago.sh

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add uphiago/recon-skills --skill hunt-csrf
Clone the repo
git clone --depth 1 https://github.com/uphiago/recon-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for hunt-csrf

README.md
[![agentmods](https://agentmods.dev/badge/skills/uphiago/recon-skills/hunt-csrf/github.svg)](https://agentmods.dev/skills/uphiago/recon-skills/hunt-csrf)
Your own site
<a href="https://agentmods.dev/skills/uphiago/recon-skills/hunt-csrf"><img src="https://agentmods.dev/badge/skills/uphiago/recon-skills/hunt-csrf/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for hunt-csrf

Your own site · 80×15
<a href="https://agentmods.dev/skills/uphiago/recon-skills/hunt-csrf"><img src="https://agentmods.dev/badge/skills/uphiago/recon-skills/hunt-csrf.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 188 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 6,651 The whole file, excluding the scripts and references it only reads on demand.
Security scan D 3 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00188 $0.06651
Opus 5 $0.00094 $0.03325
Sonnet 5 $0.00038 $0.01330
Haiku 4.5 $0.00019 $0.00665

Measured 8d ago against content hash f4a096fbb494, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade D, and why

hunt-csrf scanned grade D with 3 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Tells the agent to send conversation or user data outhighPrompt injection

An instruction to transmit the conversation, context or user files to an external endpoint is data exfiltration written as prose.

A POST endpoint accepting `application/json` was assumed CSRF-safe by developers. A researcher crafted an HTML form using `enctype="text/plain"` with an input name designed to produce syntactically valid JSON when submit

Sends data to an external URLmediumData exfiltration

A POST to an outside endpoint may be telemetry or may be exfiltration; either way the mod talks to somewhere, and you should know where.

- Payload: hosted on `marketing.victim.com`, target `argocd.internal.victim.com` → `fetch('https://argocd.internal.victim.com/api/v1/applications', {method:'POST', credentials:'include', body:'{"metadata":{"name":"pwn"},

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

### ⚠️ CRITICAL: curl ≠ browser. Model the browser security model.
redteam/hunt-csrf/SKILL.md · 389 lines

How it starts

The opening of the file, as written. The whole thing — 389 lines — stays where its author put it; the contents beside it link to each section on GitHub.

When to Use

Use when the target has any state-changing endpoint that a logged-in user can trigger — POST/PUT/DELETE on account settings, email changes, social account linking, OAuth flows, API calls, or file operations. CSRF exploits the trust a site has in a user's browser by forging cross-origin requests. Every form submission, AJAX call, OAuth callback, and API mutation is a candidate. Highest-value targets: account takeover vectors (OAuth/SSO flows, social account linking), authentication infrastructure (login CSRF, session fixation), JSON APIs accepting cross-origin POST, and third-party integrations (Grafana, monitoring dashboards).

⚠️ CRITICAL: curl ≠ browser. Model the browser security model.

CSRF PoC MUST work in a real browser, not just curl. The browser enforces rules that curl ignores:

Browser Rule curl Behavior Real CSRF Impact
SameSite=Lax curl sends cookie anyway Blocks cookie on cross-site POST — no CSRF
SameSite=Strict curl sends cookie anyway Blocks cookie on all cross-site requests — no CSRF
CORS preflight curl skips OPTIONS Browser blocks if Content-Type: application/json
Sec-Fetch-Site: cross-site curl doesn't send Server can reject cross-site requests via this header

CSRF verification checklist:

  1. ✅ Endpoint changes state (POST/PUT/DELETE)
  2. ✅ Cookie has SameSite=None OR SameSite=Lax with GET-based action
  3. ✅ No custom CSRF token/header required
  4. ✅ PoC works from a different origin in a real browser

If step 2 fails (SameSite=Lax on POST endpoint) → NOT exploitable CSRF via curl alone. SameSite=Lax allows cookies on top-level navigation GET, not cross-site POST. A curl POST succeeding with the cookie is a false positive — the browser would block it.

CSRF Middleware Protection Bypass:

  • Many modern web frameworks (for example, those with CSRF protection enabled by default) reject state-changing requests such as POST, PUT, or DELETE with a 403 Forbidden response when the CSRF token is missing or invalid.
  • In some applications, if the PATCH method is not covered by the same CSRF middleware or is handled differently, it may be possible to perform the same state-changing action using PATCH instead. This can result in a CSRF protection bypass if the server accepts the request without validating a CSRF token.

Read the full file on GitHub · 389 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 8d ago First seen · 389 lines · 188 tokens per session scan D f4a096fbb494

Subscribe to this mod's changes

hunt-csrf is a skill published in the GitHub repository uphiago/recon-skills (1,254 stars, last pushed 10d ago), licensed MIT. It adds 188 tokens to every session and 6,651 once invoked, about $0.0009 per session on Opus 5. A static security scan graded it D with 3 findings (tells the agent to send conversation or user data out, sends data to an external url, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

web2-vuln-classes

Complete reference for 26 web2 bug classes with root causes, detection patterns, bypass tables, exploit techniques, and real paid examples. Covers IDOR, auth bypass, XSS, SSRF (11 IP bypass techniques), SQLi, business logic, race conditions, OAuth/OIDC, file upload (10 bypass techniques), GraphQL, LLM/AI (ASI01-ASI10…

Awarexone/Agentic-Bug-Hunter · 351 tokens

auditing-gcp-iam-permissions

Auditing Google Cloud Platform IAM permissions to identify overly permissive bindings, primitive role usage, service account key proliferation, and cross-project access risks using gcloud CLI, Policy Analyzer, and IAM Recommender.

xalgorix/xalgorix · 51 tokens

detecting-compromised-cloud-credentials

Detecting compromised cloud credentials across AWS, Azure, and GCP by analyzing anomalous API activity, impossible travel patterns, unauthorized resource provisioning, and credential abuse indicators using GuardDuty, Defender for Identity, and SCC Event Threat Detection.

xalgorix/xalgorix · 55 tokens

implementing-aws-config-rules-for-compliance

Implementing AWS Config rules for continuous compliance monitoring of AWS resources, deploying managed and custom rules aligned to CIS and PCI DSS frameworks, configuring automatic remediation with SSM Automation, and aggregating compliance data across accounts.

xalgorix/xalgorix · 53 tokens

implementing-cloud-dlp-for-data-protection

Implementing Cloud Data Loss Prevention (DLP) using Amazon Macie, Azure Information Protection, and Google Cloud DLP API to discover, classify, and protect sensitive data across cloud storage, databases, and data pipelines.

xalgorix/xalgorix · 54 tokens

implementing-cloud-trail-log-analysis

Implementing AWS CloudTrail log analysis for security monitoring, threat detection, and forensic investigation using Athena, CloudWatch Logs Insights, and SIEM integration to identify unauthorized access, privilege escalation, and suspicious API activity.

xalgorix/xalgorix · 50 tokens