Skills Explorer Add Skills

yara-rule-authoring

An agent skill by trailofbits, from trailofbits/skills. Tags: malware-detection, rules, security, testing, threat-hunting.

What it does

Guides authoring of high-quality YARA-X detection rules for malware identification. Use when writing, reviewing, or optimizing YARA rules. Covers naming conventions, string selection, performance optimization, migration from legacy YARA, and false positive reduction. Triggers on: YARA, YARA-X, malware detection, threat hunting, IOC, signature, crx module, dex module.

Install

With the skills CLI, which installs into Claude Code, Codex, Cursor and other agents:

npx skills add trailofbits/skills --skill yara-rule-authoring

Or copy the skill folder into Claude Code's skills directory by hand (~/.claude/skills for every project, or .claude/skills inside one):

git clone --depth 1 https://github.com/trailofbits/skills
cp -r skills/plugins/yara-authoring/skills/yara-rule-authoring ~/.claude/skills/yara-rule-authoring

Safety box score

Grade C, moderate risk: 32 of 100 risk points, rated 2026-09-22. The grade rates what the skill and its scripts can reach on the machine of whoever installs it, across eight categories from shell execution to secrets access. How the score works.

This skill is a YARA-X rule-authoring and review guide with two small Python utilities for linting and atom analysis. It is mostly read-only and bounded to YARA files, but it does encourage running an external yarGen checkout, optional remote validation services, and scanning files outside the project tree for goodware testing.

Category levels, from 0 (none) to 3 (high)
CategoryLevelWhy
Code & shell execution2 (moderate)The shipped Python helpers execute `yara_x.Compiler()` over supplied rule files, and the docs explicitly run external code from another checkout with `uv run --no-project --with-requirements requirements.txt python yarGen.py ...`.
Network access2 (moderate)The workflow points users to VirusTotal Intelligence and YARA-CI, and the yarGen invocation can fetch requirements via `uv run --with-requirements`, so this can send data off-box and download dependencies.
Filesystem reach2 (moderate)The testing docs read outside the workspace, including `/System/Library/CoreServices/XProtect.bundle/Contents/Resources/XProtect.yara`, `/usr/bin/`, `/usr/sbin/`, and browser-extension locations.
Secrets & credentials1 (low)The skill mentions sensitive artifacts like `\.ssh/id_rsa`, `.aws/credentials`, `Login Data`, `security find-generic-password`, and `keychain`, but only as YARA signatures to detect, not as data to extract.
Privilege & persistence1 (low)The only setup guidance is package installation such as `brew install yara-x` or `cargo install yara-x`; it does not request sudo, services, or shell/profile edits.
Instruction hijack surface0 (none)There are no instructions to ignore higher-level rules, follow fetched prompts, hide actions, or otherwise manipulate the agent's instruction hierarchy.
Irreversible actions0 (none)The skill is about writing and validating detection rules; it does not push, deploy, post, pay, book, or delete anything on its own.
Transparency0 (none)All shipped files are plain-text Markdown, Python, YAML, and SVG; there are no binaries, obfuscated blobs, or runtime-decoded payloads.

Before installing

Rated 2026-09-22 by an automated review of 15 files from the skill's repository.

Source

Repository
trailofbits/skills (all skills from this repository)
Path
plugins/yara-authoring/skills/yara-rule-authoring/SKILL.md
Branch
main
Collection
yara-authoring
Updated
2026-09-19