ssrf-and-url-allowlists

ssrf-and-url-allowlists is a skill for Claude Code, Codex from makifbaysal/tasktrooper. It costs 59 tokens per session (1,727 once invoked), scanned C, original, Apache-2.0.

A guide to server-side request forgery (SSRF), where an attacker makes your server send requests to places they should not reach. It covers validating user-influenced URLs, including redirects and DNS changes, against allowed destinations.

In plain words
What is it for?
Use it when server code fetches, renders, redirects to, or checks a URL that users can influence, including OAuth or key-discovery URLs and PDF renderers.
Why use it?
It helps prevent servers from being used to access internal services, cloud metadata, or other protected systems through imports, previews, webhooks, and similar features.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it when server code fetches, renders, redirects to, or checks a URL that users can influence, including OAuth or key-discovery URLs and PDF renderers.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/makifbaysal/tasktrooper/ssrf-and-url-allowlists
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 makifbaysal/tasktrooper --skill ssrf-and-url-allowlists
Clone the repo
git clone --depth 1 https://github.com/makifbaysal/tasktrooper

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 ssrf-and-url-allowlists

README.md
[![agentmods](https://agentmods.dev/badge/skills/makifbaysal/tasktrooper/ssrf-and-url-allowlists/github.svg)](https://agentmods.dev/skills/makifbaysal/tasktrooper/ssrf-and-url-allowlists)
Your own site
<a href="https://agentmods.dev/skills/makifbaysal/tasktrooper/ssrf-and-url-allowlists"><img src="https://agentmods.dev/badge/skills/makifbaysal/tasktrooper/ssrf-and-url-allowlists/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 ssrf-and-url-allowlists

Your own site · 80×15
<a href="https://agentmods.dev/skills/makifbaysal/tasktrooper/ssrf-and-url-allowlists"><img src="https://agentmods.dev/badge/skills/makifbaysal/tasktrooper/ssrf-and-url-allowlists.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 59 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,727 The whole file, excluding the scripts and references it only reads on demand.
Security scan C 2 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.00059 $0.01727
Opus 5.5 $0.00024 $0.00691
Sonnet 5.5 $0.00012 $0.00345
Haiku 4.5 $0.00006 $0.00173

Measured 4d ago against content hash 689c5315c8f0, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade C, and why

ssrf-and-url-allowlists scanned grade C with 2 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 4d 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.

Cloud metadata endpointhighServer-side request forgery

One request to 169.254.169.254 can return temporary IAM credentials.

- Cloud metadata raises severity: AWS IMDSv1 (`http://169.254.169.254/latest/meta-data/iam/security-credentials/`) answers a plain GET with credentials. IMDSv2 (PUT-token), GCP (`Metadata-Flavor: Google`) and Azure (`Met

Makes network callslowCapability

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

- Reporting `fetch(userUrl)` in a React component.
catalog/agents/security-agent/skills/ssrf-and-url-allowlists/SKILL.md · 102 lines

How it starts

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

SSRF and URL Allowlists

Overview

Server-side request forgery turns your server into the attacker's network client — inside your VPC, past your firewall, next to the cloud metadata service. Since OWASP Top 10:2025 it sits under A01 Broken Access Control (CWE-918).

Core principle: validate the address you actually connect to, after DNS, on every hop — not the string the user typed.

1. Is It a Finding?

  • The attacker must control the scheme or host (or the whole URL). Path-only control on a fixed host is excluded.
  • The fetch happens server-side. SSRF in browser or mobile client code is not a finding.
  • Impact: response returned to the attacker (full read), or side effects on internal services (blind). Blind SSRF still matters when internal endpoints act on GET.
  • Cloud metadata raises severity: AWS IMDSv1 (http://169.254.169.254/latest/meta-data/iam/security-credentials/) answers a plain GET with credentials. IMDSv2 (PUT-token), GCP (Metadata-Flavor: Google) and Azure (Metadata: true) require a header a simple SSRF usually cannot set — check what the deployment runs before calling it CRITICAL.

2. Allowlist Bypasses

// ❌ substring: "https://example.com.evil.net" and "https://evil.net/?x=example.com" pass
if (!url.includes("example.com")) throw new Error("blocked");

// ❌ suffix without a dot boundary: "https://evilexample.com" passes
if (!new URL(url).hostname.endsWith("example.com")) throw ...

// ❌ regex with an unescaped dot and no end anchor: "https://api.example.com.evil.net"
if (!/^https:\/\/api.example.com/.test(url)) throw ...

// ✅ parse once, compare exact host (or a dot-bounded suffix), fixed scheme
const u = new URL(url);
const ok = u.protocol === "https:" && (u.hostname === "example.com" || u.hostname.endsWith(".example.com"));

Parser tricks that defeat string checks:

  • Userinfo: https://[email protected]/ — the host is evil.net.
  • Backslash and parser differentials: https://evil.net\@example.com/ — validators and HTTP clients disagree (WHATWG vs RFC 3986). Validate with the same parser the fetcher uses, or better, the fetcher's resolved address.
  • Base-URL resolution: new URL(userPath, base), Python urljoin(base, user) and Java URI.resolve let //evil.net/x or a full https://evil.net replace the base host.

Read the full file on GitHub · 102 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. 4d ago First seen · 102 lines · 59 tokens per session scan C 689c5315c8f0

Subscribe to this mod's changes

ssrf-and-url-allowlists is a skill published in the GitHub repository makifbaysal/tasktrooper (113 stars, last pushed yesterday), licensed Apache-2.0. It adds 59 tokens to every session and 1,727 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it C with 2 findings (cloud metadata endpoint, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-09.