apk anti-compilation go to adsSpecific steps:
1. Download Apktool
: https://code.google.com/p/android-apktool/downloads/list
2. Decompile the APK with Apktool. On the command line, enter the following command: Apktool.bat d-f aaa.apk (apk Path) anti-compilation apk file
3. Start modifying the XML layout file
First, let's go to the anti-compiled folder, take my example
Enter the C:\apk\com.youmi.android.sample\res\layout directory
Open Activity_ad.xml with Notepad (note: Different program ads are located in the same file, you can view the other files, usually in the Res\layout directory in the XML file. )
You can see the following section of code
<linearlayout
Android:id= "@+id/adlayout"
Android:layout_width= "Fill_parent"
android:layout_height= "Wrap_content"
Android:layout_alignparentbottom= "true"
Android:gravity= "Center_horizontal"
android:orientation= "Horizontal"
>
This code is used to display the ads we can change to
<linearlayout
Android:id= "@+id/adlayout"
Android:layout_width= "Fill_parent"
android:layout_height= "Wrap_content"
Android:layout_alignparentbottom= "true"
Android:gravity= "Center_horizontal"
android:orientation= "Horizontal"
Android:visibility= "Gone"
>
So the ads are hidden.
4. Compile the modified code by Apktool apk, enter Apktool.bat b aaa (you compiled the folder)
5. Finally, remember to sign the new apk.
Sign apk file:jarsigner-keystore test.keystore-storepass password-verbose testapp-unsigned.apk Name_alias
Appendix
Jarsigner command Explanation
[-keystore <url>] KeyStore location
[-storepass < password;] Password for KeyStore integrity
[-storetype < type;] KeyStore type
[-keypass < password;] Password for private key (if different)
[-sigfile < documents;]. sf/. The name of the DSA file
[-signedjar < file;] Name of the signed JAR file
[-digestalg < algorithm;] The name of the digest algorithm
[-sigalg < algorithm;] The name of the signature algorithm
[-verify] Validating a signed JAR file
[-verbose] Output details when signing/validating
[-certs] Output details and certificate display when validating
[-tsa <url>] location of the timestamp mechanism
[-tsacert < aliases;] The public key certificate for the timestamp mechanism
[-altsigner <] class name of an alternative signature mechanism
[-altsignerpath < path list;] The location of the replacement signature mechanism
[-INTERNALSF] is contained within the signature block. SF file
[-sectionsonly] does not calculate the hash of the entire manifest
[-protected] KeyStore protected authentication Path
[-providername < name;] Provider Name
[-providerclass < class > name of the cryptographic service provider
[-providerarg < parameters;]] ... Main class file and constructor parameters
APK anti-compilation to advertise big secret