Jason Ish
0321f60ebf
community-id: use Rust SHA1 to compute hash
...
Removes use of our internal ComputeSHA1 for calculating the
community ID.
4 years ago
Jason Ish
eb5cfd9b82
rust/hashing: new function to SHA1 hash a single buffer
...
SCSha1HashBuffer will has a single buffer and compute the digest
in one call.
4 years ago
Jason Ish
ff37526c6b
rust: remove md5 crate, unalias md-5
...
Remove the md5 crate as a dependency as it is no longer removed.
We now use md-5 from RustCrypto.
4 years ago
Jason Ish
0a2d8509c9
rust/ssh: use md-5 crate instead of md5
...
The "md-5" crate is part of the RustCrypto project that also
uses the sha1 and sha256 crates we are using. These all implement
the Digest trait for a common API.
4 years ago
Jason Ish
c0ddad8e7e
doc/ja3: libnss support no longer required
4 years ago
Jason Ish
d5bf748c90
ja3: remove requirement on NSS
4 years ago
Jason Ish
1022b217ed
rust/hashing: a method to md5 hash a single buffer
...
Add SCMd5HashBuffer as a replacement for NSS HASH_HashBuf as
used in ja3 to hash a single buffer.
4 years ago
Jason Ish
e50ee7eb62
filestore: remove requirement of nss for filestore
...
Required including NSS header in places that depended on
util-file.h including it.
All filestore suricata-verify tests now pass without libnss.
Also enabled detect-file{md5,sha1,sha256} without NSS support.
4 years ago
Jason Ish
e4acbcbb5e
filestore: use Rust bindings for sha256/sha1/md5
4 years ago
Jason Ish
46ceb13c08
rust: add ffi module for sha256, sha1 and md5
...
Add a Rust module that exposes Rust implementations of
sha256, sha1 and md5 from the RustCrypto project.
This is an experiment in replacing the libnss hash functions with
pure Rust versions that will allow us to remove nss as a compile
time option.
Initial tests are good, even with a 10% or so performance
improvement when being called from C.
Also trying a module naming scheme where modules under the ffi
modules are purely for exports to C, as it doesn't make any
sense to use this new hashing module directly from Rust.
4 years ago
Kirby Kuehl
5499a6f7cd
doc: fix URL for unix-socket python example
4 years ago
Jeff Lucovsky
8ce2078a38
tftp: Add test cases
...
This commit adds test cases for the TFTP parser.
4 years ago
Jeff Lucovsky
e900b6d265
tftp: Improve parser
...
This commit improves TFTP parsing by ensuring the mode and opcode are
valid.
4 years ago
Jason Ish
18a1fd22c2
github-ci: use python3 in debian builds
4 years ago
Jason Ish
7904ef82d0
github-ci/macos: use brew to install Python 3
...
The default Python on MacOS is Python 2. Suricata-Verify now
depends on Python 3, so install it with Brew.
4 years ago
Jason Ish
37eff69a37
github-ci: update min Rust version from 1.34.2 to 1.41.1
4 years ago
Jason Ish
f77fd0c0cb
rust: include file cleanup
...
The cbindgen generated header should not include rust.h as
rust.h already includes the generated binding.
Fixup C source code that only pulled the generated include, it
should instead pull in "rust.h" which includes the generated
binding plus other misc. stuff.
4 years ago
Philippe Antoine
47dd9a5ebc
signature: Fix leak in urilen parsing
...
cf #4254
4 years ago
Victor Julien
423a5e2f6c
detect/file.data: support ftp and ftp-data
4 years ago
Victor Julien
45eddde573
detect/file.name: register inspect engine for ftp-data
4 years ago
Jeff Lucovsky
f8fef0dd05
decode/tcp: Improved handling of TFO options
...
This commit improves handling of TCP fast open options
- Option length must be in [6, 18]
- Option length must be an even value
4 years ago
Gianni Tedesco
10ea60a237
detect: Validate that NOOPT options don't have optvals
...
Without this, a simple typo between : and ; is able to hide actual bugs
in rules.
I discovered 2 bugs in ET open ruleset this way.
4 years ago
Gianni Tedesco
cebe15c23b
detect-fast-pattern: Mark as OPTIONAL_OPT, instead of NOOPT
...
Also update the erroneous comment about it.
4 years ago
Sascha Steinbiss
f78f444a5e
doc: build all manpages
4 years ago
Eric Leblond
dfe5785bfa
ebpf: avoid need of 32 bit header
...
Compilation of xdp_lb.c was failing in some case with the following
error:
/usr/include/x86_64-linux-gnu/gnu/stubs.h:7:11: fatal error: 'gnu/stubs-32.h' file not found
This patch add some define to be able to skip recursive inclusion of
header files leading to the problem.
4 years ago
Juliana Fajardini
e33bbee9b7
nbss: add parser tests
...
Add tests to parse_nbss_record and parse_nbss_record_partial
4 years ago
Eric Leblond
8d034b4163
eve/dhcp: avoid to call common logging twice
4 years ago
Joshua Lumb
9d432bbab3
threads: More descriptive startup output
4 years ago
Carl Smith
9b840104bd
lua: Make the rule action available to output scripts
...
Useful for those that want to do custom logging from lua
4 years ago
Justin Ossevoort
320de5f43d
eve: Log tenant_id for all eve-json messages
4 years ago
Carl Smith
660b68a083
nsh: Parsing of Network Services Header and payload
...
Support for EtherType 0x894F and basic header
4 years ago
Victor Julien
db2dbaaf40
stream/midstream: handle packet loss after SYN/ACK
4 years ago
Victor Julien
895938080f
stream/tcp: fix invalid ack events in timewait state
4 years ago
Victor Julien
49bd1f85b9
flow/timeout: fix TCP seq/ack for reversed flows
...
When a flow is swapped it also swaps the stream trackers, so it does
not make sense to reverse them during pseudo packet creation.
4 years ago
Victor Julien
3c7c361b60
detect/stream: fix async stream inspection
...
Move raw progress forward only if detect uses stream data, indicated
by the PKT_DETECT_HAS_STREAMDATA flag.
4 years ago
Victor Julien
8aa02c6d15
stream/tcp: fix async mode ACK validation
4 years ago
Philippe Antoine
8d659c6500
fuzz: improves sigpcap target with PacketPoolInit
4 years ago
Victor Julien
372fc26739
ci: buildbot is decommissioned, so remove prscript refs
4 years ago
Jason Ish
49ca070446
github-ci: use a unique id for the commit check cargo cache
...
All builds have been using the same cache id for ~/.cargo which
could lead us to conflict situations which is what I think we are
seeing with the commit-check job.
4 years ago
Shivani Bhardwaj
6c19e7d0d4
counters: convert to FAIL/PASS API
4 years ago
Shivani Bhardwaj
7eef4e83e5
confyaml: convert to FAIL/PASS API
4 years ago
Shivani Bhardwaj
fb311e3d9d
applayer: convert to FAIL/PASS API
4 years ago
Shivani Bhardwaj
bfd956ce67
applayer/htp/xff: convert to FAIL/PASS API
4 years ago
Shivani Bhardwaj
b195ffbe18
applayer/ftp: convert to FAIL/PASS API
4 years ago
Shivani Bhardwaj
2e3d408e6f
fastlog: convert to FAIL/PASS API
4 years ago
Janani Ramjee
2d3cf11906
detect/mark: convert unittests to use PASS/FAIL API
4 years ago
Juliana Fajardini
2765bff0c5
detect/msg: convert to FAIL/PASS API
...
Issue 4053. Adjust code formatting style (wrap long lines).
Replace SigInit with DetectEngineAppendSig.
4 years ago
Sumera Priyadarsini
d4264748d8
detect: filesha1: convert unittests to use PASS/FAIL API
...
Currently, unit tests use integer values 1 and 0 to denote pass
and fail status of tests respectively. Modify the unit test
detect-filesha1 to use the PASS/FAIL API instead.
4 years ago
Juliana Fajardini
5226ba1c15
Rust: generic files definition
...
Issue: Optimization 3825
- filecontainer: add Files structure, to replace/unify SMBFiles,
NFSFiles and HTTP2Files
- smb/files: delete SMBFiles implementation
- smb/smb: replace SMBFiles with Files
- nfs/nfs: delete NFSFiles implementation, replace its former
declarations with Files' ones
- http2/http2: replace HTTP2Files with Files
- http2/mod: Delete reference to file files.rs
- http2/files: Delete
4 years ago
Juliana Fajardini
d2144c0dfb
detect-sid: fail/pass api
...
- convert unittests to new FAIL/PASS API.
4 years ago