Commit Graph

4046 Commits (48cf0585fb69c9bad712377d82796e191e24af47)
 

Author SHA1 Message Date
Anoop Saldanha 48cf0585fb Suricata upgrade to libhtp 0.5.x.
Remove the support for now unsupported personalities from libhtp -
TOMCAT_6_0, APACHE and APACHE_2_2.  We instead use the APACHE_2
personality.
12 years ago
Victor Julien 080c15b3fc Enable libhtp 0.3.0 compilation and crash free UT run. Still see 5 failed tests. 12 years ago
Victor Julien 538da26812 Fix sgh mpm flags assignment 12 years ago
Eric Leblond 150cd39c6e detect-engine: do a direct update of flag
There is no reason not to update the flag directly. So do it
to avoid to crash the test.
12 years ago
Eric Leblond 9212ff7e59 coccinelle: dynamic testing through make check
This patch modify build system to have make to create the
struct-flags.cocci file by running struct-flags.py.

This way 'make check' is running the test defined from source
code.
12 years ago
Eric Leblond e05fd7f1d0 coccinelle: add script to generate flags test
This patch adds a script which can be used to generate a test
on coherence of flag usage.

By adding comment in the code, it is possible to declare that we
link a flag in a structure to a specific family of constant:

For example:
	/* coccinelle: Packet:flowflags:FLOW_PKT_ */
will trigger the generation on a test which verifies that the
flowflags field in Packet structure is only used with constant
starting by FLOW_PKT_.
12 years ago
Eric Leblond 2f2916d9ec ccccinelle: add formatted comment for flag test 12 years ago
Victor Julien 4749420f32 Use relative dir instead of ac_builddir
When generating src/build-info.h the use of ac_builddir was problematic.
There were several cases where it was undefined leading to the absolute
path /src/build-info.h. ./configure should be called from the parent dir
to the actual src dir, so this should work. Make distcheck and normal builds
complete fine.
12 years ago
Victor Julien aafc65c757 Autotools: move libhtp conditionals to configure
In preparation of the libhtp upgrade, move all libhtp related conditionals
to configure. This allows for one set of build scripts that works regardless
of the presence of a local libhtp dir.
12 years ago
Victor Julien 73e27c1fb7 Generate proper errors if sid,gid,rev values are out of range. Bug #779. 12 years ago
Victor Julien 164d60e8cd Yaml: give a more detailed error if the user supplies a directory instead of a yaml file. Bug #803. 12 years ago
Victor Julien 55625d738a TLS: create certs dir on 'make install-full'. Bug #711. 12 years ago
Victor Julien a4e838c1d3 TLS: create certs directory during startup if it doesn't exist yet. Bug #710. 12 years ago
Victor Julien 2b5d586dbc TLS: add missing options to shipped yaml. Bug #709. 12 years ago
Victor Julien 6229bfab5e DNS: rename dns.rules to dns-events.rules, include it in yaml 12 years ago
Eric Leblond 0e92469222 nfq: be sure to always verdict packets
To be sure to always verdict packets (bug #769), this patch adds
a ReleaseData function to NFQ packets. The release function simply
drop the packet if it has not been verdicted before.
12 years ago
Victor Julien 4a0050b9ea Print pkt src to alert-debug log 12 years ago
Victor Julien 1c371da46d DNS: better handle TX' with lost replies 12 years ago
Victor Julien 0fd9b0c4fa HTP: free TX from transaction free API call 12 years ago
Victor Julien 1367074c75 App layer: clean up TX before lowest active one
Update DNS to handle cleaning up this way.
12 years ago
Victor Julien 0b229ec8b9 DNS: suppress log-dns registration message 12 years ago
Victor Julien f59f90331d Applayer: remove obsolete StateUpdateTransactionId
Also, update StateTransactionFree to take an u64 tx id, so it's
consistant with the rest of the engine.

To reflect these changes, AppLayerRegisterTransactionIdFuncs has
been renamed to AppLayerRegisterTxFreeFunc.

HTP, DNS, SMB, DCERPC parsers updated.
12 years ago
Victor Julien ebab9aee83 DNS: move internal tx id tracking to u64 12 years ago
Victor Julien e8ad876b48 App layer: add 'StateHasEvents' API call
Per TX decoder events resulted in significant overhead to the
detection engine, as it walked all TX' all the time to check
if decoder events were available.

This commit introduces a new API call StateHasEvents, which speeds
up this process, at the expense of keeping a counter in the state.

Implement this for DNS as well.
12 years ago
Anoop Saldanha cd7b4fac40 remove unused pattern id assignment functions. Goodbye 12 years ago
Anoop Saldanha 68847d12e3 Update configure.ac to use the default value of 64 for the cache line size
for systems which return a value of 0.
12 years ago
Victor Julien f353fb630c DNS: convert dns_query to sticky buffer 12 years ago
Victor Julien 7292998a58 Content: set up sticky buffers like file_data and dce_stub_data w/o flags, but with a list variable 12 years ago
Victor Julien d476e4e50d Coverity 1040312, 1040313, 1040314 1040315: improve pool thread error handling. 12 years ago
Victor Julien 1373a20e8a Thread: remove thread id 12 years ago
Victor Julien d7aaa9464c Stream: use per thread ssn_pool_id instead of thread id. 12 years ago
Victor Julien 92b7ffad69 Improve memory cleanup in some unittests 12 years ago
Victor Julien fd7899cc8b Stream: fix unittests after ssn pool changes. 12 years ago
Victor Julien aa449d51ca Stream: use per thread ssn pool
Use per thread pools to store and retrieve SSN's from. Uses PoolThread
API.

Remove max-sessions setting. Pools are set to unlimited, but TCP memcap
limits the amount of sessions.

The prealloc_session settings now applies to each thread, so lowered the
default from 32k to 2k.
12 years ago
Victor Julien b6af6cb241 pool: add error msgs and improve memory layout 12 years ago
Victor Julien 5b9ef94f34 pool: add api for per thread pools
This API is a wrapper around the regular pools where the thread pools
are arrays of locks+pools.
12 years ago
Victor Julien 016d03bdaf pool: add error msgs and improve memory layout 12 years ago
Victor Julien 46af6b7e0f Add a per threadvars thread local thread id, that starts at 0 and increments for each thread. 12 years ago
Victor Julien b3b554c269 Coverity 1038959: DNS mpm might use initialized variable 12 years ago
Anoop Saldanha fba95e9125 Remove mpm ctxs in the wrong direction.
A lot of http mpm ctxs have now been removed as a result of this.
12 years ago
Anoop Saldanha 3c2ddf04c1 Update mpm init ctx to not accept the final cuda_rc_module argument.
It was a part of our older architecture and is no longer used.
12 years ago
Victor Julien 33818c0272 DNS: fix CUDA build 12 years ago
Victor Julien be7e6cdd7a DNS: fix warning when debug is not enabled 12 years ago
Victor Julien 16edbfd4ea DNS: disable logging by default 12 years ago
Victor Julien 571b8ac186 DNS: add support for per TX decoder events. 12 years ago
Victor Julien 9dc04d9fab app layer: add support for per TX decoder events 12 years ago
Victor Julien 72e35efbc6 Reset app layer events when we start inspecting a new TX 12 years ago
Victor Julien 28a6c1d9f8 DNS: add test for app layer event match 12 years ago
Victor Julien 6645620c03 Merge SIG_FLAG_MPM_HTTP and SIG_FLAG_MPM_DNS into SIG_FLAG_MPM_APPLAYER, do the same for the _NEG variant. 12 years ago
Victor Julien 43ba5a677e DNS: enable mpm/fast_pattern support for dns_query 12 years ago