[Oisf-devel] [PATCH 0/2] ligthen Packet structure
Eric Leblond
eleblond at edenwall.com
Sun Nov 21 21:22:41 UTC 2010
Hi,
I've discovered some problem with this patchset during more extensive
testing. I will fix this and resend the patchset.
BR,
Le samedi 20 novembre 2010 à 18:57 +0100, Eric Leblond a écrit :
> Hi,
>
> This patchset is a heavily modified version of the previous patchset. I've
> followed Robert Kerr suggestion to have a configurable preallocated packet
> size. The 'default-packet-size' variable can now be put in suricata.yaml
> to define the preallocated size for each packets. If not set, 1514 is used
> as default.
>
> To do so, I've modified the Packet allocation to allocate enough place for
> the structure by itself but also for the packet data. The data are written
> after the Packet structure and the pkt member is now a pointer to that
> space.
>
> The modification was quiet easy and the main point was to fix the unittest
> which are now working (Defrag tests have been tested with different packet
> size).
>
> I've also modified the patch following your latest suggestion (no ip6h
> mobility).
>
> My main question about this patchset is that the modifications are simple
> in most cases but they involve a lot of codes (see patchset statistics
> below). I was not able to find an easy way to split things.
>
> Patchset statistics:
> src/alert-debuglog.c | 12 ++--
> src/alert-fastlog.c | 2 +-
> src/alert-unified-log.c | 8 +-
> src/alert-unified2-alert.c | 20 +++---
> src/app-layer-detect-proto.c | 4 +-
> src/cuda-packet-batcher.c | 4 +-
> src/decode-ethernet.c | 2 +-
> src/decode-gre.c | 14 ++--
> src/decode-icmpv4.c | 12 ++--
> src/decode-icmpv6.c | 26 +++---
> src/decode-ipv4.c | 66 ++++++++--------
> src/decode-ipv6.c | 2 +-
> src/decode-ppp.c | 8 +-
> src/decode-pppoe.c | 10 +-
> src/decode-raw.c | 22 +++---
> src/decode-tcp.c | 6 +-
> src/decode-vlan.c | 6 +-
> src/decode.c | 58 ++++++++++++++-
> src/decode.h | 27 ++++++-
> src/defrag.c | 167 ++++++++++++++++++++++++-----------------
> src/detect-bytetest.c | 6 +-
> src/detect-content.c | 2 +-
> src/detect-decode-event.c | 2 +-
> src/detect-dsize.c | 2 +-
> src/detect-engine-tag.c | 6 +-
> src/detect-flags.c | 20 +++---
> src/detect-flowbits.c | 6 +-
> src/detect-flowint.c | 6 +-
> src/detect-fragbits.c | 4 +-
> src/detect-fragoffset.c | 2 +-
> src/detect-icmp-id.c | 2 +-
> src/detect-ipopts.c | 4 +-
> src/detect-stream_size.c | 4 +-
> src/detect.c | 104 ++++++++++++++------------
> src/flow.c | 2 +-
> src/source-erf-dag.c | 21 +++---
> src/source-erf-file.c | 16 ++--
> src/source-ipfw.c | 28 ++++----
> src/source-nfq.c | 29 ++++---
> src/source-pcap-file.c | 18 ++--
> src/source-pcap.c | 26 ++++---
> src/source-pfring.c | 16 ++--
> src/stream-tcp.c | 64 ++++++++--------
> src/suricata.c | 12 ++-
> src/tmqh-packetpool.c | 11 +++
> src/util-mpm-b2g-cuda.c | 10 +-
> src/util-unittest-helper.c | 25 +++---
> suricata.yaml | 5 +
> 48 files changed, 533 insertions(+), 396 deletions(-)
>
> BR,
> --
> Eric Leblond <eleblond at edenwall.com>
> _______________________________________________
> Oisf-devel mailing list
> Oisf-devel at openinfosecfoundation.org
> http://lists.openinfosecfoundation.org/mailman/listinfo/oisf-devel
More information about the Oisf-devel
mailing list