Android - How to check Proguard obfuscation has worked?
In your project directory you will find a Proguard
folder, in which you will see four text files:
dump.txt
Describes the internal structure of all the class files in the .apk file
mapping.txt
Lists the mapping between the original and obfuscated class, method, and field names. This file is important when you receive a bug report from a release build, because it translates the obfuscated stack trace back to the original class, method, and member names. See Decoding Obfuscated Stack Traces for more information.
seeds.txt
Lists the classes and members that are not obfuscated
usage.txt
Lists the code that was stripped from the .apk
Source: Proguard
Hope this helps!
Here is probably a more visual way to check. In the newer release of Android Studio, it comes with the APK Analyser that let user explore what is in the APK file and it is handy to check if your class has been obfuscated.
Below image shows that both package and method name have been obfuscated
Proguard workflow:
seeds.txt
- list of what Proguard keeps. These are entry points and they nodes. For example for bare java it is amain
function and others dependenciesusage.txt
- list of what Proguard does not keepmapping.txt
- info about old and new naming inold_name -> new_name
format. It can be used for decoding stacktrace byretrace
orproguardui
dump.txt
- describe everything that Proguard put into the result archive
You can find output
<module_name>/build/outputs/mapping/<buildType>/
You can use Analyze APK
tool. Where you can look thought .class
files, add a Proguard mapping file, show removed nodes, show deobfuscated names