custom-signatures
Create and deploy custom IOCs, YARA rules, Sigma rules, and STIX indicators for THOR scans.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Create and deploy custom IOCs, YARA rules, Sigma rules, and STIX indicators for THOR scans.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Entry point and router for THOR-related work: running scans, analyzing THOR logs, troubleshooting THOR behavior, maintaining THOR installs, THOR Lens workflows, writing THOR plugins (v11+), and creating custom signatures/IOCs.
Run THOR scans and propose the exact command line for Windows, Linux, or macOS. Use when the user wants to scan a host, a directory, a mounted image, or a memory dump with THOR v10/v11.
Write, package, and use THOR plugins to extend scanner functionality. THOR v11+ only.
Troubleshoot THOR runs that are stuck, slow, failing to start, stopping early, or produce missing output. Use when the user reports freezes, long runtimes, high CPU pauses, scan aborts, or licensing/update issues.
THOR Lens workflows for forensic timeline analysis. A web UI that imports THOR v11 audit trail JSONL logs for interactive exploration. Requires THOR v11 (audit trail not available in v10).
Interpret THOR scan results and explain what findings mean. Use when the user pastes THOR log lines, shares a log file, or asks how to triage Notices/Warnings/Alerts.
| name | custom-signatures |
| description | Create and deploy custom IOCs, YARA rules, Sigma rules, and STIX indicators for THOR scans. |
Goal: Help users create, format, and deploy custom detection content for THOR.
THOR processes all files in the ./custom-signatures folder. The file extension and filename tags determine how each file is interpreted:
| Extension | Type | Description |
|---|---|---|
.txt | Simple IOCs | CSV-style IOC files (hashes, filenames, C2s, etc.) |
.dat | Encrypted IOCs | Encrypted simple IOCs (via thor-util) |
.yar | YARA rules | Plain text YARA rules |
.yas | Encrypted YARA | Encrypted YARA rules |
.yml | Sigma rules | Log detection rules |
.yms | Encrypted Sigma | Encrypted Sigma rules |
.json | STIX v2 | STIXv2 JSON indicators |
.jsos | Encrypted STIX | Encrypted STIX indicators |
Filename tags determine IOC type. Tag is detected via regex \Wc2\W (word boundary match).
| Tag in Filename | Purpose | Example Filename |
|---|---|---|
c2 or domains | IPs, hostnames, CIDR ranges | case22-c2-iocs.txt |
filename or filenames | Regex-based path/name IOCs | apt-filename-iocs.txt |
hash or hashes | MD5, SHA1, SHA256, Imphash | misp-hashes.txt |
keyword or keywords | String-based keywords | incident-keywords.txt |
trusted-hash | Whitelist hashes (reduce score) | my-trusted-hashes.txt |
handles | Mutex/Event values | malware-handles.txt |
pipes | Named pipes | c2-pipes.txt |
Critical: The filename determines how THOR initializes the rule. See YARA Rules Reference for full details.
| Filename Contains | Rule Type | Applied To |
|---|---|---|
(none), process | Generic rules | Files, process memory, DeepDive chunks |
meta | Meta rules | All files (first 64KB + externals) |
keyword | Keyword rules | THOR module output (tasks, services, etc.) |
registry | Registry rules | Registry keys/values |
log | Log rules | Log lines, event log entries |
Common mistake: Using limit = "ScheduledTasks" without keyword in the filename. This causes the rule to be initialized as a generic rule (file/memory scanner), which won't match module output like scheduled task names.
Applied to Windows Eventlogs and log files. By default only high and critical levels shown.
Supports file observables (name, path, hashes, size, timestamps) and registry key observables.
meta:
score = 80 // Default is 75 if not specified
Available in generic and meta YARA rules:
| Variable | Description | Example |
|---|---|---|
filename | File name only | cmd.exe |
filepath | Path without filename | C:\temp |
extension | Extension with dot, lowercase | .exe |
filetype | Magic header type | EXE, ZIP, PDF |
filesize | Size in bytes | (YARA built-in) |
owner | File owner | NT-AUTHORITY\SYSTEM |
filemode | POSIX-style file mode | |
unpack_parent | Immediate container | ZIP |
unpack_source | Full unpack chain | EMAIL>ZIP |
meta:
type = "memory" // or "file" - restrict to memory/file only
limit = "Mutex" // Restrict to specific module
nodeepdive = 1 // Exclude from DeepDive
falsepositive = 1 // Reduce score instead of add
# Good - tag detected
case22-c2-domains.txt ✓ (c2 tag)
misp-export-hashes.txt ✓ (hashes tag)
incident-filename-iocs.txt ✓ (filename tag)
# Bad - tag not detected
myc2iocs.txt ✗ (no word boundary)
filenameiocs.txt ✗ (no word boundary)
# Place files in custom-signatures folder
cp my-hashes.txt /path/to/thor/custom-signatures/
# For YARA rules, use yara subfolder
cp my-rules.yar /path/to/thor/custom-signatures/yara/
# Encrypt sensitive IOCs (optional)
thor-util encrypt --file my-c2-domains.txt
# Creates my-c2-domains.dat
# Run with custom signatures only
./thor-macosx --customonly -p /target/path
# Verify IOC loading in startup
./thor-macosx 2>&1 | grep -i "custom\|ioc\|signature"