implement runtime relocation of the ART boot image #51

Open
thestinger opened this Issue Oct 25, 2015 · 0 comments

Comments

Projects
None yet
1 participant
@thestinger
Contributor

thestinger commented Oct 25, 2015

The ART boot image (boot.art) is generated for the initial boot of a given version via patchoat, and is then mapped in at a fixed location in all processes. This needs to be fixed for full ASLR in ART processes (app_process, system_server). It should be relocated in-memory at runtime.

Note that while boot.oat is not currently position independent and is also patched with patchoat, there's support for using WITH_DEXPREOPT_PIC with it. It has an issue resulting in log spam (at least in debug builds) in Marshmallow that appears to be fixed in master / Nougat. It could be backported but there was a lot of churn, so it might make sense to simply relocate both via the same hack for now and then move boot.oat to the more efficient PIC model in Nougat.

@thestinger thestinger changed the title from ART boot image is placed at a persistent address chosen by ART via MAP_FIXED to implement runtime relocation of the ART boot image Jun 10, 2016

@thestinger thestinger added the project label Jun 12, 2016

@thestinger thestinger removed the project label Sep 26, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment