-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
476 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
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
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
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
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,18 @@ | ||
EXTRA_DIST=resolver.py readme.md pylintrc | ||
bin_SCRIPTS=resolver.py | ||
|
||
pkgdocdir=${docdir}/resolver | ||
pkgdoc_DATA=readme.md | ||
|
||
pylint: | ||
pylint-3 resolver.py | ||
|
||
flake8: | ||
flake8 resolver.py | ||
|
||
pycodestyle: | ||
pycodestyle-3 resolver.py | ||
|
||
lint: pylint flake8 pycodestyle | ||
|
||
include ../aminclude.am |
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,16 @@ | ||
# -*- mode: conf; -*- | ||
|
||
[MASTER] | ||
ignore: .git | ||
|
||
[REPORTS] | ||
output-format: parseable | ||
reports: no | ||
|
||
[MESSAGES CONTROL] | ||
disable: locally-disabled, no-self-use, bad-continuation | ||
|
||
[DESIGN] | ||
max-statements: 200 | ||
max-branches: 40 | ||
max-locals: 30 |
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,59 @@ | ||
# Resolver | ||
|
||
## Module description | ||
|
||
This module amends flow records with resolved fields. | ||
|
||
|
||
## Input data | ||
|
||
This module expects flow records in Unirec format. The required fields | ||
are determined by run time parameters. | ||
|
||
|
||
## Output data | ||
|
||
Flows are sent on the output interface, also in Unirec format, they | ||
contain all the fields of the input interface plus the configured | ||
resolved fields from the resolvspec parameter. | ||
|
||
|
||
## Available resolutions | ||
|
||
These resolutions are available: | ||
|
||
* dns_ptr: ip address (ipaddr) -> domain name (string) | ||
* dns_a: domain name (string) -> ip address (ipaddr) | ||
* dns_aaaa: domain name (string) -> ip address (ipaddr) | ||
* ent_services: port (uint16)/protocol (uint8) -> service name | ||
(string) | ||
|
||
|
||
## Module parameters | ||
|
||
In addition to the implicit *libtrap* parameters `-i IFC_SPEC`, `-h` | ||
and `-v` (see [Execute a | ||
module](https://github.com/CESNET/Nemea#try-out-nemea-modules)) this | ||
module takes the following parameters: | ||
|
||
* `-u` `--urformat` urformat | ||
Specify unirec input format. | ||
|
||
* `-r` `--resolvspec` infield[/infield] resolution outfield | ||
Specify field(s), what lookup to do of it/them and where to put the | ||
result. | ||
|
||
For more detailed information see above under [available | ||
resolutions](#available-resolutions). | ||
|
||
All fields specified as infields in resolvspec parameters must be | ||
supplied in the urformat parameter for this module to start. Note | ||
though that the downstream module will fail if it requires non | ||
resolved fields you do not specify in the uformat parameter. | ||
|
||
<!--- Local variables: --> | ||
<!--- mode: markdown; --> | ||
<!--- mode: auto-fill; --> | ||
<!--- mode: flyspell; --> | ||
<!--- ispell-local-dictionary: "british"; --> | ||
<!--- End: --> |
Oops, something went wrong.