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: <20141126044306.36e16cad.akpm@linux-foundation.org>
Date:	Wed, 26 Nov 2014 04:43:06 -0800
From:	Andrew Morton <akpm@...ux-foundation.org>
To:	Jungseung Lee <js07.lee@...il.com>
Cc:	Alexander Viro <viro@...iv.linux.org.uk>,
	linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [RFC PATCH] fs/binfmt_elf.c: fix inconsistent vma dump size

On Wed, 26 Nov 2014 21:37:54 +0900 Jungseung Lee <js07.lee@...il.com> wrote:

> 2014-11-26 15:51 GMT+09:00 Jungseung Lee <js07.lee@...il.com>:
> 
> >>> @@ -2093,7 +2083,20 @@ static int elf_core_dump(struct coredump_params *cprm)
> >>>
> >>>       dataoff = offset = roundup(offset, ELF_EXEC_PAGESIZE);
> >>>
> >>> -     offset += elf_core_vma_data_size(gate_vma, cprm->mm_flags);
> >>> +     vma_filesz = kmalloc(sizeof(*vma_filesz) * (segs - 1), GFP_KERNEL);
> >>
> >> Use kmalloc_array() here, in case a disaster has occurred...
> >>
> > I'll try to find another way how to pass or save vma size with consistency.
> >
> it looks like just to replace kmalloc to vmalloc could be solution.
> I'll send patch, thanks.

Solution to what?  I was merely suggesting the use of kmalloc_array()
instead of open-coded kmalloc(n * m).

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ