Commit c9e37c37 by sikang

up

parent 47f096dd
...@@ -6,7 +6,6 @@ import glob, os ...@@ -6,7 +6,6 @@ import glob, os
import sys import sys
used_names = [] used_names = []
activity_mangle_setting = {}
# rand string for class names # rand string for class names
...@@ -64,21 +63,18 @@ def process_file_content(path, file_name): ...@@ -64,21 +63,18 @@ def process_file_content(path, file_name):
return return
# read configs
with open('obact.json', "rt") as f:
json_root = json.load(f)
activities = json_root["activities"]
source_root = json_root["root"]
manifest = json_root["manifest"]
# mangle activity names
for act_name in activities:
activity_mangle_setting[act_name] = gen_rand_str()
root_path = os.path.join(os.getcwd(), source_root)
# perform content replace for the files # perform content replace for the files
print("processing file content...") for root, dirs, files in os.walk("../../../app/src/main"):
for root, dirs, files in os.walk(source_root): directory = os.path.join(os.getcwd(), root)
for file in files:
if file.endswith(".java"):
# get the path of the java file
path = os.path.join(directory, file)
process_file_content(path, file)
for root, dirs, files in os.walk("../../../lib_base/src/main"):
directory = os.path.join(os.getcwd(), root) directory = os.path.join(os.getcwd(), root)
for file in files: for file in files:
if file.endswith(".java"): if file.endswith(".java"):
...@@ -86,4 +82,5 @@ for root, dirs, files in os.walk(source_root): ...@@ -86,4 +82,5 @@ for root, dirs, files in os.walk(source_root):
path = os.path.join(directory, file) path = os.path.join(directory, file)
process_file_content(path, file) process_file_content(path, file)
print("processing file content done") print("processing file content done")
...@@ -9,7 +9,9 @@ echo "6、pull UI代码 " ...@@ -9,7 +9,9 @@ echo "6、pull UI代码 "
echo "7、为 resGuardApks 目录下的 *_release.apk 打渠道包" echo "7、为 resGuardApks 目录下的 *_release.apk 打渠道包"
echo "8、提交一个渠道包Tag" echo "8、提交一个渠道包Tag"
echo "9、开始四大组件混淆" echo "9、开始四大组件混淆"
echo "10、还原四大组件混淆" echo "10、插入乱码"
echo "11、还原代码"
echo -n "请输入指令编号:" echo -n "请输入指令编号:"
read commod read commod
...@@ -67,6 +69,12 @@ then ...@@ -67,6 +69,12 @@ then
elif (($commod == '10')) elif (($commod == '10'))
then then
cd garble cd garble
chmod a+x insert.sh
./insert.sh
elif (($commod == '11'))
then
cd garble
chmod a+x reset_name.sh chmod a+x reset_name.sh
./reset_name.sh ./reset_name.sh
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment