But interrupts can also be directly controllable and/or predictable by userspace, if not quite such a big attack surface. We could implement kernel stack randomization on interrupt as well. Kees didn't call it a horrible idea:
Looks like a straight-forward implementation is to perform the add_random_kstack_offset() and choose_random_kstack_offset() calls from the DEFINE_INTERRUPT_HANDLER* macros.
syscalls recently gained kernel stack randomization
https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git/commit/?id=f4a0318f278d98d9492916722e85f258c2221f88
But interrupts can also be directly controllable and/or predictable by userspace, if not quite such a big attack surface. We could implement kernel stack randomization on interrupt as well. Kees didn't call it a horrible idea:
https://lists.ozlabs.org/pipermail/linuxppc-dev/2022-May/243238.html