Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lib_base
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
sikang
lib_base
Commits
c9e37c37
Commit
c9e37c37
authored
Mar 28, 2019
by
sikang
1
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
up
parent
47f096dd
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
15 deletions
+20
-15
script/garble/insert.py
+11
-14
script/script_help.sh
+9
-1
No files found.
script/garble/insert.py
View file @
c9e37c37
...
...
@@ -6,7 +6,6 @@ import glob, os
import
sys
used_names
=
[]
activity_mangle_setting
=
{}
# rand string for class names
...
...
@@ -64,21 +63,18 @@ def process_file_content(path, file_name):
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
print
(
"processing file content..."
)
for
root
,
dirs
,
files
in
os
.
walk
(
source_root
):
for
root
,
dirs
,
files
in
os
.
walk
(
"../../../app/src/main"
):
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
)
for
file
in
files
:
if
file
.
endswith
(
".java"
):
...
...
@@ -86,4 +82,5 @@ for root, dirs, files in os.walk(source_root):
path
=
os
.
path
.
join
(
directory
,
file
)
process_file_content
(
path
,
file
)
print
(
"processing file content done"
)
script/script_help.sh
View file @
c9e37c37
...
...
@@ -9,7 +9,9 @@ echo "6、pull UI代码 "
echo
"7、为 resGuardApks 目录下的 *_release.apk 打渠道包"
echo
"8、提交一个渠道包Tag"
echo
"9、开始四大组件混淆"
echo
"10、还原四大组件混淆"
echo
"10、插入乱码"
echo
"11、还原代码"
echo
-n
"请输入指令编号:"
read
commod
...
...
@@ -67,6 +69,12 @@ then
elif
((
$commod
==
'10'
))
then
cd
garble
chmod a+x insert.sh
./insert.sh
elif
((
$commod
==
'11'
))
then
cd
garble
chmod a+x reset_name.sh
./reset_name.sh
...
...
sikang
@sikang
mentioned in commit
1c564f4f
Mar 29, 2019
mentioned in commit
1c564f4f
mentioned in commit 1c564f4f9dd76340450e1ac60c0e99d70eabd277
Toggle commit list
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment