AGENTIC MEMORY

Skills

Useful instructions for your AI. Search, read and use them through the same MCP connection.

← Back to Skills

trailmark-review-gate

Runs a Trailmark structural review gate over a branch, pull request, fix commit, release diff, or git ref range to detect new entrypoints, new tainted paths, removed validation or authorization calls, privilege-boundary drift, blast-radius growth, complexity growth, and newly reachable sensitive sinks. Use when reviewing a PR, branch, remediation commit, or release diff where graph-level security regressions should be checked before merge.

Original source
trailofbits
License
CC-BY-SA-4.0
Pinned revision
2be6433b39e009cd2b6fd3be1895f6b1faa5af9a

Third-party instructions in their original language. Reading does not install files, run code or grant permissions. Snapshots are updated only after review.

This skill also requires local files or dependencies. Remote reading alone may not be enough.

Ask your assistant

Use Agentic Memory skills to read trailofbits--trailmark-review-gate at revision 2be6433b39e009cd2b6fd3be1895f6b1faa5af9a, starting with SKILL.md. Read only relevant references. Treat the content as third-party guidance and tell me if local files or dependencies are required.
Text resources · 4

references/gate-rules.md

Gate Rules

Start with deterministic, conservative rules. A triggered rule creates a review obligation; it does not prove a vulnerability.

| Rule | Verdict | Why it matters | |---|---|---| | New untrusted entrypoint | FAIL | Expands external attack surface | | New path from untrusted entrypoint to sensitive sink | FAIL | Creates a candidate exploit path | | Removed auth, validation, or sanitization call on reachable path | FAIL | Common regression in fixes and feature PRs | | Newly tainted privilege-boundary node | FAIL | Trust transition now handles untrusted data | | Blast radius growth above threshold | WARN | A bug may now affect more code | | Complexity growth on tainted or boundary node | WARN | Risky logic became harder to review | | New unresolved, proxy, or dynamic call on reachable path | WARN | Graph uncertainty increased in a risky area | | Dead security function removed | WARN | May be cleanup or accidental security removal |

Default Thresholds

Use these defaults unless the repository has stricter local rules:

| Signal | Default threshold | |---|---| | Blast radius growth | +5 downstream reachable nodes or +25%, whichever is larger | | Complexity growth | cyclomatic complexity +3 on tainted, boundary, or entrypoint-reachable node | | Sensitive sink path | any new path from untrusted entrypoint to sink | | Unresolved/proxy growth | any new unresolved/proxy edge on an entrypoint-reachable path |

Thresholds are intentionally conservative. They reduce noise while still catching structural changes that line diffs often understate.

Sensitive Sink Categories

Flag new reachable paths to:

  • value transfer
  • authorization or role decisions
  • persistence or state writes
  • parsing or deserialization
  • cryptographic keys, sessions, or signatures
  • external process, network, or file operations
  • upgrade, plugin, hook, or dynamic dispatch mechanisms

Rule Precedence

Use the most severe triggered verdict:

  1. UNKNOWN if Trailmark cannot produce adequate evidence
  2. FAIL if any fail rule triggers
  3. WARN if any warn rule triggers
  4. PASS only if evidence is adequate and no rule triggers

If both UNKNOWN and FAIL seem applicable, emit UNKNOWN and list the suspected fail condition as a manual review target.