微信资源包混淆

时间:2019-02-07 14:57:41   收藏:0   阅读:193

微信资源包混淆项目:https://github.com/shwenzhang/AndResGuard

 技术图片

 

资源包混淆作用

* 1.避免其他人拷贝图片资源

* 2.把apk变小(apk瘦身步骤)

开发中到底用不用:看需求,可以使用资源包混淆,

1.配置config.xml文件

<issue id="sign" isactive="true">

    <!--the signature file path, in window use \, in linux use /, and the default path is the running location-->

    <path value="E:\ngyb\day2\MobileSafe\ngyb.jks"/>

    <!--storepass-->

    <storepass value="123456"/>

    <!--keypass-->

    <keypass value="123456"/>

    <!--alias-->

    <alias value="ngyb"/>

</issue>

 

2.简单命令(对签名和未签名apk都可以)

java -jar andresguard.jar ..\build\MobileSafe_signed.apk

 

3.指定配置文件或输出目录

java -jar andresguard.jar ..\build\MobileSafe_signed.apk -config config.xml -out ngyb

 

4.使用7zip打包

java -jar andresguard.jar ..\build\MobileSafe_signed.apk -config config.xml

-7zip 7za.exe -out ngyb_new

 

 

<!-- 任务9:集成微信资源包混淆AndResGuard -->

<target name="andResGuard" depends="generateUnsignedApk">

    <echo message="任务9:微信资源包混淆"/>

    <exec executable="${java.exe}">

        <arg value="-jar"/>

        <arg value="${andresguard.jar}"/>

        <arg value="${unsignedApk}"/>

        <arg value="-config"/>

        <arg value="${config.xml}"/>

        <arg value="-out"/>

        <arg value="${resGuardOut}"/>

    </exec>

</target>

 

评论(0
© 2014 mamicode.com 版权所有 京ICP备13008772号-2  联系我们:gaon5@hotmail.com
迷上了代码!