4

I created a sample app on android studio. After running proguard, the mapping file was placed on my mappings.txt file due to personal preferences. Everything seems to work fine. However, I thought my code was going to be obfuscated. My field "text" a textview has been renamed "p" according to the mappings.txt file. However when I open my project I still see the same code as before, I even set a new string on "text" and the program ran fine. Why doesn't my code seem obfuscated. I am trying to find the obfuscated stack trace, who knows where it is. By the way, I ran proguard on debug mode. Android should include videos on the ProGuard tool. It takes time from actual developing of code.

4

1 回答 1

10

Proguard 不会更改您的代码,它会重命名字段和方法名称,但会在生成的 apk 中,而不是在您的代码中。

您需要对堆栈跟踪进行去混淆处理。为此,您可以执行以下步骤:

  1. 打开 /tools/proguard/bin/proguardgui.bat
  2. 在左栏中选择 ReTrace。
  3. 添加您的映射文件和混淆的堆栈跟踪。
  4. 单击重新跟踪
于 2015-07-28T22:10:05.390 回答