# Adversarial code review

> Adversarial code review is an open-source agent skill for security. Adversarial second-pass code review that hunts for disclosure, data integrity. It is available on Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose.

- **Kind:** Skill
- **Pricing:** Open source
- **Platforms:** Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf, Goose
- **Website:** https://github.com/aws-solutions/konductor/tree/main/skills/adversarial-code-review
- **Repository:** https://github.com/aws-solutions/konductor
- **GitHub stars:** 12
- **License:** Apache-2.0
- **Skill name:** adversarial-code-review
- **Collection:** https://github.com/aws-solutions/konductor
- **Categories:** [security](https://ai-powered.com/categories/security), [developer tools](https://ai-powered.com/categories/developer-tools)
- **Listing updated:** 2026-12-04

## About

This skill tells the agent to review a code change as a skeptical security architect whose job is to argue against approval. It concentrates on three areas that ordinary review tends to miss: information disclosure, data integrity failures, and schema or validation completeness. Every finding it reports is meant to justify blocking or conditioning the change.

The skill runs in one of two modes that must not be mixed. In generator mode the agent reads the diff and proposes findings through each lens, accepting that some will be noisy. In validator mode the agent acts only as a filter, returning KEEP or REJECT for each proposed finding and rejecting anything that cannot be traced to visible code, is vague, or is a style nit. Findings are graded CRITICAL, IMPORTANT or SUGGESTION against a fixed list, with a CRITICAL finding blocking approval.

The skill expects a code diff and the file paths it touches. It refers to companion pass skills and an orchestrator for a fuller multi-pass review, which are separate components of the konductor project and are not included in this file.

## When your agent uses it

> Targets the three gap categories standard review misses: information disclosure, data integrity, and schema validation. Use for a second pass after code review, as the checker in a maker-checker cycle, or before submitting a change to auth, data writes or external APIs.

## What it can access

From a static check of the files on GitHub; nothing was run.

- [Instructions only, no scripts](https://github.com/aws-solutions/konductor/tree/HEAD/skills/adversarial-code-review)
- [License: Apache-2.0](https://github.com/aws-solutions/konductor/tree/HEAD/skills/adversarial-code-review)

## Features

- **Disclosure lens:** Checks whether stack traces, internal IDs or raw errors reach callers, and whether payloads or tokens are logged.
- **Data integrity checks:** Looks for non-atomic multi-item writes, unconditional overwrites and missing condition checks.
- **Schema and validation review:** Flags breaking contract changes, missing defaults and validation that runs after side effects.
- **Validator filter mode:** Reviews candidate findings and keeps or rejects each one against strict rules to cut false positives.
- **Severity rating:** Grades every finding as CRITICAL, IMPORTANT or SUGGESTION using a fixed list of cases.
- **Structured output format:** Presents each finding with severity, category, file location, problem and fix.

## Good for

- Do a second-pass review of a pull request before merging
- Check a change to authentication code for information leaks
- Review a write path for atomicity and overwrite risks
- Verify that new API fields are validated and defaulted
- Filter a list of proposed review comments before posting them

## Install

### Claude Code

This skill ships in the `konductor` plugin. In Claude Code, add the marketplace and install the plugin (it may include other skills too):

```sh
/plugin marketplace add aws-solutions/konductor
/plugin install konductor@konductor
```

Or copy only this skill to `~/.claude/skills/adversarial-code-review`:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/aws-solutions/konductor.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/adversarial-code-review &&
cp -R "$tmp/skills/adversarial-code-review" ~/.claude/skills/adversarial-code-review &&
rm -rf "$tmp"
```

For one project only, put the folder in `.claude/skills/adversarial-code-review` inside it instead.

### Codex

Copy the skill folder to `~/.agents/skills/adversarial-code-review` to use it in every repository:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/aws-solutions/konductor.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/adversarial-code-review &&
cp -R "$tmp/skills/adversarial-code-review" ~/.agents/skills/adversarial-code-review &&
rm -rf "$tmp"
```

For one repository only, put the folder in `.agents/skills/adversarial-code-review` inside it instead.

### Cursor

Copy the skill folder to `~/.cursor/skills/adversarial-code-review` to use it in every project:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/aws-solutions/konductor.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/adversarial-code-review &&
cp -R "$tmp/skills/adversarial-code-review" ~/.cursor/skills/adversarial-code-review &&
rm -rf "$tmp"
```

For one project only, put the folder in `.cursor/skills/adversarial-code-review` inside it instead.

### Gemini CLI

Run in a terminal (add `--scope workspace` to install it for the current workspace only):

```sh
gemini skills install https://github.com/aws-solutions/konductor.git --path skills/adversarial-code-review
```

Or copy the folder to `~/.gemini/skills/adversarial-code-review` yourself.

### VS Code

For GitHub Copilot in VS Code, copy the skill folder to `~/.copilot/skills/adversarial-code-review`:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/aws-solutions/konductor.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/adversarial-code-review &&
cp -R "$tmp/skills/adversarial-code-review" ~/.copilot/skills/adversarial-code-review &&
rm -rf "$tmp"
```

For one project only, put the folder in `.github/skills/adversarial-code-review` inside it instead.

### Other agents

Get the folder:

```sh
git clone --depth 1 https://github.com/aws-solutions/konductor.git
```

Then copy `konductor/skills/adversarial-code-review` into your agent's skills folder as `adversarial-code-review`. Agents that support SKILL.md read one folder per skill.

## FAQ

### When should Adversarial code review be used?

For a second pass after standard code review, as the checker in a maker-checker cycle, or before submitting changes to auth, data writes or external APIs.

### Does Adversarial code review run the full adversarial review by itself?

No. The full multi-pass review is coordinated by the konductor orchestrator, and this skill is asked to direct that request to konductor instead of running the passes itself.

### What does validator mode do?

It only returns KEEP or REJECT for each proposed finding and never proposes new findings or offers fixes.

### How are findings rated?

CRITICAL findings block approval, IMPORTANT findings should be fixed before merge, and SUGGESTION items are optional.

### How do I install Adversarial code review in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/adversarial-code-review to use it in all your projects, or to .claude/skills/adversarial-code-review in one project. Or install the konductor plugin, which includes it: /plugin marketplace add aws-solutions/konductor, then /plugin install konductor@konductor.

### Does Adversarial code review run scripts?

No. It is instructions only, with no scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

### Which AI agents can use Adversarial code review?

Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose. Each reads skills in the SKILL.md format from its own folder; the install steps on this page list them.

### What are the best alternatives to Adversarial code review?

The closest alternatives to Adversarial code review are Adversarial code review pass security, Adversarial code review pass schema, Adversarial code review pass integrity, Differential review and Code review loop.

## Where this comes from

- Description: from the skill's own SKILL.md.

## Alternatives

- [Adversarial code review pass security](https://ai-powered.com/skills/adversarial-code-review-pass-security): Adversarial code review pass security is an open-source agent skill for security.
- [Adversarial code review pass schema](https://ai-powered.com/skills/adversarial-code-review-pass-schema): Adversarial code review pass schema is an open-source agent skill for developer tools.
- [Adversarial code review pass integrity](https://ai-powered.com/skills/adversarial-code-review-pass-integrity): Adversarial code review pass integrity is an open-source agent skill for developer tools.
- [Differential review](https://ai-powered.com/skills/differential-review): Differential review is an open-source agent skill for security.
- [Code review loop](https://ai-powered.com/skills/code-review-loop): Code review loop is an open-source agent skill for developer tools.
- [Code review expert](https://ai-powered.com/skills/code-review-expert): Code review expert is an open-source agent skill for developer tools.
- [Code review and quality](https://ai-powered.com/skills/code-review-and-quality): Code review and quality is an open-source agent skill for developer tools.
- [Security review](https://ai-powered.com/skills/security-review-getsentry): Security review is an open-source agent skill for security.

---
Source: https://ai-powered.com/skills/adversarial-code-review
