From: "Zach, Yoav" <yoav.zach@intel.com>
To: "Alan Cox" <alan@lxorguk.ukuu.org.uk>
Cc: "Linux Kernel Mailing List" <linux-kernel@vger.kernel.org>
Subject: RE: [PATCH]: non-readable binaries - binfmt_misc 2.6.0-test4
Date: Thu, 4 Sep 2003 09:30:17 +0300 [thread overview]
Message-ID: <2C83850C013A2540861D03054B478C0601CF64F5@hasmsx403.iil.intel.com> (raw)
> You've added a security hole.
>
> > + if (fmt->flags & MISC_FMT_OPEN_BINARY) {
> > + /* if the binary should be opened on behalf of the
> > + * interpreter than keep it open and assign it a
> > descriptor */
> > + fd = get_unused_fd ();
> > + if (fd < 0) {
>
> At this point your file table might be shared with another thread (see
> binfmt_elf in 2.4 - I dunno if 2.6 has been fixed for this
> exploit yet).
> You need to unshare the file table before you modify it
> during the exec.
>
> Otherwise it looks fairly sane.
>
Do you know whether the 'unshare_files' patch was already prepared and
sent to the 2.6 maintainer ? If not then I would like to do it.
Thanks,
Yoav.
next reply other threads:[~2003-09-04 6:30 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-09-04 6:30 Zach, Yoav [this message]
-- strict thread matches above, loose matches on Subject: below --
2003-08-31 21:41 Zach, Yoav
2003-08-31 22:12 ` Herbert Poetzl
2003-08-31 22:48 ` Alan Cox
2003-08-31 22:45 ` Alan Cox
2003-08-31 22:58 ` Alan Cox
2003-09-01 4:20 ` Willy Tarreau
2003-08-31 23:01 ` Linus Torvalds
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=2C83850C013A2540861D03054B478C0601CF64F5@hasmsx403.iil.intel.com \
--to=yoav.zach@intel.com \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=linux-kernel@vger.kernel.org \
/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®