Menu

#565 Proguard bug when obfuscating Android app that uses external jar obfuscated with GuardIT

v5.1
closed
nobody
None
High
2019-12-05
2015-02-13
No

We have a customer who is using Proguard to obfuscate the release build of their Android app. They are trying to integrate our libraries into their app, but they're running into problems when generating the release build. We have identified the issue to be because our libraries are obfuscated using GuardIT when we generate them, and Proguard performs optimizations on the already optimized and obfuscated code when they are trying to produce the release build.

The problem does not exist when the client uses the -dontoptimize flag in their pro guard configuration file. It also doesn't exist when they remove the following optimizations: method/marking/static,method/removal/parameter,code/removal/advanced,!field/*. However, they can't use those flags since it makes their app much less secure and bigger in size.

The client is able to generate the release build of their app without problems. However, when they try to open the app, it ends up being unresponsive (ANR).

Discussion

  • T. Neidhart

    T. Neidhart - 2019-12-05
    • status: open --> closed
    • Priority: 9 --> High
     
  • T. Neidhart

    T. Neidhart - 2019-12-05

    Pre-obfuscated code should not be optimized.
    In order to disable optimization you can specify a keep rule like that:

    -keep,allowobfuscation,allowshrinking,includecode class xxx.yyy.* { ; }

    where xxx.yyy is the base package name of the library.

     

Log in to post a comment.