]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Control implicit PROT_MAX() using procctl(2) and the FreeBSD note
authorkib <kib@FreeBSD.org>
Tue, 2 Jul 2019 19:07:17 +0000 (19:07 +0000)
committerkib <kib@FreeBSD.org>
Tue, 2 Jul 2019 19:07:17 +0000 (19:07 +0000)
commit5144f6086b02fd30a2fc7268dd0b960fdc215587
tree96703a93b51f5d48d8b713c1307d2ef5c6f4da62
parent558f1c0d8c709c9625832eae65ba218bc7085b20
Control implicit PROT_MAX() using procctl(2) and the FreeBSD note
feature bit.

In particular, allocate the bit to opt-out the image from implicit
PROTMAX enablement.  Provide procctl(2) verbs to set and query
implicit PROTMAX handling.  The knobs mimic the same per-image flag
and per-process controls for ASLR.

Reviewed by: emaste, markj (previous version)
Discussed with: brooks
Sponsored by: The FreeBSD Foundation
Differential revision: https://reviews.freebsd.org/D20795
lib/libc/sys/procctl.2
sys/compat/freebsd32/freebsd32_misc.c
sys/kern/kern_procctl.c
sys/sys/elf_common.h
sys/sys/proc.h
sys/sys/procctl.h
sys/sys/syscallsubr.h
sys/vm/vm_mmap.c