Skip to content

Skill

Semgrep Rule Creator

trailofbits

Authors a custom Semgrep static-analysis rule for one specific bug or vulnerability pattern - building the match (or a taint-mode source-to-sink data flow), then the paired vulnerable-and-safe test cases that keep false positives in check. Its output is a reusable detection rule, not a finished audit: it does not run existing Semgrep rulesets over your repo, triage the findings a scan produces, or review a diff by hand.

A situation it fits

At a security audit you discover your app mishandles a proprietary protocol in a way command-line scanners default ignore. You need to codify a narrowly scoped gatekeeper with paired illustrations to avoid noisy CI runs.
Semgrep Rule Creator. The skill is designed for narrowing the focus to exactly one novel weakness in code, teaching how to build a pair of contrasting code snippets and package them into a portable, reusable gatekeeper that plugs into CI. That fits here because the bug is proprietary and off-the-shelf checkers are blind to it, so you need a self-contained, narrowly scoped artifact with paired positive and negative illustrations rather than a supply-chain sweep, a generic error-message rewrite, or an identity breach lookup.

Skills it gets confused with

These share a family with Semgrep Rule Creator, which is another way of saying they are the ones you might reach for by mistake.

Every comparison with Semgrep Rule Creator

Knowing what Semgrep Rule Creator does is the easy half. Telling it apart from the others under time pressure is the game.

Today's session

Semgrep Rule Creator is part of trailofbits/skills. Licence: CC-BY-SA-4.0. The description above was written for this game, not taken from the skill.