consumer-rules.pro 4.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157
  1. -keepclassmembers class * {
  2. @com.tencent.luggage.wxa.SaaA.plugin.SyncJsApi *;
  3. @com.tencent.luggage.wxa.SaaA.plugin.AsyncJsApi *;
  4. }
  5. -keep class com.donut.plugin.* {*;}
  6. # Add project specific ProGuard rules here.
  7. # You can control the set of applied configuration files using the
  8. # proguardFiles setting in build.gradle.
  9. #
  10. # For more details, see
  11. # http://developer.android.com/guide/developing/tools/proguard.html
  12. # If your project uses WebView with JS, uncomment the following
  13. # and specify the fully qualified class name to the JavaScript interface
  14. # class:
  15. -keepclassmembers class fqcn.of.javascript.interface.for.webview {
  16. public *;
  17. }
  18. # Uncomment this to preserve the line number information for
  19. # debugging stack traces.
  20. -keepattributes SourceFile,LineNumberTable
  21. # If you keep the line number information, uncomment this to
  22. # hide the original source file name.
  23. -renamesourcefileattribute SourceFile
  24. # 屏蔽警告
  25. -ignorewarnings
  26. # 指定混淆是采用的算法,后面的参数是一个过滤器
  27. # 这个过滤器是谷歌推荐的算法,一般不做更改
  28. -optimizations !code/simplification/arithmetic,!field/*,!class/merging/*
  29. # 保护代码中的Annotation不被混淆
  30. -keepattributes *Annotation*
  31. # 避免混淆泛型, 这在JSON实体映射时非常重要
  32. -keepattributes Signature
  33. # 抛出异常时保留代码行号
  34. -keepattributes SourceFile,LineNumberTable
  35. #优化时允许访问并修改有修饰符的类和类的成员,这可以提高优化步骤的结果。
  36. # 比如,当内联一个公共的getter方法时,这也可能需要外地公共访问。
  37. # 虽然java二进制规范不需要这个,要不然有的虚拟机处理这些代码会有问题。当有优化和使用-repackageclasses时才适用。
  38. #指示语:不能用这个指令处理库中的代码,因为有的类和类成员没有设计成public ,而在api中可能变成public
  39. -allowaccessmodification
  40. #当有优化和使用-repackageclasses时才适用。
  41. #-repackageclasses com.test
  42. # 混淆时记录日志(打印混淆的详细信息)
  43. # 这句话能够使我们的项目混淆后产生映射文件
  44. # 包含有类名->混淆后类名的映射关系filename.txt
  45. ##-classobfuscationdictionary filename.txt
  46. ##-packageobfuscationdictionary f
  47. #-obfuscationdictionary ilename.txt
  48. -verbose
  49. -keep class .R -keepclasseswithmembers class *.R$* { public static <fields>;}
  50. # 保留枚举类不被混淆
  51. -keepclassmembers enum * {
  52. public static **[] values();
  53. public static ** valueOf(java.lang.String);
  54. }
  55. -keep public class android.net.http.SslError
  56. -keep public class android.webkit.WebViewClient
  57. -dontwarn android.webkit.WebView
  58. -dontwarn android.net.http.SslEr
  59. -dontwarn android.webkit.WebViewClient
  60. #--------------ludp和oaid资源混淆忽略-------start#
  61. -keep class com.lenovo.lps.reaper.**{*;}
  62. -keep class com.lenovo.lps.reaper.*$* {
  63. *;
  64. }
  65. -dontwarn com.lenovo.lps.reaper.**
  66. -keep class org.greenrobot.greendao.**{*;}
  67. -keep class org.greenrobot.greendao.*$* {
  68. *;
  69. }
  70. -dontwarn org.greenrobot.greendao.**
  71. -keep class com.lenovo.lsf.gamesdk.oaid.** { *; }
  72. -keep class com.lenovo.lsf.gamesdk.oaid.*$* { *; }
  73. -keep class com.asus.msa.**{*;}
  74. -keep class com.asus.msa.*$* {
  75. *;
  76. }
  77. -keep class com.bun.**{*;}
  78. -keep class com.bun.*$* {
  79. *;
  80. }
  81. -keep class com.huawei.hms.ads.identifier.**{*;}
  82. -keep class com.huawei.hms.ads.identifier.*$* {
  83. *;
  84. }
  85. -keep class com.netease.nis.sdkwrapper.**{*;}
  86. -keep class com.netease.nis.sdkwrapper.*$* {
  87. *;
  88. }
  89. -keep class com.samsung.android.deviceidservice.**{*;}
  90. -keep class com.samsung.android.deviceidservice.*$* {
  91. *;
  92. }
  93. -keep class com.zui.**{*;}
  94. -keep class com.zui.*$* {
  95. *;
  96. }
  97. -dontwarn com.asus.msa.**
  98. -dontwarn com.bun.**
  99. -dontwarn com.huawei.hms.ads.identifier.**
  100. -dontwarn com.netease.nis.sdkwrapper.**
  101. -dontwarn com.samsung.android.deviceidservice.**
  102. -dontwarn com.zui.**
  103. #--------------ludp和oaid资源混淆忽略-------end#
  104. #--------------支付资源混淆忽略-------start#
  105. -keep class com.google.zxing.**{*;}
  106. -keep class com.google.zxing.*$* {
  107. *;
  108. }
  109. -dontwarn com.google.zxing.**
  110. -dontwarn com.alipay.**
  111. -keep class com.alipay.**{*;}
  112. -keep class org.json.alipay.**{*;}
  113. -keep class org.json.alipay.*$* {
  114. *;
  115. }
  116. -dontwarn org.json.alipay.**
  117. #--------------支付资源混淆忽略-------end#
  118. #--------------lenovoId源混淆忽略-------start#
  119. -keep class com.lenovo.lsf.**{*;}
  120. -keep class com.lenovo.lsf.*$* {
  121. *;
  122. }
  123. -dontwarn com.lenovo.lsf.**
  124. #--------------lenovoId源混淆忽略-------end#
  125. -keep class com.lenovo.intermodal.bean.**{*;}
  126. -keep class com.lenovo.intermodal.bean.*$* {
  127. *;
  128. }
  129. -dontwarn com.lenovo.intermodal.bean.**
  130. -keep class com.lenovo.intermodal.api.**{*;}
  131. -keep class com.lenovo.intermodal.api.*$* {
  132. *;
  133. }
  134. -dontwarn com.lenovo.intermodal.api.**
  135. -keep class com.lenovo.intermodal.request.**{*;}
  136. -keep class com.lenovo.intermodal.request.*$* {
  137. *;
  138. }
  139. -dontwarn com.lenovo.intermodal.request.**