Plugins and integrationsReviewed · Trail of Bits

Insecure Defaults Detection (Claude Code plugin)

A Claude Code plugin from Trail of Bits that uses AI agents to audit a file, folder or repo for insecure default settings, aimed at developers and security reviewers who use Claude Code; its main catch is that the source itself says its prompts still need a live run on a real model. Six pattern sweeps collect candidates, and Opus verifiers try to refute each one before it is reported.

Researched 12 Nov 2026

In short.

Insecure Defaults Detection is a Claude Code plugin from Trail of Bits that uses AI agents to audit code for insecure default settings, aimed at developers and security reviewers who already use Claude Code; its main catch is that every verdict depends on a live language model, and the captured evidence contains no run, sample output or accuracy figures. Technically, the /insecure-defaults:audit command runs one Sonnet recon agent, six Sonnet pattern sweeps (one per category: fallback secrets, default credentials, fail-open switches, weak crypto, permissive access and debug leakage), Opus verifiers batched by category with at most 16 findings each, and a Sonnet report agent. Each verifier starts from refuted and must trace a candidate to a security decision before it survives. The source ships offline tests for the workflow scaffolding, but their results are not in the evidence, and verdict quality, per-run cost and behaviour on any given model are unknown.

Researched and written by an AI model and checked by a second AI model. How it works

Source scope is the plugin folder plugins/insecure-defaults at revision e4dd0bb5b15535f7c5a0834187dffba6ac37e4ff: 20 captured files covering the manifest, the audit command, the README, the workflow script, six category pairs and four test files. The repository-root LICENSE is included as a related notice outside that folder. Linked pages and other folders in the trailofbits/skills repository are excluded, so other plugins are not described. Untested behaviour: nothing in the captured evidence shows the audit, the verifiers, the report or the offline tests being run, and no sample output is captured. Model behaviour, verdict accuracy, cost, timing and data handling are not assessed. No distribution file is proposed with this analysis.

The overview

identity

Insecure Defaults Detection is a Claude Code plugin named insecure-defaults, version 2.0.3, published by Trail of Bits in the trailofbits/skills repository under plugins/insecure-defaults. Its manifest gives the name, the version, a one-line description (Detects insecure default configurations including hardcoded credentials, fallback secrets, weak authentication defaults, and dangerous values in production) and the author. The manifest has no licence field.

The captured source is pinned to revision e4dd0bb5b15535f7c5a0834187dffba6ac37e4ff and was captured on 2026-11-12. It is invoked as the slash command /insecure-defaults:audit. It is a software tool and workflow for code review, not a model, a dataset or hardware. The evidence does not name the marketplace that the README's install command refers to, and it does not say who maintains the plugin day to day.

assessment

The plugin is a substantive, structured tool for one narrow job: finding configuration-level security defaults, such as a secret that falls back to a literal, a seeded admin account, a feature flag that is on by default, or a public ACL. Its design aims to limit false positives. Pattern sweeps only collect candidates, and a separate verifier must trace each one to a security decision and refutes it by default. The README points users to Semgrep or a linter when a fixed pattern is enough, and to gitleaks or trufflehog for committed secrets, so it presents itself as a complement to those tools rather than a replacement.

The engineering around the prompts is detailed: six categories, each with a seed-pattern file and a worked vulnerable/secure corpus; a four-phase workflow; abort statuses for unreadable corpora and failed searches; and an offline test suite with mutation self-tests. Those checks cover the workflow's logic, its batching and dedup, its prompt wording and the correspondence between category files. They do not establish whether a real model reaches correct verdicts. The captured evidence has no test output, no sample audit report, no false-positive or recall figures and no timing or cost data, so the quality of its findings is not assessed.

Overall fit: a credible option for a team that already uses Claude Code and wants a second review of configuration defaults. Confidence in its negative results should stay limited until someone has run it on code with known defaults.

users

The intended users are developers and security reviewers who use Claude Code and want an AI-assisted review of a codebase for insecure defaults. The README is written for people who install plugins with /plugin install and run a slash command. The captured evidence describes an interactive command, not a non-interactive or CI mode for the audit itself.

For beginners, the output is a list of candidate issues that an AI agent has traced, not a guaranteed list of defects. A finding means the code matches the category's rule under the trace shown. A run that reports no findings can end in one of two ways. A no-candidates result means the sweeps that searched produced no candidates; the workflow's own note calls this an absence of pattern matches, not proof of absence. A no-findings-confirmed result means candidates were found and adjudicated but none was confirmed; it can include candidates recorded as refuted only because a trace was incomplete, as well as unresolved coverage gaps such as unverified candidates or categories that scanned no files. Neither result establishes that the code has no vulnerabilities. Beginners should read the coverage details before trusting any result.

For experienced developers, the seed patterns and the six corpora are plain text that can be read and edited. The README requires the three files for each category to agree, and the test suite checks that. The sweeps are already asked to derive extra patterns for the detected stack. The worked examples cover Python, JavaScript, Java and Ruby; how the tool performs on other languages is unknown.

capabilities

Each category targets a different kind of default. Fallback secrets: a default value used when an environment variable is missing, where that value feeds signing, encryption, session or token code. Default credentials: a credential literal that a running deployment can authenticate with, including accounts seeded on first boot. Fail-open switches: a configuration default that disables a security control. Weak crypto: a broken or non-cryptographic primitive standing in for one used for password hashing, token generation, encryption or signature checks. Permissive access: public ACLs, world-writable file modes such as 0o666, and CORS origins set to '*'. Debug leakage: stack traces, verbose errors or introspection left on in responses, listening ports or logs that a lower-privileged party can read.

The target can be a whole repository, a folder or a single file, passed as an optional argument that defaults to the current directory. Findings are graded CRITICAL to LOW. Each finding carries its location, the offending line, a verification trace that cites the sink, a production-impact note and an exploitation note. Remediation is grouped by fix rather than by finding. The report also includes a table of refuted candidates with the step that refuted each one, so a reviewer can see why a match was dropped.

The workflow separates two kinds of candidate. A configurable candidate is a lookup with a fallback, and it matters only if the app actually runs with that fallback. An unconditional candidate has no configuration involved, such as a hardcoded admin password or an md5 call over a password. The README says that about half of all findings are unconditional. For configurable candidates, the verifier also reads the deploy manifests (Dockerfile, compose files, Kubernetes, Helm, Terraform, CI workflows, systemd units, Procfile) to decide whether production always sets the variable. That changes severity; it does not clear the finding.

Using it

requirements

The host must be Claude Code with plugin installation and slash-command support. The command's allowed tools are Bash and Workflow, so the host must provide a Workflow capability that can run the audit-pipeline script. That script relies on runtime-supplied globals (agent, parallel, phase, log, args) and uses top-level await and return, so it needs a host that provides them. The evidence does not state a minimum Claude Code version or the account and billing setup needed.

The audit names two model tiers: Sonnet for recon, sweeps and the report, and Opus for verification. The captured files name those tiers but not the exact model identifiers used at run time, and they do not say what access the host needs to use them. The plugin folder must be complete: the command checks that the references folder lists category files, and the workflow aborts with corpus-unreadable if any category file cannot be read.

The offline tests need node and grep, and the wrapper script needs bash with strict error handling. The tests spawn no agents and touch no network. Windows support is not established by the evidence.

mechanism

Recon, run by one Sonnet agent, first confirms the target exists and then profiles it: languages, frameworks and their settings paths, the project's own configuration accessors (the recon prompt says a local get_config wrapper matters more than raw os.environ), deploy manifests, and exclusion paths such as tests and fixtures. The prompt forbids excluding the named target itself. If the path is missing, the run stops with scope-missing rather than reporting a clean result.

Discover runs six Sonnet sweeps in parallel, one per category. Each sweep reads its category's seed file and its worked-example corpus, writes extra patterns for the detected stack, runs them as grep-style searches and reports candidates without judging them. It also reports whether it could read its corpus and how many files it scanned. A sweep that cannot read its corpus aborts the whole run, and zero files scanned is treated as a failed search. Candidates are deduplicated on category, file and line, so one line flagged by two categories stays as two candidates, each judged against its own rule.

Verify runs Opus agents batched by category, with at most 16 findings each; directories are kept together where they fit. Each verifier starts from refuted true and works through five ordered steps, stopping at the first that refutes: (1) is the file reachable in production; (2) is the insecure value the one that runs, which for a configurable candidate means checking whether a missing variable stops the process; (3) is the value actually insecure; (4) does it reach a security decision, cited as file and line; (5) does deployment always supply the variable, which only changes severity. An unconditional candidate cannot be refuted at step 2 for lacking configuration. An incomplete trace is recorded as refuted, and verifiers are told not to hunt for new candidates.

Report is one Sonnet agent that writes markdown from the confirmed findings, the refuted list and the coverage record. The coverage record names categories that scanned no files, candidates that no verifier judged, failed verify batches and categories that ran only generic seeds. If every candidate went unjudged, the run stops with verify-failed rather than reporting the target as clean.

setup

Install from a marketplace with /plugin install insecure-defaults, or from a local checkout with /plugin install ./plugins/insecure-defaults. The README does not name the marketplace it expects.

Run /insecure-defaults:audit for the whole repository, /insecure-defaults:audit src/ for a folder, or /insecure-defaults:audit src/config/app.py for one file. The argument is optional and defaults to the current directory. Do not call insecure-defaults:audit-pipeline directly: the README says it stops immediately, because it needs the command to supply the plugin path and scope.

Optional offline checks, run from the plugin folder: node tests/harness.js workflows/audit.js, the same command with --self-test, and node tests/seed-coverage.js. The wrapper bash tests/run_seeds.sh runs all three and fails if node is missing. None of these spawns agents or touches the network. The captured evidence does not show their results.

example

Fallback secrets, from the corpus: in Python, SECRET_KEY = os.environ.get('SECRET_KEY', 'dev-secret-key-123') feeding jwt.encode is classed as vulnerable, because the app runs with a known signing key if the variable is missing. The secure form, SECRET_KEY = os.environ['SECRET_KEY'], is classed as secure because it raises at startup when the variable is absent. For the first line, a verifier would treat the candidate as configurable: the literal runs, so the trace continues to the jwt.encode sink, and the deploy manifests decide the severity.

Fail-open switch: REQUIRE_AUTH = os.getenv('REQUIRE_AUTH', 'false').lower() == 'true', followed by a before-request check that returns early and skips authentication when REQUIRE_AUTH is false, is vulnerable. When the variable is unset, the comparison evaluates to False, so the unconfigured state is no authentication. The secure counterpart keeps the same Boolean conversion but defaults to 'true': REQUIRE_AUTH = os.getenv('REQUIRE_AUTH', 'true').lower() == 'true'. The corpus also shows REQUIRE_AUTH = os.environ['REQUIRE_AUTH'].lower() == 'true', which crashes if the variable is not configured. Default credentials: a bootstrap_admin function that creates an admin account with the password admin123 on first run is vulnerable, while reading ADMIN_USERNAME and ADMIN_PASSWORD from the environment is the secure pattern. These are the corpus's own worked pairs.

No sample audit report or real run output is in the captured evidence. These examples show the rule each category applies; they are not results from a run on any codebase.

Assessment & evidence

limitations

Nothing in the captured evidence shows the audit being run. The README says that whether the prompts work on a real model needs a live run, and the test README says that only a live run tells you whether the prompts elicit good behaviour. Verdict quality, false-positive rate and recall are not assessed.

Pattern coverage is partial by design. Seed patterns are described as a floor, and the derived patterns are written by the model for each stack, so coverage depends on that step. The report records how many patterns ran and which sweeps derived none. A no-candidates result means the searches produced no candidates; the workflow's note calls this an absence of pattern matches, not proof of absence. A no-findings-confirmed result means candidates were adjudicated without any being confirmed. It can include incomplete traces recorded as refuted, as well as unresolved coverage gaps such as unverified candidates, failed verify batches or categories that scanned no files. Neither result establishes that vulnerabilities are absent.

Scope is narrow. There are six categories, and none covers dependency vulnerabilities, injection flaws or general logic bugs. The README directs extensive secret detection to gitleaks or trufflehog. The verifier defaults to refuted, and an incomplete trace is also recorded as refuted, so a real issue can be dropped. The refuted table lets a reviewer check those decisions, but the evidence contains no measurement of how often this happens.

Language and framework coverage is uneven in the evidence. The worked examples cover Python, JavaScript, Java and Ruby. The Ruby example in the fallback-secrets corpus is a Rails case: Rails.application.credentials.secret_key_base set from ENV.fetch('SECRET_KEY_BASE', 'fallback-secret-base'). The recon prompt names Django, Rails, Spring and Express settings, and it mentions Go flag setup in main.go. The sweep prompt suggests Go-style shapes such as flag.String, but no worked corpus example is in Go. How well the audit performs on any language or framework is not measured, and coverage of languages without worked examples is not established.

The command is granted Bash, and the audit reads source files and passes candidate snippets to model agents. The captured evidence does not describe what data leaves the machine, where model calls go or how long they are retained. Those points are unknown.

reasoning

The design separates cheap collection from expensive judgment. Sweeps are broad and do not judge. Verifiers see the whole file and must cite a sink before confirming a finding, and only the verifiers use the higher model tier. Refute-by-default and the five-step ladder are meant to cut false positives. The configurable/unconditional split keeps config-free defects from being dropped by a check that assumes a fallback exists. The authors also chose to abort rather than guess when a corpus is missing or a whole verify phase fails.

The source is open about its own past faults. Its test README reports that 8 of 18 documented examples once matched no seed in any category. The seed-coverage check is designed to catch that kind of silent drift by requiring every documented vulnerable example to match a seed. The harness defines mutation self-tests that alter the workflow source in memory, check that the scenarios then fail, and treat a mutation that no longer applies as a failure. These are sound engineering habits and the most concrete quality signals in the captured files. The test source and documentation, however, establish what the checks are meant to do, not that they pass: no execution results are captured.

What the reasoning cannot show is whether the design works on real code. The offline tests are designed to check the workflow's argument handling, batching, dedup and abort paths, some prompt wording, and whether each corpus's vulnerable examples are matched by seeds. No results from running them are in the evidence. Even when they pass, they are not designed to show whether the verifiers reach correct verdicts or whether derived patterns find real defects; the test README says only a live run tells you that. The design is plausible and carefully guarded, but its results are not measured in the evidence.

alternatives

The README names two alternatives for narrower jobs. Semgrep or a linter fits better when the rule is a fixed pattern with no reachability question. gitleaks or trufflehog fits better for extensive secret detection in committed code. The plugin positions itself for a different question: whether a default the code falls back to is reachable and matters in a deployment.

The corpora are plain markdown and JSON, so a team could use them as a manual review checklist without installing the plugin. The captured evidence does not compare this plugin with other AI-based review tools, so its advantage over them is not assessed.

evidence

The captured evidence holds 21 files at revision e4dd0bb5b15535f7c5a0834187dffba6ac37e4ff: the plugin manifest, the audit command, the README, the workflow script, six category pairs (a JSON seed file and a markdown corpus each), four test files, and the root LICENSE as a notice outside the plugin folder. All of it is source text.

The evidence contains no run record, sample output, benchmark, changelog, issue data, release notes, commit dates or continuous-integration results. Statements about how the plugin behaves come from its own descriptions and code, which is as far as the captured files can go.

Access & freshness

costs

Cost is unknown. The captured evidence gives no price, token count, run time or per-run estimate, and it does not say how model usage is billed by the host. The workflow source does not read the runtime's budget value, so no spending cap is set in the captured code.

The number of model calls depends on how far a run gets. If the plugin root is not supplied, the pipeline stops before any agent is started. One Sonnet recon agent runs first, and the run stops there if recon returns nothing or the target does not exist. After successful recon, six Sonnet sweeps run in parallel. A corpus-unreadable or search-failed result stops the run after the sweeps. If the sweeps produce no candidates (no-candidates), verification and reporting are skipped. If they produce candidates, Opus verifiers run, batched by category: at least one per category that produced a candidate, and more where a category has more than 16. If at least one candidate is adjudicated, one Sonnet report agent follows; if none is, the run stops with verify-failed before the report. Verification is the only phase on the higher model tier, but the evidence does not measure how much of a run's cost it accounts for.

rights

The repository-root LICENSE is Creative Commons Attribution-ShareAlike 4.0 International. It was captured as a notice outside the plugin folder. The plugin manifest has no licence field, and the captured plugin files contain no separate licence text, so the root licence is the only rights statement in the evidence. Nothing in the captured files excludes the plugin's scripts, tests or corpora from it.

The licence grants a worldwide, royalty-free, non-sublicensable, non-exclusive, irrevocable licence to reproduce and share the material, and to produce, reproduce and share adapted material. Its conditions attach to sharing. Attribution applies when you share the licensed material, including in modified form. You must retain the creator identification, copyright notice, notices referring to the licence and to the disclaimer of warranties, and a link to the material where reasonably practicable, if the licensor supplied them. You must also indicate whether you modified it, and indicate that it is under this licence, with the licence text or a link to it. ShareAlike also applies when you share adapted material you produce. The adapter's licence you apply must be a Creative Commons licence with the same Attribution and ShareAlike elements, version 4.0 or later, or a BY-SA Compatible License, and you may not add terms or technical measures that restrict the rights it grants. Modifying the material privately, without sharing it, does not trigger these sharing conditions.

The licence does not permit implying endorsement by the licensor, does not license patent or trademark rights, and disclaims warranties.

freshness

The captured files were taken on 2026-11-12 at 05:41 UTC from the pinned revision e4dd0bb5b15535f7c5a0834187dffba6ac37e4ff, and the manifest version is 2.0.3. The snapshot reflects that revision only. It says nothing about later changes upstream, and the captured files carry no commit or release dates.

Whether the plugin is actively maintained is not established. The test README cross-references an issue number and a Makefile note, but their current status is not captured. Freshness of the upstream repository is unknown.

actions

If you are new to this, install it in a scratch repository first, run it on one file, and read the coverage section before anything else. Treat any line under Not searched or Not verified as a gap in the audit, not as a clean result. Do not treat a no-candidates or no-findings-confirmed result as proof that a codebase is safe.

If you are an experienced developer, pin the plugin to the revision you reviewed and run the offline suites locally before use. Then run a live audit on a repository with known, planted defaults, and compare the verdicts with what you planted before trusting negative results. Check the Bash permission and your data-handling rules for sending code to a model, and measure the cost of an Opus verification pass on your own code, because the evidence gives no figures.

Run the audit alongside the tools the README names: a fixed-pattern linter for rules without a reachability question, and gitleaks or trufflehog for committed secrets. If you share the plugin, in original or modified form, follow the root licence's attribution conditions. If you share an adapted version, also license the adaptation under a Creative Commons licence with the same Attribution and ShareAlike elements, version 4.0 or later, or a BY-SA Compatible License. Modifying it privately, without sharing, does not trigger these conditions.

Evidence for this report

LICENSEnotice · checked 2026-11-12
plugins/insecure-defaults/README.mdselected · checked 2026-11-12
plugins/insecure-defaults/commands/audit.mdselected · checked 2026-11-12
plugins/insecure-defaults/tests/README.mdselected · checked 2026-11-12
plugins/insecure-defaults/tests/harness.jsselected · checked 2026-11-12
plugins/insecure-defaults/tests/run_seeds.shselected · checked 2026-11-12
plugins/insecure-defaults/workflows/audit.jsselected · checked 2026-11-12