Jason Ish
583593aa1b
http/eve: use set_string_from_bytes where appropriate
...
The JsonBuilder set_string_from_bytes will escape unprintable
characters in the output stream. Using BytesToStringBuffer
can generate invalid UTF-8 which prevents the conversion from
a C string to a Rust string.
6 years ago
Victor Julien
d6cf4b3335
detect/dataset: error if set couldn't be fully loaded
6 years ago
Victor Julien
017c038bcb
datasets: free old data when reusing a hash container
6 years ago
Jeff Lucovsky
00f77f9643
log: Log errors while writing log info
...
This commit adds logic to log errors during output. Errors are logged
once and the number of errors is maintained.
6 years ago
Jeff Lucovsky
b9458adf8a
log: Add log output error code
6 years ago
Jeff Lucovsky
6cdd87f5ad
log: Use unlocked variants of stdio functions
...
This commit uses the unlocked variants of additional stdio functions
6 years ago
Jeff Lucovsky
3c91e14352
log: Add more stdio_unlocked macros
...
This commit adds additional macros for interfaces in stdio_unlocked
according to their local availability.
6 years ago
Victor Julien
fa0b91b18f
error: reformat enum
6 years ago
Victor Julien
fbdc776525
app-layer: handle parser return code issues more gracefully
6 years ago
Victor Julien
5155982ba5
pcap: fix minor scan-build warnings
6 years ago
Victor Julien
aac2b9dbb9
commandline: add static analyzer hint for -r parsing
6 years ago
Victor Julien
71297f575f
commandline: minor formatting fixes
6 years ago
Jeff Lucovsky
9efb936697
general: Improve grammar in error messages
...
This commit corrects a minor grammar issue in address/port error
messages.
6 years ago
Ali Jad Khalil
6be08637c3
decode/teredo: Modified/refactored Teredo logic
...
This is just a slight refactor to make analagous decoding/encapsulation
schemes - Geneve, Teredo, and VXLAN - be implemented as similarly as
possible.
6 years ago
Ali Jad Khalil
66452dd38a
decode/vxlan: Modified/refactored VXLAN logic
...
This is just a slight refactor to make analagous decoding/encapsulation
schemes - Geneve, Teredo, and VXLAN - be implemented as similarly as
possible.
6 years ago
Ali Jad Khalil
5d955c1836
decode/geneve: Add Geneve decoding functionality
...
These changes are in response to feature request 3063. Geneve is
very similar to VXLAN, but uses a slightly different encapsulation
scheme.
6 years ago
Victor Julien
77bafe13a3
decode: reformat event table
6 years ago
Jason Ish
665328b29e
plugins: require registration function SCPluginRegister
...
Instead of looking for a symbol, "PluginSpec" look for a function
named SCPluginRegister that returns a SCPlugin.
This makes it much easier to create Rust plugins without having
to deal with dlopen constructors and such, which is rather
straight forward in C, but a bit of advanced boilerplate in Rust
that can be eliminated by simply calling a registration function.
6 years ago
Jason Ish
335e4e728f
suricata: expose the SuricataContext with a function
...
Expose the "SuricataContext" required by Rust as a function. During
normal startup we register this context with the Rust code, but
plugins written in Rust will need to get the same registration
done, but to do this in a plugin, the plugin code must
call and set the context within its address space.
6 years ago
Jason Ish
87a91e6aa8
logging: expose the log level with a function
...
The log level needs to exposed so Rust plugins can bootstrap
themselves with the correct login to SCLogNotice!(), etc work
as expected.
6 years ago
Jason Ish
17776e098e
rust-context: remove unused opaque type Store
6 years ago
Joshua Lumb
6dbc6d6669
runmodes: memory leak on runmode single
6 years ago
Jeff Lucovsky
ff29345527
output: Remove unused output functions
...
This commit removes registration, initialization, and de-initialization
functions no longer needed
6 years ago
Jeff Lucovsky
15caf3eea5
log: Remove standalone output registration
...
Remove standalone output logger registration since eve is
multi-instance.
6 years ago
Victor Julien
703de67086
flow: fix multi-manager hash range calculation
6 years ago
Victor Julien
260a20bf91
flow: suppress noisy messages
6 years ago
Philippe Antoine
c06d8f2463
dcerpc: validate signature with dcerpc keywords
...
so that they do not use another protocol's keywords
6 years ago
Philippe Antoine
d509a78074
http: handles gaps
...
ie data=NULL and len>0 from libhtp callbacks
6 years ago
Victor Julien
23c0efa2ec
flowbits: convert flowbits dumping to json builder
6 years ago
Victor Julien
7facf5785f
detect/analyzer: convert to jsonbuilder
6 years ago
Victor Julien
d3cf2c21df
threshold: fix potential memory leak
6 years ago
Victor Julien
6444f738af
reject: minor code cleanup
...
Use enum for direction to assist compiler.
6 years ago
Victor Julien
b6fed6d431
stream: fix GAP size
...
Fix GAPs sizes sometimes exceeding the ACK'd data size.
6 years ago
Victor Julien
6978d8dac6
stream: fix deinit after incomplete init
6 years ago
Victor Julien
a015a31073
output/flow: fix deinit after incomplete init
6 years ago
Victor Julien
c39101bbec
nfq: suppress debug message using info level
6 years ago
Victor Julien
797a128256
plugins: suppress coverity toctou warning
6 years ago
Victor Julien
bd68bd5037
flow: work around harmless coverity warnings
6 years ago
Victor Julien
29148fb563
flow: fix spare sync incomplete counter
6 years ago
Victor Julien
50c7b0d1c3
reject: work around coverity warning
6 years ago
Vadym Malakhatko
65455208a5
plugin: fix typo in long_opts struct
6 years ago
Jeff Lucovsky
cc93638d33
napatech: Style -- remove extra space
6 years ago
Jeff Lucovsky
67529bd25a
napatech: Use proper parser for type
...
This commit uses the proper parser call for the value being parsed.
6 years ago
Jeff Lucovsky
45b055aca5
napatech: Improve configuration range handling
...
This commit corrects issues parsing ranges from the Napatech section of
the configuration file.
6 years ago
Jeff Lucovsky
c408b15c51
napatech: Fix compiler issues w/out bypass
...
This commit fixes compiler errors when Napatech bypass is not configured
6 years ago
Carl Smith
81d7a7aa82
threshold: Change rule parsing to use pcre_copy_substring
...
Fixes memory leak when parsing threshold rules.
All parsed strings are less than 16 characters except
for the IP address which could be up to 48 characters.
Remove redefinition of MAX_SUBSTRINGS
6 years ago
Jason Ish
b8994cdaca
plugins: track all loaded plugins in a list
...
Track the pointer returned from dlopen in a list to prevent a
resource leak by the pointer going out of scope.
Found by Coverity, CID 1465661.
Redmine issue:
https://redmine.openinfosecfoundation.org/issues/3864
6 years ago
Jason Ish
dbb5dcb1dd
plugins: use closedir to close open directory (not free)
...
Found by Coverity, CID 1465665: ALLOC_FREE_MISMATCH.
Redmine issue:
https://redmine.openinfosecfoundation.org/issues/3864
6 years ago
Jason Ish
f2a1626b51
output-json: fix Coverity USE_AFTER_FREE
...
Return error if plugin open fails. Fixes Coverity CID 1465664
USE_AFTER_FREE error.
Redmine issue:
https://redmine.openinfosecfoundation.org/issues/3864
6 years ago
Victor Julien
ac491c6e8d
fuzz/pcap: add missing flow queue
6 years ago