souramoo / Needle

Android framework injection made easy
GNU General Public License v3.0
100 stars 28 forks source link

Does not work with odexed/oat ROMs (Lollipop + Marshmallow) #4

Open michitux opened 8 years ago

michitux commented 8 years ago

I've just upgraded my Samsung Galaxy Nexus to official CM 12.1 nightlies. Unfortunately patching fails there, as the framework is odexed, i.e. framework.jar is empty, the code is in /system/framework/arm/boat.oat. smali seems to have support for deodexing ART oat files but only for Marshmellow. There is also another oat2dex.jar which seems to be used by other tools that claim Android 5.0 support. With java -jar oat2dex.jar -a 22 smali ../../Needle/boot.oat I have been able to produce a PackageParser.smali file that could be patched. However I don't know if it is possible to re-assemble to result and if yes, how to do that (or what to do instead). Some of the binaries that use oat2dex.jar appear to be able to do that, but - as far as I can see - most of them are close source and Windows only (and I have only Linux...).

GitteHuber commented 8 years ago

Same for me, I'm also using the official CM 12.1 nightlies for Samsung Galaxy Nexus. I also encountered the problem michitux describes.

Is there any chance, that needle will support this kind of setup?