Aller au contenu
Skillpedia
Sécurité7.7k · #13102

dnr-respond

Ce qu’il fait

Cette compétence guide la réponse à une piste de sécurité précise, comme une alerte, une adresse suspecte ou une découverte issue d'une recherche. Elle contrôle les journaux, le code source et un test local, puis propose des mesures de confinement et de correction. Elle s'adresse aux personnes qui gèrent les incidents de sécurité.

Quand l’utiliser

  • ✓Quand vous avez une alerte de sécurité et devez savoir si l'attaque a réussi.
  • ✓Quand vous voulez mesurer combien d'utilisateurs ou de systèmes une attaque a touchés.
  • ✓Quand vous avez besoin d'un plan de réponse proposé, sans que l'agent l'exécute lui-même.

Lien du skill

https://github.com/anthropics/defending-code-reference-harness/blob/main/.claude/skills/dnr-respond/SKILL.md

Copiez-le et collez-le dans votre IA (Claude, ChatGPT ou Cursor) en lui demandant de suivre les instructions.

Comment l’utiliser

Le plus simple : copiez le message et collez-le dans votre IA. Elle lit le skill et suit les instructions.

Message prêt à coller

Utilise ce skill pour m’aider : https://github.com/anthropics/defending-code-reference-harness/blob/main/.claude/skills/dnr-respond/SKILL.md Lis le fichier SKILL.md de ce lien et suis ses instructions pour ma tâche.
Envie que votre IA trouve seule des skills comme celui-ci ?Installez le MCP gratuit de Skillpedia : une ligne, et elle cherche parmi 15 000+ skills avant chaque tâche.Installer en 1 minute →

Exemple de demande à votre IA

“Peux-tu vérifier si cette alerte de connexion suspecte a mené à une attaque réussie, et jusqu'où elle s'est propagée ?”

5 nouveaux skills par semaine. 1 minute de lecture.

Comment ça marche

L'agent recherche la piste dans les journaux, détermine si l'attaque a réussi, cherche la cause dans le code source et rédige un plan que vous examinez avant toute action.

Contenu technique (SKILL.md original)

Texte original de l’auteur, en anglais, directement depuis GitHub.

dnr-respond

Lead-in-hand incident response: take one concrete starting point and answer the four questions an incident commander needs, in order — what happened, did it succeed, how far did it go, and what do we do about it. The output is a verdict, a quantified blast radius, a root cause proven in source, and a response plan that is proposed, never executed.

Invoke with /dnr-respond <lead> [--logs dir] [--repo path] [--fresh].

The lead ($1) can be:

  • an incident id from the hunt's INCIDENTS.json (e.g. INC-2) — the /dnr-hunt handoff
  • an alert pasted from an alert queue (JSON line or prose)
  • an IOC: an IP, an account name, a route, a session identifier
  • free text ("a customer says their address was quoted in a phishing email")

Other arguments:

  • --logs = logs directory or dnr target directory (same resolution as /dnr-hunt; defaults to targets/dnrcanary if it exists, else cwd).
  • --repo = application source (defaults to the target's app/).
  • --fresh = ignore any checkpoint in the run dir's .dnr-respond-state/ and mint a new run dir.

Hard rules (shared with /dnr-hunt — the track's contract)

  1. Log evidence alone never confirms a vulnerability. confirmed_exploited requires log evidence + the flaw in source + a PoC fired locally this session. Otherwise the ceiling is suspected.
  2. Query, don't read. Never Read or cat a log file; wc/head/ tail to profile, grep/awk/sort/uniq/python3 to interrogate. Small files (alert queues, error logs under ~200 lines) may be read whole.
  3. Propose, never execute. No blocking, disabling, rotating, or config changes — in any environment, including the demo app. The plan names actions; humans execute them.
  4. Local only. PoCs fire at 127.0.0.1 against an instance you started. Never touch a remote host.
  5. Every number is a query result. "How many records" and "how many customers" get answered by pipelines run this session, never estimated.

Run directory and checkpointing

First action — establish the run directory, the same way /dnr-hunt does, but as a consumer. Let TARGET be the basename of the resolved --logs/target path (default targets/dnrcanary) and SCOPE that path.

  • Lead is INC-n (the /dnr-hunt handoff, or a second lead from a hunt you already started responding to): work the response into the investigation that incident lives in. {RUN} is the newest results/TARGET/<timestamp>/ directory that contains an INCIDENTS.json — find it with Bash, e.g. ls -1d results/TARGET/*/ | sort -r | while read d; do [ -f "$d/INCIDENTS.json" ] && echo "$d" && break; done. Do not call rundir for an INC-n lead — rundir mints a fresh empty dir once a prior /dnr-respond in that dir has completed, which would strand the incident's INCIDENTS.json in the old dir. Only if no run dir holds an INCIDENTS.json (you were handed INC-n but never ran the hunt) fall through to the rundir line below.
  • Any other lead (alert, IOC, free text): Bash python3 .claude/skills/_lib/checkpoint.py rundir results/TARGET --state .dnr-respond-state --scope "SCOPE" (append --fresh if it's in $ARGUMENTS). This adopts the newest run dir for the target if one exists, else mints a fresh results/TARGET/<timestamp>/.

That path is {RUN}; substitute the literal path everywhere below, and double-quote it (and SCOPE) in Bash.

Checkpoint mechanics are identical to /dnr-hunt, state dir {RUN}/.dnr-respond-state/, phases 0–4. When {RUN} already holds a completed .dnr-respond-state from an earlier lead, load reports complete and the rules below reset it cleanly — a second lead enriches the same INCIDENTS.json and writes its own RESPONSE-<lead>.md. On start: python3 .claude/skills/_lib/checkpoint.py load {RUN}/.dnr-respond-state — absent/complete/--fresh → reset and start at Phase 0; running with phase_done == N → read phase0.json…phaseN.json, resume at N+1. After each phase: Write payload to {RUN}/.dnr-respond-state/_chunk.tmp, then checkpoint.py save {RUN}/.dnr-respond-state <N> <name> --from {RUN}/.dnr-respond-state/_chunk.tmp. Never write progress.json directly; never pass payload via heredoc/stdin. After outputs: checkpoint.py done {RUN}/.dnr-respond-state 4.

Phase 0 — Parse the lead, locate inputs

  1. Resolve --logs (dnr target config or bare directory) and inventory log fil
Questions fréquentes

L'agent corrige-t-il lui-même le problème ?

Non. Le plan n'est que proposé et n'est jamais exécuté par l'agent.

Quelle peut être la piste de départ ?

Ce peut être un identifiant d'incident, une alerte collée, une adresse, un nom de compte ou une courte description.

Est-ce la même chose que la compétence de recherche ?

Elle suit les mêmes règles, mais part d'une piste connue au lieu de chercher sans alerte.

Détails

Description originale de l’auteur

Incident response workup for a lead in hand — an alert, an IOC, or a /dnr-hunt finding. Scopes the lead across the logs, verdicts whether the attack succeeded, quantifies blast radius, confirms root cause in source with a local PoC, and writes a proposed (never executed) containment/remediation/recovery plan. Use when asked to "respond to this alert", "work this incident", "how bad is this", or "run dnr-respond". /dnr-hunt is the no-alert entry to the same track.

repo: anthropics/defending-code-reference-harness

Popularité

Étoiles GitHub
7.7k
Position au classement
#13102
Licence
—
Mis à jour
06/08/2026

Ce skill vous est-il utile ?

0

Connectez-vous pour voter.

Commentaires

  • …

Autres skills de ce dépôt

Skills similaires