This is a security check that warns when both PROT_WRITE and PROT_EXEC are
set during mmap(). If mmap()ed memory is both writable and executable, it makes
it easier for the attacker to execute arbitrary code when contents of this
memory are compromised. Some applications require such mmap()s though, such as
different sorts of JIT.
Re-applied after a revert in r324167.
Temporarily stays in the alpha package because it needs a better way of
determining macro values that are not immediately available in the AST.
Patch by David Carlier!
Differential Revision: https://reviews.llvm.org/D42645
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@326405 91177308-0d34-0410-b5e6-96231b3b80d8
Due to Buildbot failures - most likely that's because target triples were not
specified in the tests, even though the checker behaves differently with
different target triples.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@324167 91177308-0d34-0410-b5e6-96231b3b80d8
This is a security check which is disabled by default but will be enabled
whenever the user consciously enables the security package. If mmap()ed memory
is both writable and executable, it makes it easier for the attacker to execute
arbitrary code when contents of this memory are compromised. Some applications
require such mmap()s though, such as different sorts of JIT.
Patch by David Carlier!
Differential Revision: https://reviews.llvm.org/D42645
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@324166 91177308-0d34-0410-b5e6-96231b3b80d8