Documentation #3046


Document each default value from the config

Added by Andreas Herz over 3 years ago. Updated over 2 years ago.

Target version:
Affected Versions:


There are some parts at the config documentation (comments) which don't include the default and aren't 100% obvious.

Related issues 1 (1 open0 closed)

Related to Task #4762: Suricon 2021 brainstormAssignedVictor JulienActions
Actions #1

Updated by Andreas Herz over 3 years ago

I would add those to the documentation AND the config, any objections?

Actions #2

Updated by Victor Julien about 3 years ago

Not sure, maybe this needs to be looked at on a case by case basis. The default yaml is a monster, so adding more things to it is something that I would like to do carefully.

I didn't find a ticket for having multiple yamls (e.g. minimal/normal/everything, or split out yamls), but maybe its time to revisit this.

Actions #3

Updated by Andreas Herz about 3 years ago

Another approach would be to make the current config much smaller, even remove all comments and just rely on the documentation where it's also easier to keep the defaults?

If not, adding the defaults to the current config shouldn't be too much.

Jason, do you know any nice way to deal with multiple yamls?

Actions #4

Updated by Andreas Herz about 3 years ago

  • Tracker changed from Optimization to Documentation
Actions #5

Updated by Andreas Herz about 3 years ago

  • Target version changed from Documentation to TBD
Actions #6

Updated by Victor Julien over 2 years ago

In general the question of what to have and haven't be part of the yaml shouldn't block already improving the userguide.

Actions #7

Updated by Jason Ish over 2 years ago

I think right now we could break it up into multiple files with include statements. It would make sense to keep commonly updated stuff in the suricata.yaml, and less commonly updated stuff in includes.

Assuming the includes are in some system directory, say /usr/share/suricata/config/app-layer.yaml, then tweaking stuff includes does become harder. You would have to make a complete copy of the top level object and modify it, as we don't have a way to override just one deeply nested configuration parameters in a file, but you can do it with the --set.

I've seen in some other projects (maybe docker-compose files? filebeat configuration maybe?) where they provide a dotted syntax to override nested settings.. For example we may have:

    HOME_NET: "[,,]" 

I've seen overrides provided in the format:
vars.address-groups.HOME_NET: "" 

which could be convenient. However it gets a little tricker for the arrays we have, which will probably have settings where overrides make sense as well.

It would be nice to define what we want to break out, and maybe go from there.

PostgreSQL has a rather large configuration file when all options are present. What they do is install a smaller file with some common option, then the rest get their default. Their documentation then covers all options, and while I'm not sure if this is maintained anymore, they also had an annotated exchaustive configuration file with defaults:

While it does increase overhead, we could make the sample suricata.yaml in the doc exhaustive, and perhaps trim down what we have in the installed one.

Actions #8

Updated by Andreas Herz 11 months ago

  • Related to Task #4762: Suricon 2021 brainstorm added

Also available in: Atom PDF