Suricata is a network Intrusion Detection System, Intrusion Prevention System and Network Security Monitoring engine developed by the OISF and the Suricata community.
You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
Go to file
Ken Steele b076a26cdc Replace ReleaseData function on Packet Structure with ReleasePacket.
This commit allows handling Packets allocated by different methods.
The ReleaseData function pointer in the Packet structure is replaced
with ReleasePacket function pointer, which is then always called to
release the memory associated with a Packet.

Currently, the only usage of ReleaseData is in AF Packet. Previously
ReleaseData was only called when it was not NULL. To implement the
same functionality as before in AF Packet, a new function is defined
in AF Packet to first call the AFP specific ReleaseData function and
then releases the Packet structure.

Three new general functions are defined for releasing packets in the
default case:
    1) PacketFree() - To release a packet alloced with SCMalloc()
    2) PacketPoolReturnPacket() - For packets allocated from the Packet Pool.
                                  Calls RECYCLE_PACKET(p)
    3) PacketFreeOrRelease() - Calls PacketFree() or PacketPoolReturnPacket()
                                 based on the PKT_ALLOC flag.

Having these functions removes the need to check the PKT_ALLOC flag
when releasing a packet in most cases, since the ReleasePacket
function encodes how the Packet was allocated. The PKT_ALLOC flag is
still set and is needed when AF Packet releases a packet, since it
replaces the ReleasePacket function pointer with its own function and
then calls PacketFreeOfRelease(), which uses the PKT_ALLOC flag.
13 years ago
benches Initial add of the files. 17 years ago
contrib Add one shot run option to suri-graphite. 13 years ago
doc Update docs from wiki 14 years ago
m4 Prelude plugin: add detection in configure script 17 years ago
qa coccinelle: dynamic testing through make check 13 years ago
rules DNS: rename dns.rules to dns-events.rules, include it in yaml 13 years ago
scripts suricatasc: fix make distcheck. 14 years ago
src Replace ReleaseData function on Packet Structure with ReleasePacket. 13 years ago
.gitignore add configure summary to build-info output 14 years ago
COPYING Initial add of the files. 17 years ago
ChangeLog Update changelog for 2.0beta1 13 years ago
LICENSE import of gplv2 LICENSE 17 years ago
Makefile.am autotools: workaround on partial cleaning 13 years ago
Makefile.cvs Initial add of the files. 17 years ago
acsite.m4 Added C99 defs/macros to acsite.m4 for CentOS 17 years ago
autogen.sh OpenBSD 5.2 build fixes, Unit test fix. 14 years ago
classification.config Import of classification.config 17 years ago
config.rpath Add file needed for some autotools version. 13 years ago
configure.ac fix for #875. 13 years ago
doxygen.cfg Adding an updated doxygen config file, because the old one was created a couple major versions ago. 13 years ago
mkinstalldirs Update autojunk.sh + build update. 17 years ago
reference.config Add md5 to reference.config. 15 years ago
suricata.yaml.in Suricata upgrade to libhtp 0.5.x. 13 years ago
threshold.config threshold: improve comments of shipped threshold.config, add links to wiki. 14 years ago