Agent skill

Codex Adversarial Review

by WrongStack in WrongStack/WrongStack

A skill your agent uses to conduct aggressive, adversarial code reviews on git changes, branches, or PRs to detect critical edge cases, race conditions, security holes, and data loss risks.

MITAuto-check passedDevelopment

Install Codex Adversarial Review

skills CLI
$ npx skills add WrongStack/WrongStack --skill codex-adversarial-review -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install WrongStack/WrongStack codex-adversarial-review --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/WrongStack/WrongStack.git skills-src && mkdir -p .claude/skills && cp -r skills-src/packages/core/skills/codex-adversarial-review .claude/skills/codex-adversarial-review && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
codex-adversarial-review
GitHub stars
371
Token cost
~2k tokens
SKILL.md length
657 words
Files
1
Skills in repo
100
Repo updated
First seen
Licence
MIT

At a glance

A skill your agent uses to conduct aggressive, adversarial code reviews on git changes, branches, or PRs to detect critical edge cases, race conditions, security holes, and data loss risks.

  • Works in 2 steps: Adversarial Audit Finding Template → Idempotency & Webhook Double-Spend…
  • Conduct aggressive
  • SKILL.md covers Selection card, Overview, Rules and Pre-Flight Verification Runbook, plus 6 more sections
  • Calls git

What it does

Codex Adversarial Review is an agent skill from WrongStack/WrongStack. Use this skill to conduct aggressive, adversarial code reviews on git changes, branches, or PRs to detect critical edge cases, race conditions, security holes, and data loss risks. Triggers: user mentions "adversarial review", "break the code", "find vulnerabilities", "security audit PR", "race condition check", "ship gate", "pre-merge audit".

Its SKILL.md is about 2k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Development, covering Async programming, Code review and Security review. It works with Git. The repository describes itself as: An AI coding agent that reads your code, edits files, runs commands, and reasons through bugs — across a terminal REPL, a full-screen TUI, and a browser UI, while you keep your… The licence is MIT.

When your agent uses it

  • Conduct aggressive
  • Adversarial code reviews on git changes
  • PRs to detect critical edge cases
  • Race conditions

Example prompts

  • “adversarial review”
  • “break the code”
  • “find vulnerabilities”
  • “/codex-adversarial-review”

Workflow steps

2 steps, taken from the step headings in SKILL.md.

  1. Adversarial Audit Finding Template
  2. Idempotency & Webhook Double-Spend Vulnerability

What it can do on your machine

Read from SKILL.md and the folder at commit a744bdc. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • git

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use git, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Codex Adversarial Review loads about 2k tokens when it runs. Until then it costs about 93 tokens; SKILL.md has 657 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~93
When it runs · the whole SKILL.md, loaded when a task matches
~2k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from WrongStack/WrongStack at commit a744bdc, republished under its MIT licence (© WrongStack). 657 words, ~1,958 tokens.

Download SKILL.mdSave it as .claude/skills/codex-adversarial-review/SKILL.md (or your agent's skills folder).
name
codex-adversarial-review
description
Use this skill to conduct aggressive, adversarial code reviews on git changes, branches, or PRs to detect critical edge cases, race conditions, security holes, and data loss risks. Triggers: user mentions "adversarial review", "break the code", "find vulnerabilities", "security audit PR", "race condition check", "ship gate", "pre-merge audit".
version
1.2.1
required-capabilities
filesystem.read
optional-capabilities
version-control.manage
trigger
Use this skill to conduct aggressive, adversarial code reviews on git changes, branches, or PRs to detect critical edge cases, race conditions, security…
metadata.routing-group
quality

Codex Adversarial Code Review Architecture

Selection card

  • Task: Review adversarially and propose approval-gated fixes. / TR: Karşıt bakışla incele ve onay gerektiren düzeltme öner.
  • Start: Identify the scope and obtain an executable before-proof or review evidence.
  • Finish: apply the acceptance checks below; report observed results and unresolved constraints.

Overview

The purpose of an adversarial code review is not to validate the author's work, but to aggressively break confidence in the change by uncovering subtle, high-cost, or user-visible failure modes before the code reaches production. Reviewers adopt the mindset of an attacker, a chaotic network environment, and an overloaded database.

Rules

  1. Pre-flight: Inspect repo diff & live security advisories first. Read the full git diff, surrounding call sites, and recent dependency changes in package.json / lockfiles. Cross-reference suspicious patterns or third-party packages against live security advisories (e.g. GitHub Advisory Database, CVE feeds) before auditing logic.
  2. Default to skepticism. Assume the change fails in high-risk ways until concrete evidence proves safety.
  3. Focus on high-damage attack surfaces: auth boundaries, tenant isolation, data loss/corruption, idempotency gaps, and race conditions.
  4. Ignore superficial style, formatting, and naming feedback; report only material, high-impact defects.
  5. Strict Stop Rule: After presenting review findings, STOP. Never modify code or auto-apply fixes without explicit confirmation from the user.
  6. Issue a clear ship decision: BLOCKING_RISKS_DETECTED if blocking risks exist, or APPROVE only if no substantive flaws can be proven.
  7. Construct reproducible proof-of-concept payloads or call sequences for every flagged vulnerability.
  8. Verify database mutations are wrapped inside atomic transactions with rollbacks on failure.

Pre-Flight Verification Runbook

Before beginning the adversarial audit:

  1. Extract Changed Files and Git Diffs:
    bash
    git diff --name-only origin/main...HEAD
    git diff origin/main...HEAD
  2. Scan for New or Modified Third-Party Dependencies:
    bash
    git diff origin/main...HEAD -- package.json pnpm-lock.yaml Cargo.toml
  3. Check for Security Advisories:
    • Query npm audit or vulnerability registries for any newly introduced packages.

The 5 Critical Attack Vectors

Attack VectorWhat to Look ForReal-World Impact
1. Broken Object-Level Authorization (IDOR)Fetching records by ID (/api/items/:id) without validating tenant / user ownershipData leakage across tenant boundaries
2. Race Conditions & Concurrency GapsRead-modify-write patterns without database-level row locks or atomic incrementsAccount double-spending, inventory overselling
3. Idempotency GapsWebhooks (e.g. Stripe, billing) that process charges without unique event ID deduplicationDuplicate charges, duplicated user credits
4. Partial Failure & Missing RollbacksMutating DB table A, calling external service B, then updating table C without a transactionInconsistent system state and silent data corruption
5. Resource Exhaustion / Unbounded I/OMissing LIMIT on queries, unescaped Regex on user strings (ReDoS), unbounded file uploadsServer CPU freeze, memory crash, denial of service
Show full SKILL.md (239 more words)Show less

Patterns

1. Adversarial Audit Finding Template
text
### [CRITICAL] Race Condition in Quota Deduction
- **File**: src/billing/quota.ts:45-62
- **Attack Vector**: Concurrent HTTP requests bypass usage limits
- **Proof of Concept**:
  Sending 10 concurrent requests when `remainingCredits = 1`:
  1. Request A reads remainingCredits = 1
  2. Request B reads remainingCredits = 1
  3. Request A executes operation and sets remainingCredits = 0
  4. Request B executes operation and sets remainingCredits = 0
  Result: User executes 2 operations while only paying for 1.
- **Remediation**:
  Replace application-level check with an atomic database query:
  `UPDATE users SET credits = credits - 1 WHERE id = $1 AND credits >= 1 RETURNING credits;`
2. Idempotency & Webhook Double-Spend Vulnerability
typescript
// ❌ VULNERABLE: Stripe webhook without idempotency or atomic transactions
export async function handleInvoicePaid(event: StripeEvent) {
  const invoice = event.data.object;
  const user = await db.query.users.findFirst({ where: eq(users.customerId, invoice.customer) });
  
  // Vulnerability: If Stripe sends duplicate webhooks, credits are added twice!
  await db.update(users).set({ credits: user.credits + 100 }).where(eq(users.id, user.id));
}

// ✅ SECURE & RESILIENT: Idempotency table + atomic transaction
export async function handleInvoicePaidSecure(event: StripeEvent) {
  const invoice = event.data.object;
  
  await db.transaction(async (tx) => {
    // 1. Guard against duplicate webhook deliveries
    const processed = await tx.insert(processedEvents).values({ id: event.id }).onConflictDoNothing();
    if (!processed.rowCount) return; // Already handled, exit safely

    // 2. Atomic credit increment
    await tx.update(users)
      .set({ credits: sql`credits + 100` })
      .where(eq(users.customerId, invoice.customer));
  });
}

Anti-patterns

  • Auto-applying fixes without confirmation: The reviewer's role is to stress-test and reveal failure modes, not to silently alter application code.
  • Reporting stylistic nits: Commenting on indentation, variable naming, or comment phrasing dilutes focus from actual exploits and critical bugs.
  • Assuming input is sanitized: Never assume client-provided IDs, numbers, or JSON payloads are validated upstream.
  • Assuming third-party SDK calls succeed: External network requests can time out, return 500s, or drop connections midway through operations.

Before returning

  • Full diff analyzed against main branch
  • Every finding cites exact file and line ranges
  • Concrete failure triggers and real-world consequences detailed
  • Explicit ship decision rendered (BLOCKING_RISKS_DETECTED or APPROVE)
  • Strict Stop Rule respected: No code edits executed without user confirmation

Review boundary and decision

Pin the exact change set and identify the implementation's actual trust/resource boundaries. Review owned source and bounded defensive checks; do not construct offensive workflows or contact live third-party targets. Every material finding needs a reachable condition, impact and confidence level; missing evidence is a validation gap. An approve verdict means no confirmed blockers in the examined scope, not a proof that every failure mode is impossible. The stop rule remains: return findings and wait for explicit confirmation before applying fixes.

Skills in scope

  • security-scanner — for running static AST checks and credential pattern scans
  • testing — for writing regression tests proving discovered vulnerabilities
  • tech-stack — for auditing supply chain packages and dependencies

© WrongStack, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in packages/core/skills/codex-adversarial-review of WrongStack/WrongStack.

Open the folder on GitHubat commit a744bdc

Compare with similar skills

Codex Adversarial Review next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Codex Adversarial Review compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Codex Adversarial Review this skillWrongStack/WrongStack371—~2kAutomated safety check: PassMIT
Code Review ChecklistshareAI-lab/learn-claude-code78k4 repos~1.1kAutomated safety check: PassMIT
Requesting Code ReviewHezaoHezao/poirot2495 repos~1.6kAutomated safety check: PassMIT
Openqodexopenqodex/openqodex524—~2.5kAutomated safety check: PassApache-2.0
Code Review with Beads Tasksmaslennikov-ig/claude-code-orchestrator-kit260—~2kAutomated safety check: PassCustom licence
Review Codetobihagemann/turbo408—~3.3kAutomated safety check: PassMIT

Similar skills

  • Code Review Checklist

    shareAI-lab/learn-claude-code

    Reviews code against a five-part checklist covering security, correctness, performance, maintainability and testing, and reports findings in a fixed format.

    78k GitHub starsUsed in 4 repos~1.1k tokens
    DevelopmentAuto-check passed
  • Requesting Code Review

    HezaoHezao/poirot

    Pre-commit review: security scan, quality gates, auto-fix. An agent skill from HezaoHezao/poirot.

    249 GitHub starsUsed in 5 repos~1.6k tokens
    DevelopmentAuto-check passed
  • Openqodex

    openqodex/openqodex

    Code review for the current change, before it is pushed. An agent skill from openqodex/openqodex.

    524 GitHub stars~2.5k tokensUpdated yesterday
    DevelopmentAuto-check passed
  • Code Review with Beads Tasks

    maslennikov-ig/claude-code-orchestrator-kit

    Reviews staged changes, a branch, a PR or a path for bugs, security gaps and performance issues, then writes an evidence-based report and creates Beads tasks.

    260 GitHub stars~2k tokensUpdated 7 mo ago
    DevelopmentAuto-check passed
  • Review Code

    tobihagemann/turbo

    Review code for bugs, security vulnerabilities, API misuse, consistency issues, simplicity problems, or test coverage gaps and low-value tests by running internal reviews and a peer review in…

    408 GitHub stars~3.3k tokensUpdated yesterday
    DevelopmentAuto-check passed
  • Review

    softspark/ai-toolkit

    Reviews code for quality, security, correctness. An agent skill from softspark/ai-toolkit.

    179 GitHub stars~3.1k tokensUpdated 2 days ago
    DevelopmentAuto-check: notes

More from WrongStack/WrongStack

All 100 skills in this repo
  • Tech Stack

    WrongStack/WrongStack

    Validate and upgrade dependencies against live registries and official migration guides in any ecosystem.

    371 GitHub stars~1.5k tokensUpdated yesterday
    Auto-check passed
  • Skill Creator

    WrongStack/WrongStack

    Create, improve and validate WrongStack SKILL.md bundles with precise discovery, progressive resources and current runtime contracts.

    371 GitHub stars~1.3k tokensUpdated yesterday
    Auto-check passed
  • Bug Hunter

    WrongStack/WrongStack

    A skill your agent uses when scanning source code for bugs, anti-patterns, code smells, or quality issues in a codebase, or when running a proof-driven bug hunt that must find, prove, fix, and…

    371 GitHub stars~2.4k tokensUpdated yesterday
    Auto-check passed
  • Design Craft

    WrongStack/WrongStack

    Design or substantially improve user-facing interfaces with a product-specific visual direction, content hierarchy, and rendered critique.

    371 GitHub stars~2.3k tokensUpdated yesterday
    Auto-check passed
  • Design Critique

    WrongStack/WrongStack

    A skill your agent uses to audit an interface that already exists and say precisely why it looks generated, templated, or unfinished — a scored rubric across composition, typography, color, states…

    371 GitHub stars~2.5k tokensUpdated yesterday
    Auto-check passed
  • Mailbox Bridge

    WrongStack/WrongStack

    A skill your agent uses when external coding agents (Claude Code, Aider, custom scripts) need to participate in the project's shared WrongStack mailbox, or when a user asks to "expose the mailbox"…

    371 GitHub stars~2.6k tokensUpdated yesterday
    Auto-check passed

Works with

Categories

Questions about Codex Adversarial Review

What does Codex Adversarial Review do?

A skill your agent uses to conduct aggressive, adversarial code reviews on git changes, branches, or PRs to detect critical edge cases, race conditions, security holes, and data loss risks. Codex Adversarial Review is an agent skill from WrongStack/WrongStack. Use this skill to conduct aggressive, adversarial code reviews on git changes, branches, or PRs to detect critical edge cases, race conditions, security holes, and data loss risks.

When should I use Codex Adversarial Review?

Codex Adversarial Review fits situations like: conduct aggressive; adversarial code reviews on git changes; PRs to detect critical edge cases; race conditions.

How do I install Codex Adversarial Review in Claude Code?

Run `npx skills add WrongStack/WrongStack --skill codex-adversarial-review -a claude-code`. Or copy the skill folder (packages/core/skills/codex-adversarial-review in WrongStack/WrongStack) into .claude/skills/codex-adversarial-review in your project. Claude Code loads it when a task matches its description.

How do I install Codex Adversarial Review in Codex?

Run `npx skills add WrongStack/WrongStack --skill codex-adversarial-review -a codex`. Or copy the skill folder (packages/core/skills/codex-adversarial-review in WrongStack/WrongStack) into .agents/skills/codex-adversarial-review in your project. Codex loads it when a task matches its description.

Can I use Codex Adversarial Review in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add WrongStack/WrongStack --skill codex-adversarial-review -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/codex-adversarial-review, .gemini/skills/codex-adversarial-review, .github/skills/codex-adversarial-review and .opencode/skills/codex-adversarial-review in your project.

What does Codex Adversarial Review need to run?

Going by SKILL.md and its folder, Codex Adversarial Review needs the command-line tools its instructions call (git).

Does Codex Adversarial Review access the network?

SKILL.md contains no URLs. Its commands use git, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Codex Adversarial Review safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Codex Adversarial Review use?

Codex Adversarial Review is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Codex Adversarial Review use?

About 2k tokens (SKILL.md is roughly 7.8k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Codex Adversarial Review?

Skills that share tags, products or a category with Codex Adversarial Review: Code Review Checklist (shareAI-lab/learn-claude-code, 78k stars), Requesting Code Review (HezaoHezao/poirot, 249 stars), Openqodex (openqodex/openqodex, 524 stars) and Code Review with Beads Tasks (maslennikov-ig/claude-code-orchestrator-kit, 260 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Codex Adversarial Review?

WrongStack (a GitHub organization) maintains it in WrongStack/WrongStack, which has 371 GitHub stars. The repository holds 100 skills in this directory. The repository was last updated on October 10, 2026.

Source: WrongStack/WrongStack on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.