Android Proguard Usage Tips

Source: Internet
Author: User

1. Decoding after confusion

After the Proguard runs, output the following files:

Dump.txt: Describes the internal structure between all class files in the. apk file

Mapping.txt: Lists the original classes, method and field names, and the mappings between the code after the confusion. This file is important, and you can use it to translate the obfuscated code when you receive a bug report from the release release.

Seeds.txt: Lists classes and members that are not confused

Usage.txt: Lists the code that was removed from the. apk

These files are placed in the following folder:

· Ant:<project_root>/bin/proguard

· Eclipse: <project_root>/proguard

Note: Each time you compile in release mode, these files are overwritten by overrides, of course, by the latest files generated by the Proguard tool. Each time you publish your program, you should keep one copy, in order to decode the bug report in the future.

2. Remove the test code:

-assumenosideeffects class android.util.log{

public static * * * * d (...);

}

The above statement is used to remove all LOG.D () methods, and similarly, to remove other test code.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.