Suricata Rules Basics
Core building blocks of Suricata signatures and multi-condition DPI logic
Install
npx skills add UCSB-NLP-Chang/Skill-Usage --skill suricata-rules-basicsgit clone --depth 1 https://github.com/UCSB-NLP-Chang/Skill-Usage.git /tmp/Skill-Usage
mkdir -p ~/.claude/skills
cp -r /tmp/Skill-Usage/tasks/suricata-custom-exfil/environment/skills/suricata-rules-basics ~/.claude/skills/suricata-rules-basicsPersonal skills live in ~/.claude/skills. Use .claude/skills in a project folder to share a skill with your team.
From the SKILL.md
# Suricata Rules Basics
This skill covers the core building blocks of Suricata signatures and how to express multi-condition DPI logic.
## Rule anatomy
A typical alert rule looks like:
```
alert <proto> <src> <sport> -> <dst> <dport> (
msg:"...";
flow:...;
content:"..."; <buffer/modifier>;
pcre:"/.../"; <buffer/modifier>;
sid:1000001;
rev:1;
)
```
Key ideas:
- `sid` is a unique rule id.
- `rev` is the rule revision.
- Use `flow:established,to_server` (or similar) to constrain direction/state.
## Content matching
- `content:"...";` matches fixed bytes.
- Add modifiers/buffers (depending on protocol) to scope where the match occurs.
## Regex (PCRE)
Use PCRE when you need patterns like “N hex chars” or “base64-ish payload”:
```
pcre:"/[0-9a-fA-F]{64}/";
```
## Sticky buffers (protocol aware)
For application protocols (e.g., HTTP), prefer protocol-specific buffers so you don’t accidentally match on unrelated bytes in the TCP stream.
Common HTTP sticky buffers include:
- `http.method`
- `http.uri`
- `http.header`
- `http_client_body` (request body)
## Practical tips
- Start with strict conditions (method/path/header), then add body checks.
- Avoid overly generic rules that alert on unrelated traffic.
- Keep rules readable: group related matches and keep `msg` specific.
## Task template: Custom telemetry exfil
For the `suricata-custom-exfil` task, the reliable approach is to compose a rule using HTTP sticky buffers.Details
- Skill name
suricata-rules-basics- Repository
- UCSB-NLP-Chang/Skill-Usage
- Path
tasks/suricata-custom-exfil/environment/skills/suricata-rules-basics/SKILL.md- Repo updated
- 8 April 2026
FAQ
What does the Suricata Rules Basics skill do?
Core building blocks of Suricata signatures and multi-condition DPI logic
How do I install the Suricata Rules Basics skill?
skills CLI (Claude Code, Cursor, Codex and more): npx skills add UCSB-NLP-Chang/Skill-Usage --skill suricata-rules-basics. Skills go in ~/.claude/skills (personal) or .claude/skills (project), and Claude loads them automatically when a task matches the description.
Is Suricata Rules Basics popular?
It lives in UCSB-NLP-Chang/Skill-Usage, which has 49 GitHub stars and 5 forks.
Related skills
Pubchem Database
49UCSB-NLP-Chang/Skill-Usage
Query PubChem via PUG-REST API/PubChemPy (110M+ compounds). Search by name/CID/SMILES, retrieve properties, similarity/substructure searches, bioactivity, for cheminformatics.
Pymatgen
49UCSB-NLP-Chang/Skill-Usage
Materials science toolkit. Crystal structures (CIF, POSCAR), phase diagrams, band structure, DOS, Materials Project integration, format conversion, for computational materials science.
Rdkit
49UCSB-NLP-Chang/Skill-Usage
Cheminformatics toolkit for fine-grained molecular control. SMILES/SDF parsing, descriptors (MW, LogP, TPSA), fingerprints, substructure search, 2D/3D generation, similarity, reactions. For standard workflows with simpler interface, use datamol (wrapper around RDKit). Use rdkit for advanced control, custom sanitization, specialized algorithms.
Syzlang Ioctl Basics
49UCSB-NLP-Chang/Skill-Usage
Syzkaller syzlang syntax basics for describing ioctl syscalls
Suricata Offline Evejson
49UCSB-NLP-Chang/Skill-Usage
Running Suricata against PCAPs offline and validating results via eve.json
Threat Detection
49UCSB-NLP-Chang/Skill-Usage
Exact detection thresholds for identifying malicious network patterns including port scans, DoS attacks, and beaconing behavior.
Browse the most popular Claude skills, all other skills, or write your own with the skills generator.