From: Andrew Morton <akpm@osdl.org>
To: Yichen Xie <yxie@cs.stanford.edu>
Cc: linux-kernel@vger.kernel.org
Subject: Re: Potential DOS in load_elf_library?
Date: Fri, 18 Mar 2005 00:42:24 -0800 [thread overview]
Message-ID: <20050318004224.2f32fb24.akpm@osdl.org> (raw)
In-Reply-To: <Pine.LNX.4.60.0503180008140.25717@localhost.localdomain>
Yichen Xie <yxie@cs.stanford.edu> wrote:
>
> Hi guys, I was looking at the load_elf_library function (fs/binfmt_elf.c)
> in 2.6.10, and noticed the following:
>
> elf_phdata = (struct elf_phdr *) kmalloc(j, GFP_KERNEL);
> ...
> while (elf_phdata->p_type != PT_LOAD) elf_phdata++;
> ...
> kfree(elf_phdata);
>
> Could this be problematic since the pointer being freed might be different
> from that returned from kmalloc?
Current kernels seem to be OK.
next prev parent reply other threads:[~2005-03-18 8:42 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-03-18 8:15 Yichen Xie
2005-03-18 8:42 ` Andrew Morton [this message]
2005-03-18 8:52 ` Herbert Xu
2005-03-18 9:05 ` Andrew Morton
2005-03-18 9:09 ` Herbert Xu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20050318004224.2f32fb24.akpm@osdl.org \
--to=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=yxie@cs.stanford.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®