angler-fishThe Vulnerability History Project

Give base::SharedMemory::CreateAnonymous an executable flag

      NaCl on Mac and Linux needs to create a shared memory object that it can
later make executable with mprotect.  Express this need in the interface it
uses.  Add a test that pages mapped from such an object can later be passed
to mprotect with PROT_EXEC.

This lays the groundwork for a later change that will sometimes use a
different method to allocate an object on Linux when it needs to be
executable.  On some Linux distributions, shm_open yields objects whose
mappings cannot be made executable.

BUG= http://code.google.com/p/chromium/issues/detail?id=103377
TEST= SharedMemory.AnonymousExecutable

R=mark@chromium.org,jam@chromium.org,amit@chromium.org,ben@chromium.org

Review URL: http://codereview.chromium.org/8585002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@112570 0039d316-1c4b-4281-b951-d872f2087c98
    
commit b05df6b03e0d5dc552a96578ea6a8a7e47af407c
+39 -2
+4 -3
+10 -15
+22
+8 -12
+4 -1
expand_less