1. Introduction
This analysis is a very simple program, is a primer on the introduction of anti-compilation tutorial
Mainly learn about the use of tools, the following is downloaded from the Internet test samples
Test Sample ex_05_01_.apk
Link: http://pan.baidu.com/s/1sjOIXJn Password: 5uq4
2. First, use Dex2jar and Jd-gui to view
Reference: Android Learning Tips (8)---Mac Dex2jar and Jd-gui use
先提取apk中的classes.dex,使用dex2jar工具
使用jd-gui打开classes_dex2jar.jar查看源代码
通过源代码查看,我们可以知道,这个程序是简单的字符串比较而且由于"gogo".equals("11")必定不能相等,所以每次都是提示错误
3. Now we're going to decompile
Reference: Android Learning Tips (2)---Mac anti-compilation under Android
首先,使用apktool工具
EX05_01\smali\irdc\ex05_01路径修改EX05_01$1.smali文件
The first method of modification:
在这里会进行判断,if-eqz,如果相等,则跳转到cond_0这里修改为if-nez
The second method of modification
修改字符串"11"为"gogo",则每次判断都为正确
4. Recompile apk and sign
使用apktool工具重新编译
使用signapk.jar进行签名
5. Installation Test
Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.
Android learning Experience (MAC)---Android anti-compilation (2)