linux/arch/x86/entry/vdso
Mathias Krause c06989da39 x86/vdso: Ensure vdso32_enabled gets set to valid values only
vdso_enabled can be set to arbitrary integer values via the kernel command
line 'vdso32=' parameter or via 'sysctl abi.vsyscall32'.

load_vdso32() only maps VDSO if vdso_enabled == 1, but ARCH_DLINFO_IA32
merily checks for vdso_enabled != 0. As a consequence the AT_SYSINFO_EHDR
auxiliary vector for the VDSO_ENTRY is emitted with a NULL pointer which
causes a segfault when the application tries to use the VDSO.

Restrict the valid arguments on the command line and the sysctl to 0 and 1.

Fixes: b0b49f2673 ("x86, vdso: Remove compat vdso support")
Signed-off-by: Mathias Krause <minipli@googlemail.com>
Acked-by: Andy Lutomirski <luto@amacapital.net>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: stable@vger.kernel.org
Cc: Roland McGrath <roland@redhat.com>
Link: http://lkml.kernel.org/r/1491424561-7187-1-git-send-email-minipli@googlemail.com
Link: http://lkml.kernel.org/r/20170410151723.518412863@linutronix.de
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2017-04-10 18:31:41 +02:00
..
vdso32 x86/vdso/32: Assemble sigreturn.S separately 2016-06-14 12:16:06 +02:00
.gitignore
checkundef.sh
Makefile Merge branch 'kbuild' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild 2016-08-02 16:37:12 -04:00
vclock_gettime.c clocksource: Use a plain u64 instead of cycle_t 2016-12-25 11:04:12 +01:00
vdso2c.c x86/vdso: Get pvclock data from the vvar VMA instead of the fixmap 2015-12-11 08:56:03 +01:00
vdso2c.h x86/vdso: Fix building on big endian host 2016-09-30 12:37:40 +02:00
vdso32-setup.c x86/vdso: Ensure vdso32_enabled gets set to valid values only 2017-04-10 18:31:41 +02:00
vdso-layout.lds.S x86/vdso: Remove direct HPET access through the vDSO 2016-04-13 10:28:34 +02:00
vdso-note.S
vdso.lds.S
vdsox32.lds.S
vgetcpu.c
vma.c sched/headers: Prepare for new header dependencies before moving code to <linux/sched/task_stack.h> 2017-03-02 08:42:36 +01:00