proxy-client-address

proxy-client-address is a skill for Claude Code from KhaledSaeed18/dotclaude. It costs 45 tokens per session (850 once invoked), scanned A, original, MIT.

A server-side pattern for passing a user's real network address through a front-end proxy to an API. It uses a shared secret so the API can reject addresses invented by browsers.

In plain words
What is it for?
Use it when a browser-facing server forwards requests to an API and the API needs per-user rate limiting or audit information based on the client address.
Why use it?
Without it, the API sees the proxy's address for every user, which combines rate limits and audit records. It also prevents clients from forging forwarded address headers.

Skill for Claude Code

Written for Claude Code: argument-hint in frontmatter.

Part of the deploy plugin — 9 skills, 3 commands, 1 agent shipped together

Good fit Use it when a browser-facing server forwards requests to an API and the API needs per-user rate limiting or audit information based on the client address.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/khaledsaeed18/dotclaude/proxy-client-address
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 KhaledSaeed18/dotclaude --skill proxy-client-address
Clone the repo
git clone --depth 1 https://github.com/KhaledSaeed18/dotclaude

Made for: Claude Code.

Or install deploy, the plugin that ships this one along with the rest of its 9 skills, 3 commands, 1 agent.

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 proxy-client-address

README.md
[![agentmods](https://agentmods.dev/badge/skills/khaledsaeed18/dotclaude/proxy-client-address/github.svg)](https://agentmods.dev/skills/khaledsaeed18/dotclaude/proxy-client-address)
Your own site
<a href="https://agentmods.dev/skills/khaledsaeed18/dotclaude/proxy-client-address"><img src="https://agentmods.dev/badge/skills/khaledsaeed18/dotclaude/proxy-client-address/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 proxy-client-address

Your own site · 80×15
<a href="https://agentmods.dev/skills/khaledsaeed18/dotclaude/proxy-client-address"><img src="https://agentmods.dev/badge/skills/khaledsaeed18/dotclaude/proxy-client-address.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 45 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 850 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 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.00045 $0.00850
Opus 5.5 $0.00018 $0.00340
Sonnet 5.5 $0.00009 $0.00170
Haiku 4.5 $0.00005 $0.00085

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

Security

Grade A, and why

proxy-client-address scanned grade A with 0 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 11d 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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude-plugin/plugins/deploy/skills/proxy-client-address/SKILL.md · 36 lines

How it starts

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

When a browser calls a front-end server that forwards to an API, the API's peer is the front-end for every user: one rate-limit bucket and one audit address for everyone. Fix it with a named address the API believes only next to a shared secret, derived from the one forwarded header the edge proxy wrote itself.

Hard rules: never break these

  • Never trust X-Forwarded-For from the client side. Only the entry the edge proxy appended is real; confirm which entry that is for the proxy in front of you before relying on it.
  • The secret is runtime, server-only, identical on both sides, generated by the owner (openssl rand -base64 32), pasted into both deployments, never in a repository or a client bundle.
  • Strip the headers on the way in. The front-end deletes any x-<app>-proxy-secret or x-<app>-client-ip a browser sent before setting its own; the API deletes both after reading them.
  • Compare the secret in constant time on digests, so length and content leak nothing.
  • Without the secret, behave as before. The front-end falls back to the plain rewrite; the API falls back to req.ip. Rollout is safe in any order.

Step 1: Establish the proxy's behaviour

Read the edge proxy's configuration (Traefik: docker inspect coolify-proxy --format '{{json .Args}}' | grep -i forwarded). With no trusted IPs configured, Traefik discards client-sent X-Forwarded-* and writes the peer address itself, so the last entry is the client; a platform edge behaves the same. If trusted IPs or insecure are set, the client's forged entries survive in front of the real one and the last entry is still the real one. A Node server does not append. Document the finding.

Step 2: Front-end side (the BFF)

In the Next.js proxy (or middleware), for /api/* requests: when the secret is configured, rewrite to the API origin with two added request headers, else return nothing and let next.config rewrites handle it. Server-side fetches (Server Components) add the same headers from next/headers. Snippets in reference/snippets.md.

Read the full file on GitHub · 36 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 11d ago First seen · 36 lines · 45 tokens per session scan A 71da153c308f

Subscribe to this mod's changes

proxy-client-address is a skill published in the GitHub repository KhaledSaeed18/dotclaude (5 stars, last pushed 2d ago), licensed MIT. It adds 45 tokens to every session and 850 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-05.

Related

Other skills, from other repositories

form-strategy

Design forms that convert, validate well, resist spam, and integrate cleanly with downstream systems. Use this skill when designing or auditing any form (contact, signup, checkout, multi-step, embedded), planning validation logic, fighting spam, choosing form tooling, or improving form conversion. Triggers on form…

rampstackco/claude-skills · 107 tokens

netlify-development

Best practices for building and deploying Netlify sites, covering serverless and edge functions, Netlify Blobs storage, the Image CDN, and build configuration. Use when writing Netlify Functions or Edge Functions, configuring netlify.toml or redirects/headers, managing environment variables across deploy contexts…

Mindrally/skills · 78 tokens

nextauth-authentication

Guidelines for implementing NextAuth.js (Auth.js v5) authentication in Next.js applications with session management and security best practices.

Mindrally/skills · 30 tokens

api-security-best-practices

Implement secure API design patterns including authentication, authorization, input validation, rate limiting, and protection against common API vulnerabilities.

lingxling/awesome-skills-cn · 29 tokens

apollo-graphql

Guidelines for developing GraphQL APIs and React applications using Apollo Client for state management, data fetching, and caching.

Mindrally/skills · 26 tokens

clerk-authentication

Guidelines for implementing Clerk authentication in Next.js applications with middleware, hooks, and security best practices.

Mindrally/skills · 24 tokens