Project

General

Profile

Actions

Bug #1090

closed

FTP: Memory Leak

Added by Jack Flemming about 10 years ago. Updated about 10 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Target version:
Affected Versions:
Effort:
Difficulty:
Label:

Description

Version: Pulled from Github 1/26/2014. Advertised version is "Suricata 2.0dev (rev a77b9b3)"
Issue: Valgrind reports a memory leak in FTP

==24098== 11 bytes in 1 blocks are definitely lost in loss record 149 of 562
==24098==    at 0x4C2CD7B: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==24098==    by 0x42DA72: FTPGetLineForDirection (app-layer-ftp.c:80)
==24098==    by 0x42E90F: FTPGetLine (app-layer-ftp.c:168)
==24098==    by 0x42EE76: FTPParseRequest (app-layer-ftp.c:226)
==24098==    by 0x44418A: AppLayerParserParse (app-layer-parser.c:778)
==24098==    by 0x416837: AppLayerHandleTCPData (app-layer.c:360)
==24098==    by 0x5AB418: StreamTcpReassembleAppLayer (stream-tcp-reassemble.c:3027)
==24098==    by 0x5ABCB7: StreamTcpReassembleHandleSegmentUpdateACK (stream-tcp-reassemble.c:3373)
==24098==    by 0x5ABD59: StreamTcpReassembleHandleSegment (stream-tcp-reassemble.c:3401)
==24098==    by 0x59C49D: StreamTcpHandleFin (stream-tcp.c:2457)
==24098==    by 0x59BB2F: StreamTcpPacketStateEstablished (stream-tcp.c:2234)
==24098==    by 0x5A1C77: StreamTcpPacket (stream-tcp.c:4242)

How to recreate:
1. Make an unoptimized build of HTP / Suricata
2. Run like so:

valgrind --leak-check=full --trace-children=yes ./src/suricata -c ./suricata.yaml -r <attached pcap> -k none --runmode single -l ./output/


Files

ftp_bug.pcap (957 Bytes) ftp_bug.pcap Jack Flemming, 01/27/2014 07:48 AM
Actions #1

Updated by Victor Julien about 10 years ago

Thanks Jack, these are very useful reports. Keep 'm coming :)

Actions #2

Updated by Victor Julien about 10 years ago

  • Target version changed from 2.0rc1 to 2.0rc2
Actions #3

Updated by Victor Julien about 10 years ago

  • Assignee set to Victor Julien
Actions #4

Updated by Victor Julien about 10 years ago

  • Status changed from New to Closed
  • % Done changed from 0 to 100
Actions

Also available in: Atom PDF