1.Gson混淆
創(chuàng)新互聯(lián)建站長(zhǎng)期為近1000家客戶(hù)提供的網(wǎng)站建設(shè)服務(wù),團(tuán)隊(duì)從業(yè)經(jīng)驗(yàn)10年,關(guān)注不同地域、不同群體,并針對(duì)不同對(duì)象提供差異化的產(chǎn)品和服務(wù);打造開(kāi)放共贏平臺(tái),與合作伙伴共同營(yíng)造健康的互聯(lián)網(wǎng)生態(tài)環(huán)境。為衛(wèi)輝企業(yè)提供專(zhuān)業(yè)的網(wǎng)站設(shè)計(jì)、網(wǎng)站制作,衛(wèi)輝網(wǎng)站改版等技術(shù)服務(wù)。擁有十余年豐富建站經(jīng)驗(yàn)和眾多成功案例,為您定制開(kāi)發(fā)。
## ---------------------------------- ## ########## Gson混淆 ########## ## ---------------------------------- -keepattributes Signature -keep class sun.misc.Unsafe { *; } -keep class com.google.gson.examples.android.model.** { *; }
2.greenDao混淆
# # ------------------------------------------- # # ######## greenDao混淆 ########## # # ------------------------------------------- -keep class com.manjay.housebox.greendao.** {*;} -keepclassmembers class * extends de.greenrobot.dao.AbstractDao { public static java.lang.String TABLENAME; } -keep class **$Properties
3.volley混淆
# # ------------------------------------------- # # ############### volley混淆 ############### # # ------------------------------------------- -keep class com.android.volley.** {*;} -keep class com.android.volley.toolbox.** {*;} -keep class com.android.volley.Response$* { *; } -keep class com.android.volley.Request$* { *; } -keep class com.android.volley.RequestQueue$* { *; } -keep class com.android.volley.toolbox.HurlStack$* { *; } -keep class com.android.volley.toolbox.ImageLoader$* { *; }
4.sharesdk混淆
## ---------------------------------- ## sharesdk ## ---------------------------------- -keep class cn.sharesdk.**{*;} -keep class com.sina.**{*;} -keep class **.R$* {*;} -keep class **.R{*;} -dontwarn cn.sharesdk.** -dontwarn **.R$*
5.UIL混淆
## ---------------------------------- ## UIL相關(guān) ## ---------------------------------- -keep class com.nostra13.universalp_w_picpathloader.** { *; } -keepclassmembers class com.nostra13.universalp_w_picpathloader.** {*;}
6.高德地圖sdk混淆
## ---------------------------------- ## 高德地圖sdk混淆 ## ---------------------------------- -libraryjars libs/android-support-v4.jar -dontwarn android.support.v4.** -keep class android.support.v4.** { *; } -keep interface android.support.v4.app.** { *; } -keep public class * extends android.support.v4.** -keep public class * extends android.app.Fragment -libraryjars libs/MapApiLocation.jar -libraryjars libs/MapApiSearch.jar -libraryjars libs/Android_Map_V2.0.4.jar -dontwarn com.amap.api.** -dontwarn com.a.a.** -dontwarn com.autonavi.** -keep class com.amap.api.** {*;} -keep class com.autonavi.** {*;} -keep class com.a.a.** {*;}
7.unity混淆(需要修改proguard.jar文件)
## --------------------------------------------------------------- ## unity混淆(需要修改proguard.jar文件) ## --------------------------------------------------------------- -libraryjars f:/work_hb_v021/Lib_SocShare_v237_0804/libs/untiy-classes.jar -dontwarn com.unity3d.player.** -dontwarn org.fmod.** -keep class com.unity3d.player.**{*;} -keep class org.fmod.**{*;} -keep public class * extends com.unity3d.player.** -keep public class * extends org.fmod.**
注:還需要對(duì)與unity交互的相關(guān)方法或者類(lèi)(jni)進(jìn)行混淆配置。
8.內(nèi)部類(lèi)或者內(nèi)部接口類(lèi)的混淆配置
# # ------------------------------------------- # # ######## 內(nèi)部類(lèi)混淆配置 ########## # # ------------------------------------------- -keep class com.manjay.housebox.activity.CityListActivity$*{ <fields>; <methods>; } -keepclassmembers class com.manjay.housebox.activity.CityListActivity$*{*;} -keep class com.manjay.housebox.map.MapActivity$*{ <fields>; <methods>; } -keepclassmembers class com.manjay.housebox.map.MapActivity$*{*;}
參考資料:
1.Android項(xiàng)目:proguard混淆之常見(jiàn)開(kāi)源項(xiàng)目混淆配置
2.Android項(xiàng)目:proguard混淆之常見(jiàn)問(wèn)題及解決方法匯總
3.Android項(xiàng)目:自構(gòu)框架、SDK包或者jar文件庫(kù)的混淆及常見(jiàn)問(wèn)題解決方法
網(wǎng)頁(yè)名稱(chēng):Android項(xiàng)目:proguard混淆之常見(jiàn)開(kāi)源項(xiàng)目混淆配置
網(wǎng)站地址:http://muchs.cn/article12/jpdcgc.html
成都網(wǎng)站建設(shè)公司_創(chuàng)新互聯(lián),為您提供品牌網(wǎng)站建設(shè)、云服務(wù)器、動(dòng)態(tài)網(wǎng)站、全網(wǎng)營(yíng)銷(xiāo)推廣、關(guān)鍵詞優(yōu)化、標(biāo)簽優(yōu)化
聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶(hù)投稿、用戶(hù)轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請(qǐng)盡快告知,我們將會(huì)在第一時(shí)間刪除。文章觀點(diǎn)不代表本網(wǎng)站立場(chǎng),如需處理請(qǐng)聯(lián)系客服。電話(huà):028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時(shí)需注明來(lái)源: 創(chuàng)新互聯(lián)