Re: [patch 03/18] entry: Provide [syscall_]enter_from_user_mode_randomize_stack()

From
Thomas Gleixner <tglx@kernel.org>
Date
2026-08-29 21:12:50
Also in
linux-alpha, linux-arch, linux-doc, linux-m68k, linux-mips, linux-riscv, linux-s390, linux-sh, linux-um, lkml, loongarch, sparclinux
Reply to
H. Peter Anvin, 2026-08-27
On Thu, Aug 27 2026 at 15:46, H. Peter Anvin wrote:
Can anyone *please* find out what the actual security requirements are for the
syscall randomization offset?

The original checkin, 39218ff4c625 ("stack: Optionally randomize kernel stack
offset each syscall") indicates that it is fundamental that the stack offset
is applied *after* pt_regs pushing, but that isn't documented anywhere in the
kernel sources as far as I can tell.
However, I have also come to understand that there are further, undocumented
constraints; at least at one point I was told that "the offset should not be
stored in memory while running in the kernel", which seems more than a bit odd.
This thread has the initial discussions about it with more explanations:

  https://lore.kernel.org/kernel-hardening/2236FBA76BA1254E88B949DDB74E612BA4BC57C1@IRSMSX102.ger.corp.intel.com/

Thanks,

        tglx
Thread (125 messages) 125 messages, 17 authors, last reply 18d ago
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help