Page MenuHomeFreeBSD

implement W^X for mmap and mprotect
Needs ReviewPublic

Authored by emaste on Wed, May 20, 6:29 PM.
This revision needs review, but there are no reviewers specified.

Details

Reviewers
None
Summary

If sysctl vm.allow_wx = 0 then disallow prot with PROT_WRITE and PROT_EXECUTE both set, for mmap(2) and mprotect(2).

TODO: add support in procctl(2), proccontrol(1), and ELF tagging.

Diff Detail

Lint
Lint Skipped
Unit
Unit Tests Skipped

Event Timeline

emaste requested review of this revision.Wed, May 20, 6:29 PM
emaste created this revision.
lwhsu added a subscriber: lwhsu.Wed, May 20, 8:45 PM