lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190219022512.GW2217@ZenIV.linux.org.uk>
Date:   Tue, 19 Feb 2019 02:25:12 +0000
From:   Al Viro <viro@...iv.linux.org.uk>
To:     YueHaibing <yuehaibing@...wei.com>
Cc:     linux-kernel@...r.kernel.org, linux-fsdevel@...r.kernel.org,
        dmitry.kasatkin@...wei.com, keescook@...omium.org
Subject: Re: [PATCH -next] exec: Fix mem leak in kernel_read_file

On Tue, Feb 19, 2019 at 10:10:38AM +0800, YueHaibing wrote:
> syzkaller report this:
> BUG: memory leak
> unreferenced object 0xffffc9000488d000 (size 9195520):
>   comm "syz-executor.0", pid 2752, jiffies 4294787496 (age 18.757s)
>   hex dump (first 32 bytes):
>     ff ff ff ff ff ff ff ff a8 00 00 00 01 00 00 00  ................
>     02 00 00 00 00 00 00 00 80 a1 7a c1 ff ff ff ff  ..........z.....
>   backtrace:
>     [<000000000863775c>] __vmalloc_node mm/vmalloc.c:1795 [inline]
>     [<000000000863775c>] __vmalloc_node_flags mm/vmalloc.c:1809 [inline]
>     [<000000000863775c>] vmalloc+0x8c/0xb0 mm/vmalloc.c:1831
>     [<000000003f668111>] kernel_read_file+0x58f/0x7d0 fs/exec.c:924
>     [<000000002385813f>] kernel_read_file_from_fd+0x49/0x80 fs/exec.c:993
>     [<0000000011953ff1>] __do_sys_finit_module+0x13b/0x2a0 kernel/module.c:3895
>     [<000000006f58491f>] do_syscall_64+0x147/0x600 arch/x86/entry/common.c:290
>     [<00000000ee78baf4>] entry_SYSCALL_64_after_hwframe+0x49/0xbe
>     [<00000000241f889b>] 0xffffffffffffffff
> 
> It should goto 'out_free' lable to free allocated buf while kernel_read
> fails.

Applied.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ