kernel-hardening.lists.openwall.com archive mirror
 help / color / mirror / Atom feed
* [RFC PATCH 0/5] Prevent write to read-only pages (text, PLT/GOT
@ 2020-04-06 14:20 Lev Olshvang
  2020-04-06 14:20 ` [RFC PATCH 1/5] security : hardening : prevent write to proces's read-only pages from another process Lev Olshvang
                   ` (4 more replies)
  0 siblings, 5 replies; 9+ messages in thread
From: Lev Olshvang @ 2020-04-06 14:20 UTC (permalink / raw)
  To: arnd; +Cc: kernel-hardening, Lev Olshvang

The purpose of this patch is produce hardened kernel for Embedded
or Production systems.

Typically debuggers, such as gdb, write to read-only code [text]
sections of target process.(ptrace)
This kind of page protectiion violation raises minor page fault, but
kernel's fault handler allows it by default.
This is clearly attack surface for adversary.

The proposed kernel hardening configuration option checks the type of
protection of the foreign vma and blocks writes to read only vma.

When enabled, it will stop attacks modifying code or jump tables, etc.

Lev Olshvang (5):
  security : hardening : prevent write to proces's read-only pages from
    another process
  Prevent write to read-only pages (text, PLT/GOT tables from another
    process
  Prevent write to read-only pages (text, PLT/GOT tables from another
    process
  X86:Prevent write to read-only pages (text, PLT/GOT tables from
    another process
  UM:Prevent write to read-only pages (text, PLT/GOT tables from another
    process

 arch/powerpc/include/asm/mmu_context.h   |  7 ++++++-
 arch/powerpc/mm/book3s64/pkeys.c         |  5 +++++
 arch/um/include/asm/mmu_context.h        | 11 ++++++++---
 arch/unicore32/include/asm/mmu_context.h |  7 ++++++-
 arch/x86/include/asm/mmu_context.h       |  9 ++++++++-
 include/asm-generic/mm_hooks.h           |  5 +++++
 security/Kconfig                         | 10 ++++++++++
 7 files changed, 48 insertions(+), 6 deletions(-)

--
2.17.1


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

end of thread, other threads:[~2020-04-07 16:25 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-06 14:20 [RFC PATCH 0/5] Prevent write to read-only pages (text, PLT/GOT Lev Olshvang
2020-04-06 14:20 ` [RFC PATCH 1/5] security : hardening : prevent write to proces's read-only pages from another process Lev Olshvang
2020-04-06 19:15   ` Kees Cook
2020-04-07 10:16     ` Lev R. Oshvang .
2020-04-07 16:25       ` Kees Cook
2020-04-06 14:20 ` [RFC PATCH 2/5] Prevent write to " Lev Olshvang
2020-04-06 14:20 ` [RFC PATCH 3/5] Prevent write to read-only pages text, PLT/GOT tables " Lev Olshvang
2020-04-06 14:20 ` [RFC PATCH 4/5] X86:Prevent write to read-only pages :text, " Lev Olshvang
2020-04-06 14:20 ` [RFC PATCH 5/5] UM:Prevent " Lev Olshvang

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).