Suricata - IDS/IPS
Find a file
Jason Ish c98c49d4ba dns: parse and alert on invalid opcodes
Accept DNS messages with an invalid opcode that are otherwise
valid. Such DNS message will create a parser event.

This is a change of behavior, previously an invalid opcode would cause
the DNS message to not be detected or parsed as DNS.

Issue: #5444
2023-01-24 10:44:49 +01:00
.github github-ci: fedora non-root: suricata-verify -q 2023-01-24 10:44:49 +01:00
benches Initial add of the files. 2009-07-28 23:25:09 +02:00
contrib tile: remove files 2019-02-20 22:16:54 +01:00
doc userguide: update http.cookie description 2023-01-17 14:25:06 +01:00
ebpf ebpf: fix gre encapsulation in xdp_lb 2021-04-15 15:45:14 +02:00
etc dns: parse and alert on invalid opcodes 2023-01-24 10:44:49 +01:00
lua lua output: Update example script to match style of user doc examples 2018-03-30 09:41:38 +02:00
python suricatasc: add dataset-lookup command 2022-10-27 09:44:20 +02:00
qa cocci: remove action check as we no longer use macros 2022-10-19 23:03:24 +02:00
rules dns: parse and alert on invalid opcodes 2023-01-24 10:44:49 +01:00
rust dns: parse and alert on invalid opcodes 2023-01-24 10:44:49 +01:00
scripts scripts: fix app-layer-protos.c setup 2022-12-20 16:17:11 +01:00
src log-pcap: remove early output initializing if offline 2023-01-24 10:44:49 +01:00
suricata-update python: install without distutils 2022-08-09 07:36:59 +02:00
.clang-format devguide: move into userguide as last chapter 2022-03-29 07:56:03 +02:00
.gitignore readthedocs: add configuration file 2021-10-01 08:01:15 +02:00
.lgtm.yml ci: adds CodeQL workflow and LGTM support 2022-06-03 10:50:30 +02:00
.readthedocs.yaml readthedocs: enable all formats 2022-11-25 14:02:57 +01:00
acsite.m4 configure: check for u_int and friends 2020-04-16 14:37:34 +02:00
autogen.sh autogen/rust: remove Cargo.lock 2018-01-30 14:43:52 +01:00
ChangeLog release: 7.0.0-beta1; update changelog 2022-10-26 16:39:22 +05:30
config.rpath Add file needed for some autotools version. 2013-07-17 15:03:28 +02:00
configure.ac log: Add module and subsystem identifiers to log 2022-12-20 08:51:33 +01:00
COPYING GPL license sync with official gpl-2.0.txt 2015-10-08 10:53:45 +02:00
doxygen.cfg prelude: remove the prelude output 2021-09-17 10:50:58 +02:00
libsuricata-config.in libsuricata-config: program to print build flags 2021-02-16 11:43:26 -06:00
LICENSE GPL license sync with official gpl-2.0.txt 2015-10-08 10:53:45 +02:00
Makefile.am devguide: drop use of mscgen script in builds/make 2022-03-29 07:56:03 +02:00
Makefile.cvs Initial add of the files. 2009-07-28 23:25:09 +02:00
README.md doc: refresh main README; more accurate CI description 2022-02-01 07:44:24 +01:00
requirements.txt scripts/bundle: use git instead of tar.gz 2022-04-30 08:23:28 +02:00
suricata.yaml.in smb: configurable max number of transactions per flow 2023-01-10 11:45:28 +01:00
threshold.config docs: replace redmine links and enforce https on oisf urls 2018-02-14 14:25:46 +01:00

Suricata

Fuzzing Status codecov

Introduction

Suricata is a network IDS, IPS and NSM engine developed by the OISF and the Suricata community.

Installation

https://suricata.readthedocs.io/en/latest/install.html

User Guide

You can follow the Suricata user guide to get started.

Contributing

We're happily taking patches and other contributions. Please see https://redmine.openinfosecfoundation.org/projects/suricata/wiki/Contributing for how to get started.

Suricata is a complex piece of software dealing with mostly untrusted input. Mishandling this input will have serious consequences:

  • in IPS mode a crash may knock a network offline;
  • in passive mode a compromise of the IDS may lead to loss of critical and confidential data;
  • missed detection may lead to undetected compromise of the network.

In other words, we think the stakes are pretty high, especially since in many common cases the IDS/IPS will be directly reachable by an attacker.

For this reason, we have developed a QA process that is quite extensive. A consequence is that contributing to Suricata can be a somewhat lengthy process.

On a high level, the steps are:

  1. Github-CI based checks. This runs automatically when a pull request is made.

  2. Review by devs from the team and community

  3. QA runs from private QA setups. These are private due to the nature of the test traffic.

Overview of Suricata's QA steps

OISF team members are able to submit builds to our private QA setup. It will run a series of build tests and a regression suite to confirm no existing features break.

The final QA runs takes a few hours minimally, and generally runs overnight. It currently runs:

  • extensive build tests on different OS', compilers, optimization levels, configure features
  • static code analysis using cppcheck, scan-build
  • runtime code analysis using valgrind, AddressSanitizer, LeakSanitizer
  • regression tests for past bugs
  • output validation of logging
  • unix socket testing
  • pcap based fuzz testing using ASAN and LSAN
  • traffic replay based IDS and IPS tests

Next to these tests, based on the type of code change further tests can be run manually:

  • traffic replay testing (multi-gigabit)
  • large pcap collection processing (multi-terabytes)
  • fuzz testing (might take multiple days or even weeks)
  • pcap based performance testing
  • live performance testing
  • various other manual tests based on evaluation of the proposed changes

It's important to realize that almost all of the tests above are used as acceptance tests. If something fails, it's up to you to address this in your code.

One step of the QA is currently run post-merge. We submit builds to the Coverity Scan program. Due to limitations of this (free) service, we can submit once a day max. Of course it can happen that after the merge the community will find issues. For both cases we request you to help address the issues as they may come up.

FAQ

Q: Will you accept my PR?

A: That depends on a number of things, including the code quality. With new features it also depends on whether the team and/or the community think the feature is useful, how much it affects other code and features, the risk of performance regressions, etc.

Q: When will my PR be merged?

A: It depends, if it's a major feature or considered a high risk change, it will probably go into the next major version.

Q: Why was my PR closed?

A: As documented in the Suricata Github workflow here https://redmine.openinfosecfoundation.org/projects/suricata/wiki/Github_work_flow, we expect a new pull request for every change.

Normally, the team (or community) will give feedback on a pull request after which it is expected to be replaced by an improved PR. So look at the comments. If you disagree with the comments we can still discuss them in the closed PR.

If the PR was closed without comments it's likely due to QA failure. If the Github-CI checks failed, the PR should be fixed right away. No need for a discussion about it, unless you believe the QA failure is incorrect.

Q: the compiler/code analyser/tool is wrong, what now?

A: To assist in the automation of the QA, we're not accepting warnings or errors to stay. In some cases this could mean that we add a suppression if the tool supports that (e.g. valgrind, DrMemory). Some warnings can be disabled. In some exceptional cases the only 'solution' is to refactor the code to work around a static code checker limitation false positive. While frustrating, we prefer this over leaving warnings in the output. Warnings tend to get ignored and then increase risk of hiding other warnings.

Q: I think your QA test is wrong

A: If you really think it is, we can discuss how to improve it. But don't come to this conclusion too quickly, more often it's the code that turns out to be wrong.

Q: do you require signing of a contributor license agreement?

A: Yes, we do this to keep the ownership of Suricata in one hand: the Open Information Security Foundation. See http://suricata.io/about/open-source/ and http://suricata.io/about/contribution-agreement/