Skip to content

Commit cca96e5

Browse files
committed
Merge pull request #1 from h4ck1t4u/master
[BUG] byref & h_loadlib
2 parents 6d86068 + e883c32 commit cca96e5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

dll_inject.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,11 @@
3535

3636
# Write DLL path to allocated space
3737
written = c_int(0)
38-
kernel32.WriteProcessMemory(h_process, arg_address, dll_path, dll_len, bytef(written))
38+
kernel32.WriteProcessMemory(h_process, arg_address, dll_path, dll_len, byref(written))
3939

4040
# Resolve LoadLibraryA Address
4141
h_kernel32 = kernel32.GetModuleHandleA("kernel32.dll")
42-
h.loadlib = kernel32.GetProcAddress(h_kernel32, "LoadLibraryA")
42+
h_loadlib = kernel32.GetProcAddress(h_kernel32, "LoadLibraryA")
4343

4444
# Now we createRemoteThread with entrypoiny set to LoadLibraryA and pointer to DLL path as param
4545
thread_id = c_ulong(0)

0 commit comments

Comments
 (0)