Android 再造:提取和保护 APK 的资源(技术问题) [英] Android reengineering : extract and protect APK's resources (technical questions)
问题描述
我对 APK 文件的技术细节很感兴趣.我已经知道 APKTOOL 能够提取 APK 文件(包括 smali 源)的所有这些布局文件等,但我想知道 APKTOOL 如何提取布局,因为它们以某种方式加密(以防你用解压打开它).
I'm interested in the technical details of APK files. I know already that the APKTOOL is able to extract all those layout files and so on of an APK file (including the smali sources), but I would like to khow, how the APKTOOL does the extraction of layouts, since they are crypted somehow (in case that you open it with unzip).
有人知道Android如何压缩/加密(?)APK文件中的那些布局文件?有说明吗?
Does anybody know something about how Android compresses/encrypts(?) those layout files in the APK files? Is there any description out there?
有人知道保护布局免受重新设计的方法吗?(类似于源代码中使用的 ProGuard)?
Does anybody know a way to protect layouts against reengineering? (similar to ProGuard used for the source code)?
推荐答案
据我所知,APK 中的所有 xml 文件都是以二进制 XML 格式存储的.所以它们没有加密,阅读它们也没什么大不了的.
As far as I know, all xml files in APKs are stored in Binary XML format. So they aren't encrypted and that's not a big deal to read them.
关于保护,我认为没有办法以某种方式混淆它们.使布局难以阅读的唯一方法是直接从代码创建视图,但我认为您不应该这样做.
What about protection, I don't think there's a way to obfuscate them somehow. The only way to make layouts difficult for reading is to create view directly from code, but I don't think you should do it.
这篇关于Android 再造:提取和保护 APK 的资源(技术问题)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!