Commit Graph

182 Commits (928ac012156fb8d393ce5ac4a496fde3c2e87b00)

Author SHA1 Message Date
Juliana Fajardini 34b7a9ef82 scripts: check doc rules as TD and FW rules
Previously, a rule that had firewall-only syntax or keywords would fail
the script check.

Since we can't guarantee that a firewall rule will look different than a
detection one, run rule examples against both scenarios before failing
them.
3 weeks ago
Juliana Fajardini f3e27b0e41 scripts: check-doc-rules tries local bin first
If the point is to check the docs for added changes, it makes sense to
that used binary is the one that comes with the doc changes. Thus, try
using the local binary first, before falling back to usr/bin installed
Suricata.
3 weeks ago
Jason Ish 6b8c482012 github-ci: break ubuntu/debian script into 2 scripts
Debian 13 ships Rust 1.85 by default, Ubuntu requires installing a
specific patch to get newer then 1.75. So to support a newer MSRV,
these operating systems need different examples.
4 weeks ago
Jason Ish 05882e7be0 github-ci: cleanups to almalinux minimal build
Don't install extra repo's in the script, do it in CI. These are covered
by the documentation as they vary depending on the version and variant.
4 weeks ago
Shivani Bhardwaj 35d28272b2 dcerpc: add interface-service name data
This data directly comes from Zeek @d11a8750. It was scriptually
converted to NDJSON ingestible to Suricata using serde and serde_json.
The script used for this conversion lives in
scripts/extract_dce_rpc_interfaces.py.

Part of this data within Zeek codebase comes from the MITRE BZAR
project. Hence, the LICENSE file alongwith this data consists of both
the licenses: Zeek and BZAR.

Feature 2727
Feature 8523
1 month ago
Philippe Antoine 17dc065326 ci: check uint keywords with their size
So, that if a keyword advertises uint16, it can indeed parse
a uint16 and is not just a uint8
3 months ago
Philippe Antoine 399ee1e360 ci: check multi uint keywords
Ticket: 7929
3 months ago
Philippe Antoine 72e9314402 ci: check cargo fmt for whole suricata 3 months ago
Shivani Bhardwaj 3adb975032 misc: rename requirements.txt to bundle.txt
Do not use Python's standard file name to define external packages that
need to be installed. This confuses Dependabot.
3 months ago
Philippe Antoine ca34fba00c rust: format smb files
Ticket: 3836
3 months ago
Philippe Antoine aea9fd73b7 rust: format dcerpc files
Ticket: 3836
3 months ago
Philippe Antoine e0152178da rust: format detect files
Ticket: 3836
3 months ago
Philippe Antoine 762b725e1f ci: check-doc-rules copies data(sets) files into tmpdir
Allows to use datasets load
3 months ago
Philippe Antoine e39075557a rust: check llmnr format
Ticket: 3836
3 months ago
Philippe Antoine 4144d9c709 rust: format snmp files
Ticket: 3836
3 months ago
Philippe Antoine 9318bbfbdb rust: format tftp files
Ticket: 3836
3 months ago
Philippe Antoine 9ec200e834 rust: format x509 files
Ticket: 3836
3 months ago
Philippe Antoine dd66276f82 rust: format telnet files
Ticket: 3836
3 months ago
Philippe Antoine 709ad1bdf4 rust: format sip files
Ticket: 3836
3 months ago
Philippe Antoine 8217c51126 rust: format sdp files
Ticket: 3836
3 months ago
Philippe Antoine 9d9d8df4cd rust: format rdp files
Ticket: 3836
3 months ago
Philippe Antoine c8a86cdffa ci: move rustfmt to a helper script 3 months ago
Victor Julien 781bd5184e clang-format: support clang 17
Update Github CI runner to use it.

Bump to Ubuntu 24.04 as well.
4 months ago
Philippe Antoine 38d41e6fa6 dnp3: fix off-by-one in array sizes
So that we can write a final zero without overflowing the array
and relying on padding to avoid further problems

Ticket: 8448
4 months ago
Philippe Antoine c25ccd299e dnp3: explicit application layer length is bounded in uint16_t
Ticket: 8460
4 months ago
Philippe Antoine 891b17277e ci: check dist rules
So that we catch if we add a typo like
app-layer-event:snmp.version_mismatchZZZ;
4 months ago
Philippe Antoine d84b6789c9 ci: make doc rules validation strict
not finding anymore problems now
4 months ago
Philippe Antoine cce673349a ci/scripts: check for dots and dashes in json schema keys
Ticket: 6502
4 months ago
Philippe Antoine adc0f18463 doc/ci: check keyword links
Ticket: 8257
4 months ago
Philippe Antoine 64f003190d doc: move more rules to dedicated css container
Ticket: 8372

Also remove dead code from script checking the rules
5 months ago
Philippe Antoine e0d10c0513 scripts: remove dead code in check-doc-rules 5 months ago
Philippe Antoine 42a85c37f1 scripts: add script to check rules in doc
Ticket: 8372

and run it in github CI
5 months ago
Philippe Antoine 512bbe4de8 detect/template: merge template and template2
Ticket: 7278

Do a single packet match template merging best of both current
templates
5 months ago
Jason Ish 551f6ded69 github-ci: update almalinux minimal build to use dist archive
Update the AlmaLinux recommended minimal build to use the pre built
distribution archive as this is the type of build the documentation is
targetting.
6 months ago
Jason Ish 87dba92bdd github-ci: update debian/ubuntu minimal build to use dist
Update the Ubuntu/Debian minimal recommended build to use the
pre-built dist archive instead of building from git, as that is the
type of build this documentation targets.

Also use the ubuntu:22.04 container. The GitHub provided Ubuntu 22.04
VM appears to contain some new additions like a newer Rust that is not
found on a typical Ubuntu 22.04 installation.
6 months ago
Philippe Antoine cf88ed518c jsonschema: check for duplicate keys
Ticket: 6691

And fix the one duplicate found
9 months ago
Philippe Antoine 273e9f55eb scripts: eve-parity hard fail on unknown keyword 10 months ago
Philippe Antoine f581b8f1ae scripts: complete eve-parity type check 10 months ago
Jason Ish 6bd360570a dnp3: fix dnp3 generation script to match code 10 months ago
Jason Ish 2848061d0d scripts/evedoc.py: handle union types in schema
Update EVE documentation script to handle union types like:

    "type": ["string", "number"]
11 months ago
Philippe Antoine f7f8fbc116 scripts: setup app layer rustfmt mod.rs last
Otherwise rustfmt complains that parser.rs does not exist yet
12 months ago
Philippe Antoine 24503b0ead rust: move file functions out of SuricataContext
Ticket: 7667
12 months ago
Victor Julien b58c8461c3 clang-format: adjust for master to main rename 1 year ago
Jason Ish 8d67c91c0d clang-format: don't reformat schema on rewrite-branch
Add --extensions c,h flag to git clang-format when reformatting
commits on a branch. This prevents clang-format from modifying
non-C files like JSON schemas.

The extensions is used elsewhere in this script, so I suspect it was
just an oversight.

Also, ./scripts/schema-order.py --in-place will consistently format the
schema, while sorting the keys.
1 year ago
Philippe Antoine cca169f307 scripts: clang-format can use a different base than master
useful for git hook running on main-7.0.x branches so that
not every commit gets its format checked again.

Ticket: 7292
1 year ago
Jason Ish 371d7cba06 schema: add script to check or sort the schema 1 year ago
Jason Ish e8d7d3d83d scripts/setup-app-layer: fixes for name changes 1 year ago
Jason Ish 7321d7c7db rust/applayertemplate: replace rs_ naming with SC 1 year ago
Philippe Antoine 7d806dc7b7 ci: rustc wrapper to disable coverage for external crates
To keep the disk usage good even when we use new crates
1 year ago
Philippe Antoine c32f2dee70 scripts: remove unused code in setup-app-layer
and fix typo
1 year ago