先來(lái)張神圖
截圖.png
來(lái)源:AndroidManifest二進(jìn)制文件格式分析: https://bbs.pediy.com/thread-194206.html
原始AndroidManifest文件
<?xml version="1.0" encoding="utf-8"?>
<manifest
xmlns:android="http://schemas.android.com/apk/res/android"
android:versionCode="1"
android:versionName="1.0"
android:compileSdkVersion="30"
android:compileSdkVersionCodename="11"
package="com.example.myapplication"
platformBuildVersionCode="30"
platformBuildVersionName="11">
<uses-sdk
android:minSdkVersion="21"
android:targetSdkVersion="30" />
<application
android:theme="@ref/0x7f0c0005"
android:label="@ref/0x7f0b0027"
android:icon="@ref/0x7f0a0000"
android:debuggable="true"
android:testOnly="true"
android:allowBackup="true"
android:supportsRtl="true"
android:roundIcon="@ref/0x7f0a0001"
android:appComponentFactory="androidx.core.app.CoreComponentFactory">
<activity
android:name="com.example.myapplication.MainActivity">
<intent-filter>
<action
android:name="android.intent.action.MAIN" />
<category
android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>
解析
圖片左側(cè)為解壓開(kāi)apk后,AndroidManifest.xml的二進(jìn)制內(nèi)容片排,右側(cè)為各個(gè)chunk的解析沉颂。各個(gè)chunk和對(duì)應(yīng)的二進(jìn)制內(nèi)容通過(guò)相同的顏色標(biāo)記。
AnroidManifest文件格式.png
參考文檔
Android逆向三部曲之AndroidManifest.xml 文件格式: http://www.reibang.com/p/f0f4856866e0
AndroidManifest二進(jìn)制文件格式分析: https://bbs.pediy.com/thread-194206.html
手把手教你解析AXML:https://blog.csdn.net/beyond702/article/details/51830108?spm=1001.2014.3001.5502
大小端模式: https://blog.csdn.net/q2519008/article/details/80961176
ResourceTypes.h 源文件:http://androidxref.com/9.0.0_r3/xref/frameworks/base/libs/androidfw/include/androidfw/ResourceTypes.h