AAPT
AAPT全稱,Android Asset Packaging Tool。開發(fā)者可以在Android SDK的build-tools目錄下找到這個工具。
aapt_dir.png
AAPT使用
- 列舉apk內(nèi)容文件
利用上面的指令,可以列舉出apk中的所有內(nèi)容./aapt l[ist] <APK PATH>
可以使用重定向符“>”講內(nèi)容輸出到指定的文件中./aapt l[ist] <APK PATH> > <DEST PATH>
- 查看指定文件信息
values的取值可以分為以下幾類./aapt d[ump] [--values]<APK PATH>
- strings Print the contents of the resource table string pool in the APK.
- badging Print the label and icon for the app declared in APK.
- permissions Print the permissions from the APK.
- resources Print the resource table from the APK.
- configurations Print the configurations in the APK.
- xmltree Print the compiled xmls in the given assets.
- xmlstrings Print the strings of the given compiled xml assets.
xmltree和xmlstrings 兩個參數(shù)在apk后面要寫出具體的xml文件的路徑
./aapt d badging app-debug.apk|grep package