proguard

Does ProGuard work with JavaEE 6 applications?

谁说我不能喝 提交于 2019-12-06 07:32:21
问题 I'm trying to get Proguard to obfuscate a simple .war file. According to the docs Proguard handles .war files, but when I try I get this: Warning: class [WEB-INF/classes/com/corp/gr/t2b/T2BChannel.class] unexpectedly contains class [com.corp.gr.t2b.T2BChannel] The docs mention something about Proguard not liking .war files with classes in the WEB-INF/classes directory. So I put all the .class files in their own .jar file in WEB-INF/lib. Then Proguard complains that it cannot find any of the

Proguard problems with apk creation

此生再无相见时 提交于 2019-12-06 07:32:15
OK This is driving me nuts since a day. I am mainly an iOS guy so i dont know much about Proguard and stuff. I have made an Android app which includes both dropbox and Google Drive API. The app is working great if i deploy it on a phone thru Eclipse but I am getting a nasty error on Console when i try to export the app for apk file generation. My project.properties files was like so... # To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home): proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt:proguard

Upgraded to Android Studio 1.0 & Gradle 1.0.0, aapt makes PNG images larger if pre-optimized

折月煮酒 提交于 2019-12-06 07:23:41
I performed an upgrade to Android Studio 1.0 & Gradle 1.0.0 today, from Android Studio 0.86 & Gradle 0.13. Prior to the upgrade, I was using "runProguard = true" option in my release builds extensively, to reduce my APK size to just under 50 MB, to meet Google Play Store's APK size restrictions. However, with the new Android Studio 1.0 / Gradle 1.0.0 with "minifyEnabled = true", I am seeing resulting APKs at 55.6 MB, which is significantly larger than before. The debug build APKs are resulting in 55.6 MB as well, leaving me to conclude that the minifyEnabled option isn't actually working. I've

ProGuard JNI Error

烈酒焚心 提交于 2019-12-06 07:16:28
I'm using ProGuard to obfuscate my Java Desktop application. When I launch the obfuscated JAR , I'm getting the following error: > java -jar program.jar Error: A JNI error has occurred, please check your installation and try again Exception in thread "main" java.lang.VerifyError: Expecting a stackmap frame at branch target 80 Exception Details: Location: MyMainClass.a(Ljava/lang/String;)Ljava/lang/String; @40: iflt Reason: Expected stackmap frame at this location. Bytecode: 0x0000000: 0406 7805 0882 8206 0882 0778 0482 0659 0x0000010: 7808 822a b600 0f59 bc05 0459 585f 0464 0x0000020: 5b3e

Android Proguard - is it best practice to -keep all 3rd party libs?

女生的网名这么多〃 提交于 2019-12-06 06:03:24
问题 I'm configuring Proguard for an app that uses 3rd party libraries. Is it "best practice" (in order to avoid future hard-to-find bugs) to include the line: -keep class 3rd_party_lib_name.** {*;} for every single 3rd party open source library that doesn't have specific Proguard instructions from its developer? Also, a related question: is there a general guideline for which cases I should use -keep class and in which cases i should use -keep public class many thanks 回答1: The major problem with

Getting MultiDex Error, even after setting Min SDK 21

北城余情 提交于 2019-12-06 05:32:48
问题 The project i am working on has around 180k Methods. I have read blogs, and articles where its written that if you set your Min SDK to 21 , then you don't need MultiDex . But if i remove MultiDex from here it gives me the 65k MultiDex error message. Following is my gradle file. I don't know whether i failed to understand the concept or something else. Kindly guide me. compileSdkVersion 23 buildToolsVersion "23.0.3" defaultConfig { applicationId 'com.myapp.app' minSdkVersion 21

Android Proguard SqlCipher NoClassDefFoundError

谁说我不能喝 提交于 2019-12-06 04:29:29
问题 Have been battling with Proguard all day and have tried many examples and solutions on the official Proguard site as well as StackOverflow. I have a large project I need to obfuscate, which has a number of referenced library projects and Jars. I am getting 725 warnings from proguard from 2 libs, com.google.common and twitter4j. I can happily get the project to compile if I add the following: -dontwarn com.google.common.** -dontwarn twitter4j.** However, the app crashes instantly on open, so

how to use -assumenosideeffects class android.util.Log in my app

橙三吉。 提交于 2019-12-06 04:20:11
问题 I write -assumenosideeffects class android.util.Log in my app. but how to use this. -assumenosideeffects class android.util.Log { public static int d(...); public static int v(...); public static int i(...); public static int e(...); } in proguard.cfg file. but not working. 回答1: The manual says -assumenosideffects is "Only applicable when optimizing" . ${sdk.dir}/tools/proguard/proguard-android.txt says: "Optimization is turned off by default. Dex does not like code run through the ProGuard

Android Studio - ProGuard IOException Duplicate Zip Entry

对着背影说爱祢 提交于 2019-12-06 04:03:00
问题 So I am trying to set up ProGuard in Gradle for my Android Studio project and I get the following error when building the project: Error:Execution failed for task ':app:proguardDebug'. java.io.IOException: Can't write [C:\Users\Rich\Desktop\WebProjects\AndroidStudioProjects\Roomie\app\build\intermediates\classes-proguard\debug\classes.jar] (Can't read C:\Users\Rich\Desktop\WebProjects\AndroidStudioProjects\Roomie\app\libs\bolts-android-1.1.4.jar(;;;;;;!META-INF/MANIFEST.MF)] (Duplicate zip

i want to obfuscate AndroidManifest.xml with Proguard

删除回忆录丶 提交于 2019-12-06 03:53:14
Can i obfuscate AndroidManifest.xml file with Proguard? i think write to source code in my proguard.config file. (-adaptresourcefilenames AndroidManifest.xml) but it wasn't work. The standard Android release builds only apply ProGuard to the compiled bytecode, not to any resource files. It therefore can't adapt files like AndroidManifest.xml. Moreover, these build processes first run aapt to convert AndroidManifest.xml and other XML files to binary versions, for more efficient packaging and use. Aapt also writes out some configuration for ProGuard. ProGuard can only parse and adapt resource