Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
S
SandHook
Project
Project
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
SandHook
Commits
9da3357a
Commit
9da3357a
authored
Jan 24, 2019
by
swift_gan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kill inline
parent
b2099376
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
4 deletions
+6
-4
ActivityHooker.java
...src/main/java/com/swift/sandhook/test/ActivityHooker.java
+6
-4
No files found.
app/src/main/java/com/swift/sandhook/test/ActivityHooker.java
View file @
9da3357a
...
@@ -24,25 +24,27 @@ public class ActivityHooker {
...
@@ -24,25 +24,27 @@ public class ActivityHooker {
@HookMethod
(
"onCreate"
)
@HookMethod
(
"onCreate"
)
@MethodParams
(
Bundle
.
class
)
@MethodParams
(
Bundle
.
class
)
public
static
void
onCreate
(
Activity
thiz
,
Bundle
bundle
)
{
public
static
void
onCreate
(
Activity
thiz
,
Bundle
bundle
)
{
Log
.
e
(
"ActivityHooker"
,
"hooked onCreate success "
+
thiz
);
Log
.
e
(
"ActivityHooker"
,
"hooked onCreate success "
+
thiz
.
hashCode
()
);
onCreateBackup
(
thiz
,
bundle
);
onCreateBackup
(
thiz
,
bundle
);
}
}
@HookMethodBackup
(
"onCreate"
)
@HookMethodBackup
(
"onCreate"
)
@MethodParams
(
Bundle
.
class
)
@MethodParams
(
Bundle
.
class
)
public
static
void
onCreateBackup
(
Activity
thiz
,
Bundle
bundle
)
{
public
static
void
onCreateBackup
(
Activity
thiz
,
Bundle
bundle
)
{
//invoke self to kill inline
onCreateBackup
(
thiz
,
bundle
);
}
}
@HookMethod
(
"onPause"
)
@HookMethod
(
"onPause"
)
public
static
void
onPause
(
Activity
thiz
)
{
public
static
void
onPause
(
Activity
thiz
)
{
Log
.
e
(
"ActivityHooker"
,
"hooked onPause success "
+
thiz
);
Log
.
e
(
"ActivityHooker"
,
"hooked onPause success "
+
thiz
.
hashCode
()
);
onPauseBackup
(
thiz
);
onPauseBackup
(
thiz
);
}
}
@HookMethodBackup
(
"onPause"
)
@HookMethodBackup
(
"onPause"
)
public
static
void
onPauseBackup
(
Activity
thiz
)
{
public
static
void
onPauseBackup
(
Activity
thiz
)
{
//invoke self to kill inline
onPauseBackup
(
thiz
);
}
}
}
}
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