The tool of obfuscated aab resources.(Android app bundle资源混淆工具)
Java
1,388
93 commits
updated Nov 25, 2021
The tool of obfuscated aab resources
Powered by bytedance douyin android team.
The tool of obfuscated aab resources.
bundle package. Currently only supports filtering in the MATE-INFO/ and lib/ paths.mapping file to support incremental obfuscation.AabResGuard is a resource obfuscation tool powered by the douyin Android team. It has been launched at the end of July 2018 in several overseas products, such as Tiktok, Vigo, etc. There is no feedback on related resource issues. For more data details, please go to Data of size savings.
gradle plugin, using the original packaging command to execute obfuscation.Configured in build.gradle(root project)
buildscript {
repositories {
mavenCentral()
jcenter()
google()
}
dependencies {
classpath "com.bytedance.android:aabresguard-plugin:0.1.0"
}
}
Configured in build.gradle(application)
apply plugin: "com.bytedance.android.aabResGuard"
aabResGuard {
mappingFile = file("mapping.txt").toPath() // Mapping file used for incremental obfuscation
whiteList = [ // White list rules
"*.R.raw.*",
"*.R.drawable.icon"
]
obfuscatedBundleFileName = "duplicated-app.aab" // Obfuscated file name, must end with '.aab'
mergeDuplicatedRes = true // Whether to allow the merge of duplicate resources
enableFilterFiles = true // Whether to allow filter files
filterList = [ // file filter rules
"*/arm64-v8a/*",
"META-INF/*"
]
enableFilterStrings = false // switch of filter strings
unusedStringPath = file("unused.txt").toPath() // strings will be filtered in this file
languageWhiteList = ["en", "zh"] // keep en,en-xx,zh,zh-xx etc. remove others.
}
The aabResGuard plugin intrudes the bundle packaging process and can be obfuscated by executing the original packaging commands.
./gradlew clean :app:bundleDebug --stacktrace
Get the obfuscated bundle file path by gradle .
def aabResGuardPlugin = project.tasks.getByName("aabresguard${VARIANT_NAME}")
Path bundlePath = aabResGuardPlugin.getObfuscatedBundlePath()
The resources that can not be confused. Welcome PR your configs which is not included in WHITELIST
AabResGuard provides a jar file that can be executed directly from the command line. More details, please go to Command Line.
After the packaging is completed, the obfuscated file and the log files will be output. More details, please go to Output File.
Version change log. More details, please go to Change Log .
Read the details to learn how to participate in the improvement AabResGuard.
2,591 followers · starred Apr 2022
14 followers · starred Nov 2021
31 followers · starred Aug 2021
53 followers · starred Sep 2020
The tool of obfuscated aab resources.(Android app bundle资源混淆工具)
Java
1,388
93 commits
updated Nov 25, 2021
The tool of obfuscated aab resources
Powered by bytedance douyin android team.
The tool of obfuscated aab resources.
bundle package. Currently only supports filtering in the MATE-INFO/ and lib/ paths.mapping file to support incremental obfuscation.AabResGuard is a resource obfuscation tool powered by the douyin Android team. It has been launched at the end of July 2018 in several overseas products, such as Tiktok, Vigo, etc. There is no feedback on related resource issues. For more data details, please go to Data of size savings.
gradle plugin, using the original packaging command to execute obfuscation.Configured in build.gradle(root project)
buildscript {
repositories {
mavenCentral()
jcenter()
google()
}
dependencies {
classpath "com.bytedance.android:aabresguard-plugin:0.1.0"
}
}
Configured in build.gradle(application)
apply plugin: "com.bytedance.android.aabResGuard"
aabResGuard {
mappingFile = file("mapping.txt").toPath() // Mapping file used for incremental obfuscation
whiteList = [ // White list rules
"*.R.raw.*",
"*.R.drawable.icon"
]
obfuscatedBundleFileName = "duplicated-app.aab" // Obfuscated file name, must end with '.aab'
mergeDuplicatedRes = true // Whether to allow the merge of duplicate resources
enableFilterFiles = true // Whether to allow filter files
filterList = [ // file filter rules
"*/arm64-v8a/*",
"META-INF/*"
]
enableFilterStrings = false // switch of filter strings
unusedStringPath = file("unused.txt").toPath() // strings will be filtered in this file
languageWhiteList = ["en", "zh"] // keep en,en-xx,zh,zh-xx etc. remove others.
}
The aabResGuard plugin intrudes the bundle packaging process and can be obfuscated by executing the original packaging commands.
./gradlew clean :app:bundleDebug --stacktrace
Get the obfuscated bundle file path by gradle .
def aabResGuardPlugin = project.tasks.getByName("aabresguard${VARIANT_NAME}")
Path bundlePath = aabResGuardPlugin.getObfuscatedBundlePath()
The resources that can not be confused. Welcome PR your configs which is not included in WHITELIST
AabResGuard provides a jar file that can be executed directly from the command line. More details, please go to Command Line.
After the packaging is completed, the obfuscated file and the log files will be output. More details, please go to Output File.
Version change log. More details, please go to Change Log .
Read the details to learn how to participate in the improvement AabResGuard.
2,591 followers · starred Apr 2022
14 followers · starred Nov 2021
31 followers · starred Aug 2021
53 followers · starred Sep 2020