android-proguard

Class no longer obfuscated after upgrading to Android Gradle plugin 3.4.0

怎甘沉沦 提交于 2019-12-10 10:39:04
问题 After upgrading to Android Gradle plugin 3.4.0, a basic class no longer gets obfuscated. The following basic steps can reproduce the problem: In Android Studio create a new empty project In app/build.gradle change minifyEnabled to true Create the following class, ProguardTestClass.java : public class ProguardTestClass { public interface ProguardTestInnerInterface { void proguardTestCallback(String message); } public static void proguardTestMethod(String input, ProguardTestInnerInterface impl)

Several new Proguard issues Google Play services v10.2.6 to v11.0.0 in a Multidex project

做~自己de王妃 提交于 2019-12-10 03:23:02
问题 I updated our app to use the most recent Android Firebase SDK v11.0.0 (https://firebase.google.com/support/release-notes/android#20170607) and out of the suddenly we bunch of new proguard errors appear, FYI everything was working well before with proguard. Before: compile 'com.google.firebase:firebase-messaging:10.2.6' compile 'com.google.android.gms:play-services-vision:10.2.6' After: compile 'com.google.firebase:firebase-messaging:11.0.0' compile 'com.google.android.gms:play-services-vision

How to keep Google Maps in obfuscation?

别来无恙 提交于 2019-12-08 04:03:44
问题 I have implemented Google Maps (Google API) in my application. So I added ProGuard file inside my application. After adding the Proguard file, the map is not opening, and showing a white blank screen. This is my Proguard code: -keep class * implements com.google.android.gms.maps { *; } -keep class com.google.android.gms.maps.** { *; } -keep interface com.google.android.gms.maps.** { *; } I have tried this, but it's not working. 回答1: The Google Maps API uses some other stuff as well which can

Proguard unresolved references to classes

喜你入骨 提交于 2019-12-08 02:03:59
问题 When building apk using Proguard, I see theses Warnings: com.google.android.gms.internal.zzaq: can't find referenced class com.google.android.gms.internal.zzzk com.google.android.gms.internal.zzaq: can't find referenced class com.google.android.gms.internal.zzzk$zza com.google.android.gms.internal.zzaq: can't find referenced class com.google.android.gms.internal.zzzk com.google.android.gms.internal.zzaq: can't find referenced class com.google.android.gms.internal.zzzk$zza com.google.android

Android Library module use proguard

二次信任 提交于 2019-12-07 19:30:20
问题 I want to create secure library module that no one can extract code from apk file. but when try to enable proguard in library gradle getting error package does not exists. then i add following line in proguard rules file -keep class com.alprocr.** { *; } -keep class com.xyz.alpr.** { *; } -keep class com.xyz.alpr.doc.** { *; } after add this code app working file. but when i extract code from apk using apktool then i got complete source code from apk file. I want non-readable code when

How to remove Log.d() calls in release build of an Android app?

为君一笑 提交于 2019-12-07 15:36:19
问题 I have noticed that my release build, which i made in eclipse via: Android Tools -> Export signed application package ... My proguard-project.txt contains: -assumenosideeffects class android.util.Log { public static boolean isLoggable(java.lang.String, int); public static int v(...); public static int i(...); public static int w(...); public static int d(...); public static int e(...); } Yet, if I run the app on a device und use CatLog to look at logs I see that there are all the Log.d(), Log

Too many method references in android library project - ClassNotFoundException

流过昼夜 提交于 2019-12-07 10:54:00
问题 I have library project which I am using in main android project using AAR file. I am getting the famous 65k method limit now which I have expected, but I have few queries. I have added AAR file in libs folder of my main project and compiled the same in build.gradle. 1) Do I need to add multi-dex support in both library as well as main android project? 2) Do I need to add afterEvaluate script in both project? Most importantly if we got multi-dex working, we might get issue that in main android

Proguard - also use proguard files from modules

瘦欲@ 提交于 2019-12-07 01:40:30
问题 My projects build.gradle looks like following: android { compileSdkVersion 22 buildToolsVersion "22.0.1" defaultConfig { applicationId "..." minSdkVersion 15 targetSdkVersion 22 versionCode 1 versionName "1.0" } buildTypes { release { minifyEnabled true proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' } } } dependencies { compile project(':androKnife') } And my androKnife module does have it's own proguard file. How can I make my main project use this file as

what is the difference between -keep class and -dontwarn

不问归期 提交于 2019-12-06 23:04:30
问题 Hey I'm new with proGuard , I use it to protect my code from reverse engineering , but when I built my signed apk I got a lot of errors when I enabled proGuard ,I have googled my problem I've found answers that says use -dontwarn for the classes that showing in the error message but after seeing the documentation from proGuard it says If you don't feel like filtering out the problematic classes, you can try your luck with the -ignorewarnings option, or even the -dontwarn option. Only use

Signed apk getting crashed in proguard enable

左心房为你撑大大i 提交于 2019-12-06 20:58:15
问题 I am trying to use proguard in my app set the proguard to true and then the problem starts I am importing lib when I use proguard by following this -keepnames class com.somepackage.* with my package name the app is getting getting crashed when I try to use the signed apk. I know this iS a dumb question but I am stuck at this for last 5 hr not able to find an easy solution as I am using about 20 lib. I followed this also. Plz guide me in this how can I do this? This is my proguard rule class