bug-ncurses
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

A memory leak in _nc_init_termtype


From: 乐泰
Subject: A memory leak in _nc_init_termtype
Date: Thu, 20 Aug 2020 10:47:00 +0800 (GMT+08:00)

Reporter: Tai

Version: ncurses-6.2

Command: infotocap PoC

Environment: Ubuntu 16.04 x86-64

Detail Information: we have found a memory leak in the function _nc_init_termtype of ncurses-6.2 by fuzzing. We compile the ncurses-6.2 by AddressSanitizer in x86-64 format and print the information by executing infotocap PoC as below. The PoC file is in attachment.

=================================================================

==24750==ERROR: LeakSanitizer: detected memory leaks


Direct leak of 258336 byte(s) in 78 object(s) allocated from:

    #0 0x7fbf48aa1602 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.2+0x98602)

    #1 0x491de1 in _nc_init_termtype ../../ncurses/tinfo/read_entry.c:219


Direct leak of 6084 byte(s) in 78 object(s) allocated from:

    #0 0x7fbf48aa1602 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.2+0x98602)

    #1 0x491dc1 in _nc_init_termtype ../../ncurses/tinfo/read_entry.c:217


Direct leak of 3432 byte(s) in 78 object(s) allocated from:

    #0 0x7fbf48aa1602 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.2+0x98602)

    #1 0x491d5d in _nc_init_termtype ../../ncurses/tinfo/read_entry.c:215


SUMMARY: AddressSanitizer: 267852 byte(s) leaked in 234 allocation(s).



Attachment: id:004783,src:003656,op:havoc,rep:128
Description: Binary data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]