Jason Ish
ee7e813256
Bug 1417 - Record sequence nodes as sequences.
...
Nodes that are sequences weren't being recorded as such, causing
rules to fail to load.
Change sequence test name to reflect better what it tests, and
test that the sequence node is detected as a sequence.
11 years ago
Jason Ish
33e4cc065f
Promote nodes set with --set to sequence nodes as needed.
...
A node isn't known to be a sequence node until the YAML is parsed.
If a node sequence node was set on the command line, promote
it to a sequence node when it is discovered by YAML to be
a sequence node.
Fixes comment #18 in issue 921.
12 years ago
Jason Ish
e8626509cc
When setting a sequence value, check for an existing node.
...
This makes --set af-packet.0.threads=X do what you expect by
looking for the sequence node before setting.
12 years ago
Eric Leblond
28c5c68192
error checking: add missing alloc error treatment
...
The return of some malloc like functions was not treated in some
places of the code.
12 years ago
Jason Ish
b033acfb0c
Subsequent configuration keys now override previous ones
...
instead of merging.
The exception is final values, for example, values like
default-log-dir that may be set on the command line.
12 years ago
Jason Ish
b8e13d4bd6
More concise API for setting config values that
...
can be overrided or not (final values).
12 years ago
Jason Ish
06f4fe8e0c
Remove the single line if statements.
12 years ago
Jason Ish
8625c9eba8
Support for configuration include files.
12 years ago
Victor Julien
164d60e8cd
Yaml: give a more detailed error if the user supplies a directory instead of a yaml file. Bug #803 .
12 years ago
Victor Julien
4b2d94a841
Add line number to warning about mangled yaml parameters. Limit number of warnings to 10.
14 years ago
Nikolay Denev
32e898f2e3
Convert config entries using underscores to dashes and emit deprecation warnings.
14 years ago
Victor Julien
47abd0ef19
Fix compiler warning.
14 years ago
Victor Julien
55da9787a4
Win32 compile fixes.
14 years ago
Gerardo Iglesias Galvan
9f4fae5b1a
Fix inconsistent use of dynamic memory allocation
15 years ago
William Metcalf
ce01927515
Import of GPLv2 Header 050410
15 years ago
Victor Julien
fe55d996c1
Improve yaml loaded debug output formatting.
16 years ago
Jason Ish
acaee78b1c
Fix bug 125. - Always bail on parse errors. - Exit if loading the config file fails. - Display the line number where the parsing failed.
16 years ago
Pablo Rincon
25a3a5c6d8
Adding mem wrapper to debug runtime alloc()/free() functions. Fixing some memory leaks.
16 years ago
Jason Ish
7537013e16
Fix bug 99.
...
- Handle the case where the parent node already exists in ConfSet.
- Deal with allow_override properly when a node has already been
set with ConfSet.
16 years ago
Jason Ish
ea277a0b36
Cleanup of configuration internals. Use an n-ary type tree for everything instead of a first level hash branching off into n-ary type trees.
...
Reduces the code and uses a uniform internal data structure.
16 years ago
Jason Ish
8570976ee0
Fix for lists that are children of another list. Fix memory leak by only setting the sequence index value to the first item found.
16 years ago
Victor Julien
0d34990d7f
Add OpenBSD's strlcpy and strlcat and replace all strcat/strcpy/strncat/strncpy by those calls.
16 years ago
Jason Ish
4e1acf5fd2
Require that the configuration file begins with a valid YAML version. At this time this means the configuration file must begin with
...
%YAML 1.1
16 years ago
Jason Ish
5e318aa342
Fix issue 55.
...
Don't process any key/value pairs until we've hitting a mapping.
16 years ago
Jason Ish
844c444af1
Use the configuration file to setup alert logging (and http logging).
...
Only setup for the live pcap modes at the moment.
16 years ago
Jason Ish
6520d42b4c
Allow nested sequences.
16 years ago
Jason Ish
668b86cba4
Fix issue 36. Give each unit test a fresh configuration context - helps tests pass when a config file is passed in, which can
...
mess up the "expected" output, as this is testing loading
values into the configuration system.
16 years ago
Jason Ish
59ec05645f
Index sequence items - allows us to store sequences of mappings in the configuration database.
16 years ago
Victor Julien
ecf86f9c23
Rename to Suricata.
16 years ago
Victor Julien
241db64dd7
Fix a few memory issues.
16 years ago
Anoop Saldanha
dc44700ce5
Support vars lookup from conf file. Current patch support address and port group vars lookup
16 years ago
Jason Ish
ec9fa7b0a7
Files missed in last commit.
...
Update Conf API to allow direct access to nodes.
A configuration node is now a tailq head and a tailq entry. This allows us to build
n-ary type trees to build something DOM like.
Properly process lists so a list of rule files (for example) can be loaded.
16 years ago
Jason Ish
d39a291427
Refactor yaml loader so we can load strings or files.
16 years ago
Victor Julien
bcc5bbef93
Yet more logging api usage changes.
16 years ago
Victor Julien
0d0ffb9963
Reorganize header inclusions.
16 years ago
Victor Julien
f03d540d2f
Suppress debug output in yaml loader.
16 years ago
Jason Ish
c91a4baad5
- Autoconf goo for libyaml.
...
- Mock YAML configuration file.
- YAML loader for basic YAML files - not all YAML elements support yet..
todo.
- Add --dump-config command line parameter to dump the state of the
configuration db after loading the config file.
16 years ago