linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/4] binfmt_elf: Support segments with 0 filesz and misaligned starts
@ 2023-09-27  3:42 Kees Cook
  2023-09-27  3:42 ` [PATCH v3 1/4] " Kees Cook
                   ` (5 more replies)
  0 siblings, 6 replies; 9+ messages in thread
From: Kees Cook @ 2023-09-27  3:42 UTC (permalink / raw)
  To: Eric Biederman
  Cc: Kees Cook, Sebastian Ott, Thomas Weißschuh, Al Viro,
	Christian Brauner, Pedro Falcato, linux-kernel, linux-fsdevel,
	linux-mm, linux-hardening

Hi,

This is the continuation of the work Eric started for handling
"p_memsz > p_filesz" in arbitrary segments (rather than just the last,
BSS, segment). I've added the suggested changes:

 - drop unused "elf_bss" variable
 - report padzero() errors when PROT_WRITE is present
 - refactor load_elf_interp() to use elf_load()

This passes my quick smoke tests, but I'm still trying to construct some
more complete tests...

-Kees

Eric W. Biederman (1):
  binfmt_elf: Support segments with 0 filesz and misaligned starts

Kees Cook (3):
  binfmt_elf: elf_bss no longer used by load_elf_binary()
  binfmt_elf: Provide prot bits as context for padzero() errors
  binfmt_elf: Use elf_load() for interpreter

 fs/binfmt_elf.c | 192 ++++++++++++++++++------------------------------
 1 file changed, 71 insertions(+), 121 deletions(-)

-- 
2.34.1


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2023-09-29  0:51 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-09-27  3:42 [PATCH v3 0/4] binfmt_elf: Support segments with 0 filesz and misaligned starts Kees Cook
2023-09-27  3:42 ` [PATCH v3 1/4] " Kees Cook
2023-09-27  3:42 ` [PATCH v3 2/4] binfmt_elf: elf_bss no longer used by load_elf_binary() Kees Cook
2023-09-27  3:42 ` [PATCH v3 3/4] binfmt_elf: Provide prot bits as context for padzero() errors Kees Cook
2023-09-27 20:18   ` Eric W. Biederman
2023-09-29  0:51     ` Kees Cook
2023-09-27  3:42 ` [PATCH v3 4/4] binfmt_elf: Use elf_load() for interpreter Kees Cook
2023-09-27 20:25 ` [PATCH v3 0/4] binfmt_elf: Support segments with 0 filesz and misaligned starts Eric W. Biederman
2023-09-28 12:55 ` Sebastian Ott

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).