linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Kees Cook <keescook@chromium.org>
To: Pedro Falcato <pedro.falcato@gmail.com>
Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org,
	dalias@libc.org, ebiederm@xmission.com, sam@gentoo.org,
	viro@zeniv.linux.org.uk
Subject: Re: [PATCH v3] fs/binfmt_elf: Fix memsz > filesz handling
Date: Thu, 10 Nov 2022 22:15:44 -0800	[thread overview]
Message-ID: <202211102214.D764FAE21@keescook> (raw)
In-Reply-To: <CAKbZUD2r=zK91J4c6pyHQhDuqqMzmrx+BBgFF4Cso2jK+jjhHA@mail.gmail.com>

On Fri, Nov 11, 2022 at 03:59:08AM +0000, Pedro Falcato wrote:
> We could of course also just sort the program headers at load time,
> but I assume that's unwanted overhead for most well behaved ELF
> program headers :)

Large refactoring of the ELF loader needs proper unit testing, and we're
still a bit away from that existing. In the meantime, we'll need to make
very very small changes to fix bugs. I've sent a minimal change which I
think should fix the problem (now at v2 since right after sending it I
realized I was trading one accidentally correct state for another in the
v1):
https://lore.kernel.org/linux-hardening/20221111061315.gonna.703-kees@kernel.org/

-- 
Kees Cook


  reply	other threads:[~2022-11-11  6:15 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-08 11:07 Pedro Falcato
2022-11-11  3:38 ` Kees Cook
2022-11-11  3:59   ` Pedro Falcato
2022-11-11  6:15     ` Kees Cook [this message]
2022-11-11 17:14       ` Pedro Falcato
2022-11-11 18:43         ` Kees Cook
2022-11-11 16:32 ` kernel test robot
2022-11-11 18:13 ` kernel test robot

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=202211102214.D764FAE21@keescook \
    --to=keescook@chromium.org \
    --cc=dalias@libc.org \
    --cc=ebiederm@xmission.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=pedro.falcato@gmail.com \
    --cc=sam@gentoo.org \
    --cc=viro@zeniv.linux.org.uk \
    /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