diff options
author | mark@chromium.org <mark@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-08-24 03:33:36 +0000 |
---|---|---|
committer | mark@chromium.org <mark@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-08-24 03:33:36 +0000 |
commit | 8c40f3212b62b828f3cfbe151fb3ecd2294e44ca (patch) | |
tree | ea582d6c5b274418ff853eb67bc8bbbe2ed2d619 /chrome/chrome_exe.gypi | |
parent | 06ead8788ef8d9ea7e5db736d563a7fb25df059d (diff) | |
download | chromium_src-8c40f3212b62b828f3cfbe151fb3ecd2294e44ca.zip chromium_src-8c40f3212b62b828f3cfbe151fb3ecd2294e44ca.tar.gz chromium_src-8c40f3212b62b828f3cfbe151fb3ecd2294e44ca.tar.bz2 |
Give plug-in processes an executable heap and disable PIE/ASLR for Native
Client loader processes.
Some plug-ins depend on having an executable heap. They write code to data
pages and attempt to execute it without calling mprotect to mark this code
as executable.
Native Client needs to allocate a contiguous 1GB of address space. ASLR may
interfere with there being a "hole" this large in the address space by the
time NaCl makes its request.
Non-executable heaps are only available in 10.7 and later for 32-bit
processes.
PIE/ASLR was formerly disabled for all processes other than the browser
process. This change reenables it for all processes other than the NaCl
loader. PIE/ASLR is available on 10.5 and later, although the implementation
is stronger in 10.7 than in earlier releases.
This change results in two new helpers in addition to the existing
Chromium Helper.app: Chromium Helper EH.app (for executable heaps) and
Chromium Helper NP.app (for no PIE). libplugin_carbon_interpose.dylib moves
out of the helper .app and directly into the versioned directory. The
InfoPlist.strings have been removed from the helper app, but empty .lproj
directories remain.
BUG=90221, 93551
TEST=everything
Review URL: http://codereview.chromium.org/7714018
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@97984 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/chrome_exe.gypi')
-rw-r--r-- | chrome/chrome_exe.gypi | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/chrome/chrome_exe.gypi b/chrome/chrome_exe.gypi index 83b6e98..79d98f7 100644 --- a/chrome/chrome_exe.gypi +++ b/chrome/chrome_exe.gypi @@ -273,6 +273,7 @@ 'dependencies': [ 'helper_app', 'infoplist_strings_tool', + 'interpose_dependency_shim', 'chrome_manifest_bundle', ], 'mac_bundle_resources': [ @@ -327,6 +328,7 @@ 'destination': '<(PRODUCT_DIR)/<(mac_product_name).app/Contents/Versions/<(version_full)', 'files': [ '<(PRODUCT_DIR)/<(mac_product_name) Helper.app', + '<(PRODUCT_DIR)/libplugin_carbon_interpose.dylib', ], }, ], @@ -366,6 +368,38 @@ '<(version_full)' ], }, + { + # This postbuid step is responsible for creating the following + # helpers: + # + # For unofficial Chromium branding, Chromium Helper EH.app and + # Chromium Helper NP.app are created from Chromium Helper.app. + # For official Google Chrome branding, Google Chrome Helper + # EH.app and Google Chrome Helper NP.app are created from + # Google Chrome Helper.app. + # + # The EH helper is marked for an executable heap. The NP helper + # is marked for no PIE (ASLR). + # + # Normally, applications shipping as part of offical builds with + # Google Chrome branding have dsymutil (dwarf-with-dsym, + # mac_real_dsym) and dump_syms (mac_breakpad) run on them to + # produce a .dSYM bundle and a Breakpad .sym file. This is + # unnecessary for the "More Helpers" because they're identical + # to the original helper except for the bits in their Mach-O + # headers that change to enable or disable special features. + # Each .dSYM and Breakpad symbol file is identified by UUID + # stored in a Mach-O file's LC_UUID load command. Because the + # "More Helpers" share a UUID with the original helper, there's + # no need to run dsymutil or dump_syms again. All helpers can + # share the same .dSYM and Breakpad symbol file. + 'postbuild_name': 'Make More Helpers', + 'action': [ + 'tools/build/mac/make_more_helpers.sh', + '<(version_full)', + '<(mac_product_name)', + ], + }, ], # postbuilds }], ['OS=="linux"', { |