]>
git.ipfire.org Git - thirdparty/suricata.git/log
Jason Ish [Mon, 12 Sep 2016 16:39:14 +0000 (10:39 -0600)]
setup-app-layer-logger.sh: update for logging changes
Jason Ish [Wed, 24 Aug 2016 14:39:39 +0000 (08:39 -0600)]
logging: proper failure on memory allocation error
unwinds all previous logger allocations
Jason Ish [Fri, 15 Jul 2016 14:14:03 +0000 (08:14 -0600)]
flow-vars: remove flow locks
Code is now entered under flow lock.
Jason Ish [Fri, 15 Jul 2016 14:13:16 +0000 (08:13 -0600)]
flow-bits: remove flow locks
Code is now entered under flow lock.
Jason Ish [Thu, 14 Jul 2016 15:53:59 +0000 (09:53 -0600)]
lua: remove flow locking from the lua layer
Jason Ish [Wed, 13 Jul 2016 23:07:45 +0000 (17:07 -0600)]
stream: remove lock from StreamTcpSegmentForEach
This is only entered from logging functions which are already
called with a locked flow.
Jason Ish [Wed, 13 Jul 2016 16:48:14 +0000 (10:48 -0600)]
logging: remove the packetqueue's from the logging path
They are not referenced by any loggers, and they probably
shouldn't be either.
Jason Ish [Mon, 20 Jun 2016 15:52:28 +0000 (09:52 -0600)]
logging: hook into flow worker thread
Jason Ish [Wed, 8 Jun 2016 19:56:35 +0000 (13:56 -0600)]
output-streaming: free thread store on deinit
Jason Ish [Tue, 7 Jun 2016 23:20:23 +0000 (17:20 -0600)]
logging: rename registration functions to not have tmm
As the logging modules are no longer threading modules, rename
them so they don't look like they are being registered as
threading modules.
Also, move the registration to the output.c which will handle
registration of the loggers.
Jason Ish [Tue, 7 Jun 2016 20:56:17 +0000 (14:56 -0600)]
logging: convert pcap log to non-thread module
Jason Ish [Tue, 7 Jun 2016 20:55:18 +0000 (14:55 -0600)]
logging: just return if no tx loggers
Jason Ish [Mon, 6 Jun 2016 19:58:37 +0000 (13:58 -0600)]
logging: use a single entry point for all loggers
Introduces a new thread module, TMM_LOGGER, which is the
root most logger.
Only handles loggers in the packet path, stats and flow
logging are not included.
The loggers are made up of a hierarchy of loggers. At the top we
have the root logger which is the main entry point to
logging. Under the root there exists parent loggers that are the
entry point for specific types of loggers such as packet logger,
transaction loggers, etc. Each parent logger may have 0 or more
loggers that actual handle the job of producing output to something
like a file.
Jason Ish [Mon, 6 Jun 2016 20:38:56 +0000 (14:38 -0600)]
logging: remove output priorities: not used
Jason Ish [Fri, 3 Jun 2016 21:38:02 +0000 (15:38 -0600)]
logging: remove dead code from output-json
The "parent" json logger was setup like a real logger, but
some of that code was never being called.
Jason Ish [Sun, 29 May 2016 06:11:03 +0000 (00:11 -0600)]
output.[ch]: consistent style
- Clean up function declaration.
- Consistenly use typedefs for function points.
No functional changes.
Jason Ish [Sat, 28 May 2016 00:57:06 +0000 (18:57 -0600)]
logging: add profiling back for non-tmm loggers
The loggers moved away from a TMM required a new
profiling support.
Jason Ish [Tue, 31 May 2016 16:23:34 +0000 (10:23 -0600)]
logging: convert lua output to non-thread module
Jason Ish [Fri, 3 Jun 2016 16:48:10 +0000 (10:48 -0600)]
logging: convert tls log to non-thread module
Jason Ish [Fri, 27 May 2016 19:16:22 +0000 (13:16 -0600)]
logging: convert alert debug log to non-thread module
Jason Ish [Fri, 27 May 2016 19:12:06 +0000 (13:12 -0600)]
logging: convert tcp data logging to non-thread module
Jason Ish [Fri, 27 May 2016 19:03:58 +0000 (13:03 -0600)]
logging: convert tls store logging to non-thread module
Jason Ish [Fri, 27 May 2016 18:55:50 +0000 (12:55 -0600)]
logging: convert file data logging to non-thread module
Jason Ish [Fri, 27 May 2016 17:59:13 +0000 (11:59 -0600)]
logging: convert file logging to non-thread module
Jason Ish [Fri, 27 May 2016 16:45:11 +0000 (10:45 -0600)]
logging: convert unified2 to non-thread module
Jason Ish [Fri, 27 May 2016 16:39:50 +0000 (10:39 -0600)]
logging: convert stats loggers to non-thread module
Jason Ish [Fri, 27 May 2016 16:21:19 +0000 (10:21 -0600)]
logging: convert http log to non-thread module
Jason Ish [Fri, 27 May 2016 16:17:21 +0000 (10:17 -0600)]
logging: convert alert syslog to non-thread module
Jason Ish [Fri, 27 May 2016 16:10:02 +0000 (10:10 -0600)]
logging: convert drop output to non-thread module
Jason Ish [Fri, 27 May 2016 16:05:44 +0000 (10:05 -0600)]
logging: convert json template output to non-thread module
Jason Ish [Fri, 27 May 2016 16:01:54 +0000 (10:01 -0600)]
tests: setup unit test framework earlier
Allows tests to be registered early, in support of moving
outputs away from thread modules.
Jason Ish [Fri, 27 May 2016 08:05:30 +0000 (02:05 -0600)]
logging: convert json drop output to non-thread module
Jason Ish [Fri, 27 May 2016 08:01:52 +0000 (02:01 -0600)]
logging: convert json smtp output to non-thread module
Jason Ish [Fri, 27 May 2016 08:00:24 +0000 (02:00 -0600)]
logging: convert json ssh output to non-thread module
Jason Ish [Fri, 27 May 2016 07:54:36 +0000 (01:54 -0600)]
logging: convert json netflow output to non-thread module
Jason Ish [Fri, 27 May 2016 07:52:01 +0000 (01:52 -0600)]
logging: convert json flow output to non-thread module
Jason Ish [Fri, 27 May 2016 07:33:10 +0000 (01:33 -0600)]
logging: convert json alert output to non-thread module
Jason Ish [Fri, 27 May 2016 07:18:22 +0000 (01:18 -0600)]
logging: convert json tls output to non-thread module
Jason Ish [Fri, 27 May 2016 07:07:10 +0000 (01:07 -0600)]
logging: convert prelude output to non-thread module
Jason Ish [Fri, 27 May 2016 07:03:13 +0000 (01:03 -0600)]
logging: convert eve http to non-thread module
Jason Ish [Fri, 27 May 2016 04:26:04 +0000 (22:26 -0600)]
logging: convert eve dns logging to non-thread module
Jason Ish [Thu, 26 May 2016 16:45:55 +0000 (10:45 -0600)]
logging: convert fast log to a non-thread module
Jason Ish [Thu, 26 May 2016 05:32:48 +0000 (23:32 -0600)]
logging: convert dns log to a non-thread module
Victor Julien [Fri, 16 Sep 2016 16:29:18 +0000 (18:29 +0200)]
detect: mark alproto in keyword reg deprecated
No existing code uses it, and it had been useless for some time.
Victor Julien [Fri, 16 Sep 2016 16:27:47 +0000 (18:27 +0200)]
gitignore: update to hide more local files
Victor Julien [Fri, 16 Sep 2016 16:24:29 +0000 (18:24 +0200)]
detect: don't set alproto while registering keyword
The field is not used except for some printing, and is wrong for
many keywords.
Victor Julien [Fri, 16 Sep 2016 13:13:33 +0000 (15:13 +0200)]
detect file: enable HTTP inspection from validate func
Victor Julien [Fri, 16 Sep 2016 12:40:35 +0000 (14:40 +0200)]
detect file: enforce protocol in single place
Instead of trying to enforce the app layer protocol in each file
function, enforce it in the generic validation function.
Victor Julien [Fri, 16 Sep 2016 12:39:56 +0000 (14:39 +0200)]
app-layer: add function to check if app-layer supports files
Victor Julien [Thu, 14 Jul 2016 08:36:54 +0000 (10:36 +0200)]
threads: remove EngineKill & SURICATA_KILL
EngineStop and EngineKill were effectively doing the same, so
removed the kill variant.
Victor Julien [Thu, 14 Jul 2016 07:49:21 +0000 (09:49 +0200)]
threads: failed thread is a fatal error now
Victor Julien [Wed, 13 Jul 2016 19:07:11 +0000 (21:07 +0200)]
threading: remove thread restart logic
Thread restarts never worked well and the rest of the engine was
never really expecting errors to lead to thread restarts. Either
and error is recoverable in the thread, or not at all.
So this patch removes the functionality completely.
Victor Julien [Mon, 19 Sep 2016 10:37:12 +0000 (12:37 +0200)]
Open Suricata 3.2 development branch
Victor Julien [Mon, 19 Sep 2016 07:12:28 +0000 (09:12 +0200)]
magic: fix broken tests after CentOS6 update
Victor Julien [Mon, 12 Sep 2016 16:10:51 +0000 (18:10 +0200)]
mpls: add missing event type + rule
Victor Julien [Thu, 8 Sep 2016 08:39:51 +0000 (10:39 +0200)]
bpf: fix file parsing memory handling
Fix improper fread string handling. Improve error handling.
Skip trailing spaces for slightly more pretty printing.
Coverity CID 400763.
Thanks to Steve Grubb for helping address this issue.
Victor Julien [Thu, 1 Sep 2016 13:06:11 +0000 (15:06 +0200)]
detect: don't print (null) in --list-keywords=all
Eric Leblond [Fri, 16 Sep 2016 11:34:09 +0000 (13:34 +0200)]
detect: fix setup for some keywords
Fix problems found by siginit.cocci.
Eric Leblond [Fri, 16 Sep 2016 09:47:20 +0000 (11:47 +0200)]
coccinelle: add siginit test
Add a test that check an inversion during keyword setup where
we add a sigmatch to a signature and then do error handling on it.
This was causing a double free of some elements and ultimately a
segfault.
Proposed-by: Victor Julien <victor@inliniac.net>
Jason Ish [Thu, 15 Sep 2016 17:19:12 +0000 (11:19 -0600)]
detect-flowbits: more unittest macro usage
Also cleanup some tests by removing extra code after a test was
determined to fail.
Jason Ish [Thu, 15 Sep 2016 16:40:22 +0000 (10:40 -0600)]
hostbits: use new unittest macros
Jason Ish [Tue, 13 Sep 2016 23:09:58 +0000 (17:09 -0600)]
hostbits: fail parse on unexpected trailing data
Address issue https://redmine.openinfosecfoundation.org/issues/1889
for hostbits. This involves updating the regular expresssion
to capture any trailing data as the regex already keeps
spaces out of the name.
A unit test was converted to new macros to find out which
line it was failing at after updating regex.
Jason Ish [Tue, 13 Sep 2016 16:57:09 +0000 (10:57 -0600)]
flowbits: validate that there are no spaces in the name
Fixes issue: https://redmine.openinfosecfoundation.org/issues/1889
To catch the issue where the ';' is missing we have to expand the
regex to capture the whole name string, not just the leading
valid stuff. Then verify that there are no spaces in the name
(Snort has the same restriction) and fail if there is.
Eric Leblond [Wed, 14 Sep 2016 13:09:47 +0000 (15:09 +0200)]
unix-manager: fix output of version command
Make it consistent with the output of version command line flag.
Andreas Herz [Wed, 7 Sep 2016 20:17:01 +0000 (22:17 +0200)]
rule-parsing: reject unescaped double quote within content section
Victor Julien [Tue, 6 Sep 2016 15:52:45 +0000 (17:52 +0200)]
Update Changelog for 3.1.2
Victor Julien [Tue, 6 Sep 2016 09:29:09 +0000 (11:29 +0200)]
eve-drop: allow logging all drops
- drop:
alerts: yes # log alerts that caused drops
flows: all # start or all: 'start' logs only a single drop
# per flow direction. All logs each dropped pkt.
Victor Julien [Tue, 6 Sep 2016 08:29:57 +0000 (10:29 +0200)]
dns: use nonnull attr for log functions
Victor Julien [Tue, 6 Sep 2016 08:20:38 +0000 (10:20 +0200)]
dns: fix coverity warning
** CID
1372324 : Null pointer dereferences (FORWARD_NULL)
/src/output-json-dns.c: 532 in OutputAnswer()
________________________________________________________________________________________________________
*** CID
1372324 : Null pointer dereferences (FORWARD_NULL)
/src/output-json-dns.c: 532 in OutputAnswer()
526 }
527 }
528
529 /* reset */
530 MemBufferReset(aft->buffer);
531 json_object_set_new(djs, "dns", js);
>>> CID
1372324 : Null pointer dereferences (FORWARD_NULL)
>>> Dereferencing null pointer "entry".
532 if (likely(DNSRRTypeEnabled(entry->type, aft->dnslog_ctx->flags))) {
533 OutputJSONBuffer(djs, aft->dnslog_ctx->file_ctx, &aft->buffer);
534 }
535 json_object_del(djs, "dns");
536
537 return;
Move checks to the top of the functions. Should be more efficient too.
Victor Julien [Fri, 2 Sep 2016 10:47:11 +0000 (12:47 +0200)]
detect-template: modernize
Jason Ish [Wed, 31 Aug 2016 14:24:08 +0000 (08:24 -0600)]
app-layer templates: cleanups
- cleanup file headers
- add todo section
- convert unit tests to new macros
- add markers to remove disabled by default behaviour
Jason Ish [Mon, 5 Sep 2016 14:15:46 +0000 (08:15 -0600)]
decode-icmpv6: use FAIL macros in tests
Jason Ish [Mon, 5 Sep 2016 14:15:26 +0000 (08:15 -0600)]
unittest: FAIL macro to unconditionally fail a test
Jason Ish [Mon, 5 Sep 2016 13:41:33 +0000 (07:41 -0600)]
icmpv6: fix checksum verification if fcs present
Calculate the length of the ICMPv6 packet from decoded information
instead of off the wire length. This will provide the correct
length if trailing data like an FCS is present.
Fixes issue:
https://redmine.openinfosecfoundation.org/issues/1849
Victor Julien [Mon, 5 Sep 2016 08:17:40 +0000 (10:17 +0200)]
affinity: fix compilation on SunOS
Victor Julien [Mon, 5 Sep 2016 08:17:16 +0000 (10:17 +0200)]
byteswap: fix compilation on SunOS
Victor Julien [Mon, 5 Sep 2016 08:16:30 +0000 (10:16 +0200)]
configure: detect SunOS and link against required libs
Victor Julien [Mon, 5 Sep 2016 08:15:52 +0000 (10:15 +0200)]
threads: provide SCGetThreadIdLong for SunOS
Victor Julien [Mon, 5 Sep 2016 08:15:23 +0000 (10:15 +0200)]
decode: declare IPPROTO_IPIP if OS doesn't have it
Victor Julien [Mon, 5 Sep 2016 08:14:52 +0000 (10:14 +0200)]
decode: fix int types
Victor Julien [Mon, 5 Sep 2016 08:14:04 +0000 (10:14 +0200)]
configure: check for strings.h: used by SunOS
Victor Julien [Mon, 5 Sep 2016 08:12:54 +0000 (10:12 +0200)]
logfile: resolve name clash on SunOS
Victor Julien [Thu, 1 Sep 2016 18:34:26 +0000 (20:34 +0200)]
eve: reduce flow_id to 51 bits
Evebox & ELK couldn't handle the large integers. It looks like (partly)
a javascript limitation that doesn't treat 64bit ints as real ints.
Victor Julien [Thu, 1 Sep 2016 09:13:48 +0000 (11:13 +0200)]
configure: fix Ubuntu lua pkg suggestion
Victor Julien [Wed, 31 Aug 2016 13:08:58 +0000 (15:08 +0200)]
eve: output more unique flow_id
Victor Julien [Wed, 31 Aug 2016 13:04:58 +0000 (15:04 +0200)]
flow: introduce function to generate flow id
The flow id itself is not stored in the flow, but generated based on
properties that do not change during the lifetime of the flow.
As it's meant for use with the json output, it is limited to a signed
64 bit integer (int64_t) because that is the time json_integer_t uses.
Victor Julien [Tue, 30 Aug 2016 19:44:44 +0000 (21:44 +0200)]
detect: implement continue detect for dcepayload
Also fix a corner case in start detection.
Bug 1853.
Victor Julien [Tue, 30 Aug 2016 18:54:35 +0000 (20:54 +0200)]
detect: cleanup
Victor Julien [Tue, 30 Aug 2016 17:35:18 +0000 (19:35 +0200)]
detect: fix ICMP error handling issue
The first packet in both directions of a flow looks up the rule group
(sgh) and stores it in the flow. This makes sure the lookup doesn't
have to be performed for each packet.
ICMPv4 error messages are connected to the TCP or UDP flow they apply
to. In the case of such an ICMP error being the first packet in a
flow's direction, this would lead to an issue.
The packet would look up the rule group based on the ICMP protocol,
not based on the embedded TCP/UDP. This makes sense, as the ICMP
packet is inspected as ICMP packet. The consequence however, was that
this rule group pointer (sgh) would be stored in the flow. This is
wrong, as TCP/UDP packets that follow the ICMP packet would have no sgh
or the wrong sgh.
In normal traffic this shouldn't normally happen, but it could be
used to evade Suricata's inspection.
Victor Julien [Mon, 29 Aug 2016 11:17:31 +0000 (13:17 +0200)]
output dns: fix bit declarations
Victor Julien [Mon, 29 Aug 2016 11:14:51 +0000 (13:14 +0200)]
common: introduce macro for bit declarations
Tom DeCanio [Thu, 4 Feb 2016 20:19:14 +0000 (12:19 -0800)]
output-json-dns: dns output filtering.
Jason Ish [Tue, 23 Aug 2016 17:37:42 +0000 (11:37 -0600)]
eve: make logging of tagged packets optional
But it is enabled in the default configuration.
Jason Ish [Mon, 1 Aug 2016 20:01:49 +0000 (14:01 -0600)]
eve: log tag packets as packet events
Create a new eve event type, "packet" for logging packets that
are tagged as part of an event. The packet is still at the top
level to keep it consistent with alert event types.
In addition to the packet being logged, a packet_info object
is created to hold the linktype and any future meta data
we may want to add about the packet.
Victor Julien [Thu, 14 Jul 2016 10:11:02 +0000 (12:11 +0200)]
detect: minor cleanup
Victor Julien [Fri, 19 Aug 2016 11:58:07 +0000 (13:58 +0200)]
detect: minor style fixes
Victor Julien [Fri, 19 Aug 2016 10:58:33 +0000 (12:58 +0200)]
detect: minor debug output cleanup
Victor Julien [Thu, 18 Aug 2016 07:39:48 +0000 (09:39 +0200)]
detect: remove unused debug code
Victor Julien [Mon, 18 Jul 2016 08:50:29 +0000 (10:50 +0200)]
detect: minor cleanups
Victor Julien [Fri, 6 May 2016 17:44:54 +0000 (19:44 +0200)]
stream-tcp: fix ssn returning to wrong thread pool