File tree Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -93,9 +93,9 @@ _inject_LoadLibraryExWptr:
93
93
push esp / * Reset directory to the original one of the process * /
94
94
call esi / * Call SetCurrentDirectoryW * /
95
95
add esp , ebx / * Deallocate buffer from the stack * /
96
+ SkipDirectoryBS2:
96
97
_inject_ExitThreadptr:
97
98
mov esi , 0xDEADBEEF
98
- SkipDirectoryBS2:
99
99
test edi , edi / * Check whether LoadLibraryEx was successful * /
100
100
jz ThrowError1
101
101
_inject_funcnameptr:
@@ -114,34 +114,35 @@ _inject_funcparamptr:
114
114
If we get here , [ func_name ] has been called ,
115
115
so it's time to close this thread and optionally unload the DLL.
116
116
* /
117
-
118
- push 0 / * Exit code * /
117
+
119
118
mov eax , esi
120
119
pop edi
121
120
pop esi
122
121
pop ebp
123
122
pop ebx
123
+ push 0 / * Exit code * /
124
124
call eax / * Call ExitThread * /
125
125
126
126
.balign 16 , 0xCC
127
127
128
128
ThrowError1:
129
- push 1 / * Exit code * /
130
129
mov eax , esi
131
130
pop edi
132
131
pop esi
133
132
pop ebp
134
133
pop ebx
134
+ push 1 / * Exit code * /
135
135
call eax / * Call ExitThread * /
136
136
.balign 16 , 0xCC
137
137
138
138
ThrowError2:
139
- push 2 / * Exit code * /
140
- push edi / * Push the injected DLL's module handle * /
139
+ mov edx , edi
141
140
pop edi
142
141
pop esi
143
142
pop ebp
144
143
pop ebx
144
+ push 2 / * Exit code * /
145
+ push edx / * Push the injected DLL's module handle * /
145
146
_inject_FreeLibraryAndExitThreadptr:
146
147
mov eax , 0xDEADBEEF
147
148
call eax / * Call FreeLibraryAndExitThread * /
You can’t perform that action at this time.
0 commit comments