linux/arch/parisc
Helge Deller 7961981718 parisc: Fix kernel panic due invalid values in IAOQ0 or IAOQ1
commit 10835c8546 upstream.

On parisc the privilege level of a process is stored in the lowest two bits of
the instruction pointers (IAOQ0 and IAOQ1). On Linux we use privilege level 0
for the kernel and privilege level 3 for user-space. So userspace should not be
allowed to modify IAOQ0 or IAOQ1 of a ptraced process to change it's privilege
level to e.g. 0 to try to gain kernel privileges.

This patch prevents such modifications by always setting the two lowest bits to
one (which relates to privilege level 3 for user-space) if IAOQ0 or IAOQ1 are
modified via ptrace calls in the native and compat ptrace paths.

Link: https://bugs.gentoo.org/481768
Reported-by: Jeroen Roovers <jer@gentoo.org>
Cc: <stable@vger.kernel.org>
Tested-by: Rolf Eike Beer <eike-kernel@sf-tec.de>
Signed-off-by: Helge Deller <deller@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-26 09:14:29 +02:00
..
boot parisc: Use PA_ASM_LEVEL in boot code 2019-05-25 18:23:23 +02:00
configs
include parisc: Rename LEVEL to PA_ASM_LEVEL to avoid name clash with DRBD code 2019-05-25 18:23:24 +02:00
kernel parisc: Fix kernel panic due invalid values in IAOQ0 or IAOQ1 2019-07-26 09:14:29 +02:00
lib parisc: Fix and improve kernel stack unwinding 2018-08-13 09:54:17 +02:00
math-emu parisc: Fix compiler warnings in float emulation code 2019-06-25 11:35:55 +08:00
mm parisc: Fix map_pages() to not overwrite existing pte entries 2018-11-13 11:08:18 -08:00
oprofile
defpalo.conf
install.sh
Kconfig Consolidation of Kconfig files by Christoph Hellwig. 2018-08-15 13:05:12 -07:00
Kconfig.debug Kconfig: consolidate the "Kernel hacking" menu 2018-08-02 08:06:48 +09:00
Makefile parisc: Enable -ffunction-sections for modules on 32-bit kernel 2018-12-13 09:16:18 +01:00
nm