]>
git.ipfire.org Git - thirdparty/suricata.git/log
Victor Julien [Wed, 27 May 2015 12:29:54 +0000 (14:29 +0200)]
counters: use ptr to name instead of copy
All counters have hardcoded names, so copies are not needed.
Victor Julien [Wed, 27 May 2015 12:11:57 +0000 (14:11 +0200)]
counters: don't run if no counters have been registered
Victor Julien [Wed, 27 May 2015 09:33:41 +0000 (11:33 +0200)]
counters: work around unix-socket init issues
Victor Julien [Wed, 27 May 2015 09:23:19 +0000 (11:23 +0200)]
counters: make threads cleanup all memory
Victor Julien [Wed, 27 May 2015 07:28:24 +0000 (09:28 +0200)]
counters: clean up global context
Victor Julien [Tue, 26 May 2015 17:44:01 +0000 (19:44 +0200)]
counters: turn flow.memuse into a global counter
Victor Julien [Tue, 26 May 2015 17:36:59 +0000 (19:36 +0200)]
counters: make DNS counters globals
Victor Julien [Tue, 26 May 2015 17:16:23 +0000 (19:16 +0200)]
counters: make tcp.memuse a global counter
Victor Julien [Thu, 8 Jan 2015 00:44:18 +0000 (01:44 +0100)]
http: make http.memuse a global counter
http.memcap as well.
Victor Julien [Tue, 26 May 2015 14:45:07 +0000 (16:45 +0200)]
counters: remove references to 'perf' counters
Victor Julien [Tue, 26 May 2015 14:33:51 +0000 (16:33 +0200)]
counters: remove last and now unused tm_name reference
Victor Julien [Tue, 26 May 2015 14:29:35 +0000 (16:29 +0200)]
counters: remove old unix socket json logic
Victor Julien [Tue, 26 May 2015 14:28:01 +0000 (16:28 +0200)]
counters: minor internal API cleanups
Victor Julien [Tue, 26 May 2015 14:24:39 +0000 (16:24 +0200)]
counters: rename unparsable SCPCAElem to StatsLocalCounter
Victor Julien [Tue, 26 May 2015 14:15:03 +0000 (16:15 +0200)]
counters: minor header cleanup
Victor Julien [Tue, 26 May 2015 14:10:17 +0000 (16:10 +0200)]
counters: remaining s/SCPerf/Stats/g
Victor Julien [Tue, 26 May 2015 14:04:30 +0000 (16:04 +0200)]
counters: s/SCPerfPrivateContext/StatsPrivateThreadContext/g
Victor Julien [Tue, 26 May 2015 14:01:09 +0000 (16:01 +0200)]
counters: s/SCPerfPublicContext/StatsPublicThreadContext/g
Victor Julien [Tue, 26 May 2015 13:41:35 +0000 (15:41 +0200)]
counters: various renames and cleanups
Victor Julien [Tue, 26 May 2015 13:08:35 +0000 (15:08 +0200)]
counters: s/SCPerfCounterSetUI64/StatsSetUI64/g
Victor Julien [Tue, 26 May 2015 12:53:24 +0000 (14:53 +0200)]
counters: s/SCPerfCounterIncr/StatsIncr/g
Victor Julien [Tue, 26 May 2015 12:45:43 +0000 (14:45 +0200)]
counters: s/SCPerfCounterAddUI64/StatsAddUI64/g
Victor Julien [Tue, 26 May 2015 12:38:02 +0000 (14:38 +0200)]
counters: clean up defines
Victor Julien [Tue, 26 May 2015 12:33:21 +0000 (14:33 +0200)]
counters: rename register API calls
Also remove 'type' parameter which was always the same.
Victor Julien [Tue, 26 May 2015 11:51:38 +0000 (13:51 +0200)]
log-stats: make global/threads logging configurable
Victor Julien [Tue, 26 May 2015 10:00:36 +0000 (12:00 +0200)]
stats: support per thread stats in json output
Default is only to output totals. Optionally per thread can be added.
Both can be enabled together.
Victor Julien [Tue, 4 Nov 2014 09:07:25 +0000 (10:07 +0100)]
stats json: replace strndup
strndup is a banned function.
Victor Julien [Tue, 4 Nov 2014 08:50:29 +0000 (09:50 +0100)]
stats-json: fixes and improvements
Use proper LogFileCtx and MemBuffer handling so we can have multiple
loggers active at the same time.
Change 'date' field to timestamp, and use ISO notation to make it
the same as the other JSON outputs.
Tom DeCanio [Tue, 4 Nov 2014 01:16:46 +0000 (17:16 -0800)]
eve-log: stats logging code cleanup.
Tom DeCanio [Tue, 4 Nov 2014 01:01:59 +0000 (17:01 -0800)]
eve-log: add JSON stats logging
Support for counters in stats.log in eve output JSON stream.
Victor Julien [Mon, 25 May 2015 18:53:17 +0000 (20:53 +0200)]
counters: pass per thread stats to output api
As well as the global (merged) stats.
Victor Julien [Mon, 25 May 2015 11:46:19 +0000 (13:46 +0200)]
counters: rename widely used pctmi var to sts (stats thread store)
Victor Julien [Mon, 25 May 2015 09:42:41 +0000 (11:42 +0200)]
counters: call global counters funcs
Victor Julien [Mon, 25 May 2015 09:40:42 +0000 (11:40 +0200)]
counters: split API init
Split into early ctx initialization and post-config setup.
Victor Julien [Sun, 24 May 2015 18:18:02 +0000 (20:18 +0200)]
counters: start using Stats prefix
Victor Julien [Sun, 24 May 2015 16:38:39 +0000 (18:38 +0200)]
counters: simplify and speedup counters sync
Victor Julien [Sun, 24 May 2015 16:32:58 +0000 (18:32 +0200)]
counters: remove threadvars arg from SCPerfAddToClubbedTMTable
Victor Julien [Sun, 24 May 2015 15:58:13 +0000 (17:58 +0200)]
counters: remove thread module name from counters API
Victor Julien [Wed, 7 Jan 2015 22:00:52 +0000 (23:00 +0100)]
stream: make tcp.reassembly_memuse counter global
Fixes bugs #632 and #1178
Victor Julien [Sun, 24 May 2015 15:23:48 +0000 (17:23 +0200)]
counters: global counters registration
Victor Julien [Wed, 7 Jan 2015 18:57:18 +0000 (19:57 +0100)]
Fix harmless typo in IPOnlyCIDRItemNew's SCReturnPtr use
Victor Julien [Sun, 24 May 2015 12:04:45 +0000 (14:04 +0200)]
counters: remove unused description
Victor Julien [Sun, 24 May 2015 07:04:04 +0000 (09:04 +0200)]
counters: merge counters from threads for output
Merge counters so the table contains combined values from counters
from each thread.
Use global counter id's, track them in a hash.
Rename SCPCAElem members
Fix and improve average counters
Victor Julien [Sat, 23 May 2015 12:16:21 +0000 (14:16 +0200)]
counters: remove unused public API calls and make them private
Victor Julien [Sat, 23 May 2015 11:41:49 +0000 (13:41 +0200)]
counters: make SCPerfSetupPrivate a function
Victor Julien [Sat, 23 May 2015 11:27:41 +0000 (13:27 +0200)]
counters: minor cleanups
Victor Julien [Sat, 23 May 2015 11:24:08 +0000 (13:24 +0200)]
counters: introduce SCPerfSetupPrivate for thread setup
Victor Julien [Sat, 23 May 2015 10:56:16 +0000 (12:56 +0200)]
counters: make threadvars::perf_private_ctx static
Update SCPerfGetAllCountersArray and add a UT workaround.
Victor Julien [Sat, 23 May 2015 10:28:54 +0000 (12:28 +0200)]
counters: SCPerfGetLocalCounterValue cleanup
Return u64, update arguments.
Victor Julien [Sat, 23 May 2015 10:15:10 +0000 (12:15 +0200)]
counters: remove references to SCPerfCounterAddDouble
They were all in comments anyway.
Victor Julien [Fri, 22 May 2015 22:44:45 +0000 (00:44 +0200)]
counters: make increment call take threadvars
This hides the implementation from the caller.
Victor Julien [Fri, 22 May 2015 18:56:09 +0000 (20:56 +0200)]
counters: threadvars s/sc_perf_pca/perf_private_ctx/g
Victor Julien [Fri, 22 May 2015 17:59:35 +0000 (19:59 +0200)]
counters: rename threadvars public counters
Victor Julien [Fri, 22 May 2015 15:04:17 +0000 (17:04 +0200)]
counters: s/SCPerfContext/SCPerfPublicContext/g
Victor Julien [Fri, 22 May 2015 14:59:07 +0000 (16:59 +0200)]
counters: s/SCPerfCounterArray/SCPerfPrivateContext/g
Goal is to make it's purpose clear.
Victor Julien [Fri, 22 May 2015 12:16:10 +0000 (14:16 +0200)]
counters: minor cleanups
Eric Leblond [Wed, 20 May 2015 19:45:25 +0000 (21:45 +0200)]
suri-graphite: add ouput to file option
The --ooutput option allows to write the stats to a file given as
argument the format used is JSON for easy parsing.
Eric Leblond [Sun, 17 May 2015 17:02:37 +0000 (19:02 +0200)]
suri-graphite: add daemonization capability
You can now use -d or --daemon to daemonize the process.
Eric Leblond [Sun, 17 May 2015 16:57:48 +0000 (18:57 +0200)]
suri-graphite: fix port option
If port is specified on command line we need to convert it as an
integer before using it as argument to connect.
Victor Julien [Fri, 22 May 2015 12:23:18 +0000 (14:23 +0200)]
logfile: rename ALERT_ types to LOGFILE_TYPE_
Eric Leblond [Wed, 20 May 2015 11:40:01 +0000 (13:40 +0200)]
output-json: suppress global variable
It uses the new type field in the LogFileCtx instead.
This fixes the problem of not being able to use two eve-json
instance with different logging methods.
Eric Leblond [Wed, 20 May 2015 11:38:10 +0000 (13:38 +0200)]
log file: add type flag
It will be used to store if the file is syslog or a real file.
Eric Leblond [Sat, 7 Feb 2015 10:36:37 +0000 (11:36 +0100)]
suricata.yaml: fix the name of EVE module
It is netflow and not newflow.
Eric Leblond [Sat, 7 Feb 2015 00:58:28 +0000 (01:58 +0100)]
output-json: fix type of data parameter
The cast of data to AlertJsonThread was not correct as the real
type of the void pointer is a OutputJsonCtx. This was working by
luck because they both have a file_ctx as first element.
Alexander Gozman [Wed, 13 May 2015 18:18:43 +0000 (21:18 +0300)]
Feature #1440: support wildcards in rule filenames
David Cannings [Mon, 11 May 2015 20:51:38 +0000 (21:51 +0100)]
Fix rcode parsing, as noticed by Coverity.
Without support for OPT RR from RFC6891 (Extension mechanisms for DNS)
values of RCODE above 15 are not possible. Remove dead code which will
never match.
Jason Ish [Mon, 11 May 2015 22:50:19 +0000 (16:50 -0600)]
conf - process includes even if not at root node.
Jason Ish [Mon, 11 May 2015 16:20:25 +0000 (10:20 -0600)]
radix-tree - prevent out of bounds array access
An IPv6 entry specified before an IPv4 entry on the host-os-policy
table can cause the stream byte array to be access one byte after
the end of the allocated memory at util-radix-tree.c:578.
Jason Ish [Fri, 2 Jan 2015 21:30:30 +0000 (15:30 -0600)]
Bug 1281 - Add tests for rule content of lengths > 255.
Jason Ish [Mon, 27 Oct 2014 17:36:26 +0000 (11:36 -0600)]
Bug 1281 - Accept rule content with lengths greater than 255.
Victor Julien [Tue, 19 May 2015 13:54:41 +0000 (15:54 +0200)]
alert-json: fix stream logging for IPS mode
Switch direction in IPS mode.
Victor Julien [Mon, 18 May 2015 16:05:11 +0000 (18:05 +0200)]
threads: add untimed control cond call
The control conditions so far could only do timed waits, not normal
waits.
Victor Julien [Wed, 13 May 2015 12:26:13 +0000 (14:26 +0200)]
detect: minor cleanups
Victor Julien [Wed, 13 May 2015 12:25:49 +0000 (14:25 +0200)]
parsing: s/strtok/strtok_r/g
Remove all strtok uses and replace them by strtok_r.
Do the same for Windows builds. Cygwin builds fine with strtok_r.
Add strtok to banned function list.
Victor Julien [Thu, 14 May 2015 08:38:58 +0000 (10:38 +0200)]
threading: explain purpose of threadvars mucond
Victor Julien [Thu, 14 May 2015 08:38:10 +0000 (10:38 +0200)]
flow: don't hold tv_root_lock longer than needed
Don't hold it longer than needed in shutting down.
Victor Julien [Thu, 14 May 2015 08:17:16 +0000 (10:17 +0200)]
threading: remove unused cmd thread create func
Victor Julien [Wed, 13 May 2015 14:52:11 +0000 (16:52 +0200)]
unix-manager: convert to thread module
Sync command thread for unix manager with other managers and make
it a full thread module.
Victor Julien [Wed, 13 May 2015 08:21:20 +0000 (10:21 +0200)]
reference/classification: call global init for unittests
Victor Julien [Wed, 13 May 2015 07:53:49 +0000 (09:53 +0200)]
reference: update pcre globals use
Don't update globals each time we parse, but instead do it once at
startup.
Victor Julien [Wed, 13 May 2015 07:37:39 +0000 (09:37 +0200)]
classification: update pcre globals use
Don't update globals each time we parse, but instead do it once at
startup.
Victor Julien [Tue, 12 May 2015 14:53:02 +0000 (16:53 +0200)]
reference: remove global
Victor Julien [Tue, 12 May 2015 14:20:27 +0000 (16:20 +0200)]
classification: remove global from parsing
Parsing code used a 'fd' global. Remove this.
Victor Julien [Tue, 5 May 2015 17:43:33 +0000 (19:43 +0200)]
stream: fix --disable-detection reassembly issue
Due to an error at initialization, the stream engine would not disable
'raw' reassembly automatically when --disable-detection was used.
This lead to segments not getting cleared from the segment lists.
Victor Julien [Wed, 28 Jan 2015 12:07:19 +0000 (13:07 +0100)]
stream: remove FLOW_NO_APPLAYER_INSPECTION flag
Instead, intruduce StreamTcpDisableAppLayer to disable app layer
tracking and reassembly. StreamTcpAppLayerIsDisabled can be used
to check it.
Replace all uses of FlowSetSessionNoApplayerInspectionFlag and
the FLOW_NO_APPLAYER_INSPECTION.
Victor Julien [Wed, 28 Jan 2015 11:16:32 +0000 (12:16 +0100)]
stream: remove FLOW_NO_APPLAYER_INSPECTION use from tests
Victor Julien [Tue, 5 May 2015 15:48:18 +0000 (17:48 +0200)]
stream: improve 'no app layer' handling
When the session/flow was flagged as 'no applayer inspect', which
could happen as a result various reasons, packets would still be
considered by the app layer reassembly.
When ACK'd, they would be removed again. Depending also on the raw
reassembly.
In very long sessions however, this meganism could fail leading to
virtually endlessly growing segment lists.
This patch makes sure that segments that come in on a 'no app layer'
session are tagged properly or even not added at all.
Use a new ssn flag instead of flow flag for no app tracking.
Victor Julien [Wed, 28 Jan 2015 10:12:37 +0000 (11:12 +0100)]
app-layer: add DisableAppLayer
Move various app layer related flag setting calls into a utility
function "DisableAppLayer"
Victor Julien [Tue, 7 Apr 2015 14:00:08 +0000 (16:00 +0200)]
app-layer: de_state optimization
Add API to bypass expensive TX list walks. This API call is optional.
Implement it for HTTP and DNS.
Victor Julien [Wed, 25 Mar 2015 14:54:35 +0000 (15:54 +0100)]
detect-state: update test to check state storing
Victor Julien [Tue, 24 Mar 2015 14:36:39 +0000 (15:36 +0100)]
detect-state: handle duplicate inspect/match
If for a packet we have a TX N that has detect state and a TX N+1 that
has no detect state, but does have 'progress', we have a corner case
in stateful detection.
ContinueDetection inspects TX N, but cannot flag the rule in the
de_state_sig_array as the next (TX N+1) has already started and needs
to be inspected. 'StartDetection' however, is then unaware of the fact
that ContinueDetection already inspected the rule. It uses the per
session 'inspect_id' that is only moved forward at the end of the
detection run.
This patch adds a workaround. It uses the DetectEngineThreadCtx::
de_state_sig_array to store an offset between the 'base' inspect_id
and the inspect_id that StartDetection should use. The data type is
limited, so if the offset would be too big, a search based fall back
is implemented as well.
Victor Julien [Wed, 25 Mar 2015 08:19:49 +0000 (09:19 +0100)]
detect: add de_state duplication check
Add test to check if no duplicate destate is created.
Only enabled with DEBUG_VALIDATION.
Victor Julien [Tue, 24 Mar 2015 11:40:27 +0000 (12:40 +0100)]
detect-state: fix state storing
Fix storing state and bypassing detection. Previously we'd store
on a match only, meaning that StartDetection would rerun often.
Make sure StartDetection only stores if there is something to store.
Victor Julien [Tue, 24 Mar 2015 16:25:04 +0000 (17:25 +0100)]
detect-http-header: improve buffer handling
Previously we could never be calling DetectEngineHHDGetBufferForTX
for TX N and then afterwards for TX N - 1. Due to changes in the
stateful detection code this is now possible.
This patch changes the buffer logic to take the 'inspect_id' as it's
base, instead of the first transaction that we are called with.
Victor Julien [Wed, 12 Nov 2014 12:41:50 +0000 (13:41 +0100)]
detect-events: set SIG_MASK_REQUIRE_*_STATE for events
Set SIG_MASK_REQUIRE_*_STATE for event rules to earlier discard
them.
Victor Julien [Mon, 21 Jul 2014 19:09:06 +0000 (21:09 +0200)]
engine-analysis: print fast_pattern summary
When using engine analysis for print fast_pattern stats, print a
short summary at the end containing per buffer:
- smallest fp
- biggest fp
- number of patterns
- avg fp len
Victor Julien [Wed, 2 Jul 2014 11:16:28 +0000 (13:16 +0200)]
lua: fix error handling
Victor Julien [Sat, 18 Oct 2014 19:46:59 +0000 (21:46 +0200)]
http: add event for leading spaces on request line
Libhtp will issue a warning in this case, so we can match on this.
This patch adds event, rule and unittest.
Victor Julien [Fri, 16 Jan 2015 10:06:35 +0000 (11:06 +0100)]
threads: fix missing unlock in error handling
If TmThreadsUnregisterThread was called with out of range 'id', a lock
would not be cleared after returning from the function.
** CID
1264421 : Missing unlock (LOCK)
/src/tm-threads.c: 2186 in TmThreadsUnregisterThread()
Victor Julien [Fri, 8 May 2015 14:09:24 +0000 (16:09 +0200)]
Update changelog for 2.1beta4 release