-
Notifications
You must be signed in to change notification settings - Fork 90
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Test for configuration include arrays being loaded at the correct location. Bug: #6300
- Loading branch information
1 parent
592f045
commit c31735b
Showing
4 changed files
with
52 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# Configure Include Array Test | ||
|
||
Test that files included as part of array are included into the | ||
corrent location. | ||
|
||
Issue: https://redmine.openinfosecfoundation.org/issues/6300 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
%YAML 1.1 | ||
--- | ||
|
||
af-packet: | ||
- interface: enp10s0 | ||
cluster-id: 99 | ||
cluster-type: cluster_flow | ||
defrag: yes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
%YAML 1.1 | ||
--- | ||
|
||
classification-file: /etc/suricata/classification.config | ||
reference-config-file: /etc/suricata/reference.config | ||
|
||
# These will be included into the root of the configuration tree. | ||
include: | ||
- ./af-packet.yaml | ||
|
||
foobar: | ||
include: | ||
# This should be included under foobar. | ||
- ./af-packet.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
requires: | ||
min-version: 7 | ||
|
||
pcap: false | ||
|
||
args: | ||
- --dump-config | ||
|
||
checks: | ||
- shell: | ||
args: grep '^af-packet.0 = interface' stdout | wc -l | ||
expect: 1 | ||
|
||
- shell: | ||
args: grep '^af-packet.0.interface = enp10s0' stdout | wc -l | ||
expect: 1 | ||
|
||
- shell: | ||
args: grep 'foobar.af-packet.0 = interface' stdout | wc -l | ||
expect: 1 | ||
|
||
- shell: | ||
args: grep 'foobar.af-packet.0.interface = enp10s0' stdout | wc -l | ||
expect: 1 |