Project

General

Profile

Actions

Bug #2961

closed

filestore: memory leaks

Added by Victor Julien over 5 years ago. Updated over 5 years ago.

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

Description

http test from: https://github.com/OISF/suricata-verify/pull/52

=================================================================
==26918==ERROR: LeakSanitizer: detected memory leaks

Direct leak of 24 byte(s) in 1 object(s) allocated from:
    #0 0x4eca27 in __interceptor_malloc (/home/victor/sync/devel/eidps/src/suricata+0x4eca27)
    #1 0x7fb13a8c6d9d in json_integer (/usr/lib/x86_64-linux-gnu/libjansson.so.4+0x8d9d)
    #2 0x18927af in OutputFilestoreFinalizeFiles /home/victor/devel/eidps/src/output-filestore.c:171:35
    #3 0x188e288 in OutputFilestoreLogger /home/victor/devel/eidps/src/output-filestore.c:267:9
    #4 0x1887c2e in CallLoggers /home/victor/devel/eidps/src/output-filedata.c:113:9
    #5 0x18871a2 in OutputFiledataLogFfc /home/victor/devel/eidps/src/output-filedata.c:192:37
    #6 0x188405e in OutputFiledataLog /home/victor/devel/eidps/src/output-filedata.c:238:5
    #7 0x187695a in OutputLoggerLog /home/victor/devel/eidps/src/output.c:920:13
    #8 0x17bb3f5 in FlowWorker /home/victor/devel/eidps/src/flow-worker.c:265:5
    #9 0x1df24b2 in TmThreadsSlotVarRun /home/victor/devel/eidps/src/tm-threads.c:130:17
    #10 0x1aac2a2 in TmThreadsSlotProcessPkt /home/victor/devel/eidps/src/./tm-threads.h:162:9
    #11 0x1aa8590 in PcapFileCallbackLoop /home/victor/devel/eidps/src/source-pcap-file-helper.c:101:9
    #12 0x7fb13b112d18  (/usr/lib/x86_64-linux-gnu/libpcap.so.0.8+0x1ed18)

SUMMARY: AddressSanitizer: 24 byte(s) leaked in 1 allocation(s).

smb test from: https://github.com/OISF/suricata-verify/pull/52

=================================================================
==6822==ERROR: LeakSanitizer: detected memory leaks

Direct leak of 96 byte(s) in 4 object(s) allocated from:
    #0 0x4eca27 in __interceptor_malloc (/home/victor/sync/devel/eidps/src/suricata+0x4eca27)
    #1 0x7fb99f471d9d in json_integer (/usr/lib/x86_64-linux-gnu/libjansson.so.4+0x8d9d)
    #2 0x18f4b3a in FileWriteJsonRecord /home/victor/devel/eidps/src/output-json-file.c:264:18
    #3 0x18f38e8 in JsonFileLogger /home/victor/devel/eidps/src/output-json-file.c:285:5
    #4 0x187e06a in OutputFileLogFfc /home/victor/devel/eidps/src/output-file.c:131:21
    #5 0x187c962 in OutputFileLog /home/victor/devel/eidps/src/output-file.c:179:5
    #6 0x187695a in OutputLoggerLog /home/victor/devel/eidps/src/output.c:920:13
    #7 0x17bb3f5 in FlowWorker /home/victor/devel/eidps/src/flow-worker.c:265:5
    #8 0x1df241a in TmThreadsSlotVarRun /home/victor/devel/eidps/src/tm-threads.c:128:17
    #9 0x1e08bff in TmThreadsSlotVar /home/victor/devel/eidps/src/tm-threads.c:583:17
    #10 0x7fb99f2516da in start_thread (/lib/x86_64-linux-gnu/libpthread.so.0+0x76da)

Direct leak of 96 byte(s) in 4 object(s) allocated from:
    #0 0x4eca27 in __interceptor_malloc (/home/victor/sync/devel/eidps/src/suricata+0x4eca27)
    #1 0x7fb99f471d9d in json_integer (/usr/lib/x86_64-linux-gnu/libjansson.so.4+0x8d9d)
    #2 0x18927af in OutputFilestoreFinalizeFiles /home/victor/devel/eidps/src/output-filestore.c:171:35
    #3 0x188e288 in OutputFilestoreLogger /home/victor/devel/eidps/src/output-filestore.c:267:9
    #4 0x1887c2e in CallLoggers /home/victor/devel/eidps/src/output-filedata.c:113:9
    #5 0x18871a2 in OutputFiledataLogFfc /home/victor/devel/eidps/src/output-filedata.c:192:37
    #6 0x188405e in OutputFiledataLog /home/victor/devel/eidps/src/output-filedata.c:238:5
    #7 0x187695a in OutputLoggerLog /home/victor/devel/eidps/src/output.c:920:13
    #8 0x17bb3f5 in FlowWorker /home/victor/devel/eidps/src/flow-worker.c:265:5
    #9 0x1df241a in TmThreadsSlotVarRun /home/victor/devel/eidps/src/tm-threads.c:128:17
    #10 0x1e08bff in TmThreadsSlotVar /home/victor/devel/eidps/src/tm-threads.c:583:17
    #11 0x7fb99f2516da in start_thread (/lib/x86_64-linux-gnu/libpthread.so.0+0x76da)

Direct leak of 48 byte(s) in 2 object(s) allocated from:
    #0 0x4eca27 in __interceptor_malloc (/home/victor/sync/devel/eidps/src/suricata+0x4eca27)
    #1 0x7fb99f471d9d in json_integer (/usr/lib/x86_64-linux-gnu/libjansson.so.4+0x8d9d)
    #2 0x18f4b3a in FileWriteJsonRecord /home/victor/devel/eidps/src/output-json-file.c:264:18
    #3 0x18f38e8 in JsonFileLogger /home/victor/devel/eidps/src/output-json-file.c:285:5
    #4 0x187e06a in OutputFileLogFfc /home/victor/devel/eidps/src/output-file.c:131:21
    #5 0x187c914 in OutputFileLog /home/victor/devel/eidps/src/output-file.c:178:5
    #6 0x187695a in OutputLoggerLog /home/victor/devel/eidps/src/output.c:920:13
    #7 0x17bb3f5 in FlowWorker /home/victor/devel/eidps/src/flow-worker.c:265:5
    #8 0x1df241a in TmThreadsSlotVarRun /home/victor/devel/eidps/src/tm-threads.c:128:17
    #9 0x1e08bff in TmThreadsSlotVar /home/victor/devel/eidps/src/tm-threads.c:583:17
    #10 0x7fb99f2516da in start_thread (/lib/x86_64-linux-gnu/libpthread.so.0+0x76da)

Direct leak of 48 byte(s) in 2 object(s) allocated from:
    #0 0x4eca27 in __interceptor_malloc (/home/victor/sync/devel/eidps/src/suricata+0x4eca27)
    #1 0x7fb99f471d9d in json_integer (/usr/lib/x86_64-linux-gnu/libjansson.so.4+0x8d9d)
    #2 0x18927af in OutputFilestoreFinalizeFiles /home/victor/devel/eidps/src/output-filestore.c:171:35
    #3 0x188e288 in OutputFilestoreLogger /home/victor/devel/eidps/src/output-filestore.c:267:9
    #4 0x1887c2e in CallLoggers /home/victor/devel/eidps/src/output-filedata.c:113:9
    #5 0x18871a2 in OutputFiledataLogFfc /home/victor/devel/eidps/src/output-filedata.c:192:37
    #6 0x1883d85 in OutputFiledataLog /home/victor/devel/eidps/src/output-filedata.c:236:5
    #7 0x187695a in OutputLoggerLog /home/victor/devel/eidps/src/output.c:920:13
    #8 0x17bb3f5 in FlowWorker /home/victor/devel/eidps/src/flow-worker.c:265:5
    #9 0x1df241a in TmThreadsSlotVarRun /home/victor/devel/eidps/src/tm-threads.c:128:17
    #10 0x1e08bff in TmThreadsSlotVar /home/victor/devel/eidps/src/tm-threads.c:583:17
    #11 0x7fb99f2516da in start_thread (/lib/x86_64-linux-gnu/libpthread.so.0+0x76da)

SUMMARY: AddressSanitizer: 288 byte(s) leaked in 12 allocation(s).

Actions #1

Updated by Victor Julien over 5 years ago

  • Status changed from Assigned to Closed
  • Priority changed from High to Normal
Actions

Also available in: Atom PDF