Function at 0x41393c
Capabilities:
Enumerate process modules
Enumerate processes
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x46ac
mov eax, dword [0x417028]
push ebx
push esi
mov esi, dword [sym.imp.KERNEL32.dll_GlobalAlloc]
push edi
shl eax, 2
push eax
push 0x40
call esi
mov dword [ebp - 0x20], eax
call fcn.00411535
lea ecx, [ebp - 0x28]
push ecx
mov ecx, dword [0x417028]
shl ecx, 2
push ecx
push dword [ebp - 0x20]
push 0x10
call dword [eax]
mov edi, 0xc0000004
jmp 0x4139be
mov eax, dword [0x417028]
push dword [ebp - 0x20]
add eax, eax
mov dword [0x417028], eax
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov eax, dword [0x417028]
shl eax, 2
push eax
push 0x40
call esi
mov dword [ebp - 0x20], eax
call fcn.00411535
lea ecx, [ebp - 0x28]
push ecx
mov ecx, dword [0x417028]
shl ecx, 2
push ecx
push dword [ebp - 0x20]
push 0x10
call dword [eax]
cmp eax, edi
je 0x41397f
mov eax, dword [ebp - 0x20]
shr dword [ebp - 0x28], 4
xor ebx, ebx
push ebx
add eax, 4
push 2
mov dword [ebp - 0x18], eax
mov dword [0x41c6ec], ebx
mov dword [0x41c70c], ebx
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov esi, eax
cmp esi, 0xffffffff
mov dword [ebp - 0x14], esi
je 0x413a11
lea eax, [ebp - 0x698]
push eax
push esi
mov dword [ebp - 0x698], 0x22c
call sub.KERNEL32.dll_Process32FirstW
test eax, eax
jne 0x413a19
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
inc eax
jmp 0x41428c
mov dword [ebp - 0xc], ebx
call fcn.0040e83a
cmp byte [eax + 2], bl
je 0x413bc2
push 0x400
lea eax, [ebp - 0x1e98]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea eax, [ebp - 0x1e98]
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
lea eax, [ebp - 0x1e98]
push eax
lea eax, [ebp - 0x1698]
push 0x40e4b4
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
push ebx
push 0x80
push 2
push ebx
push ebx
push 0x40000000
lea eax, [ebp - 0x1698]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [ebp - 0xc], eax
je 0x413bc2
mov esi, dword [sym.imp.USER32.dll_wsprintfA]
lea eax, [ebp - 0x444]
push 0x40e460
push eax
call esi
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenA]
pop ecx
pop ecx
push ebx
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x444]
push eax
call edi
push eax
lea eax, [ebp - 0x444]
push eax
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_WriteFile]
push dword [0x41c6fc]
lea eax, [ebp - 0x444]
push 0x40e430
push eax
call esi
add esp, 0xc
push ebx
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x444]
push eax
call edi
push eax
lea eax, [ebp - 0x444]
push eax
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_WriteFile]
lea eax, [ebp - 0x444]
push 0x40e42c
push eax
call esi
pop ecx
pop ecx
push ebx
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x444]
push eax
call edi
push eax
lea eax, [ebp - 0x444]
push eax
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_WriteFile]
xor eax, eax
cmp dword [0x41c6fc], ebx
jbe 0x413b93
mov dword [ebp - 8], ebx
mov ecx, dword [0x41c6f4]
mov edx, dword [ebp - 8]
inc eax
lea ecx, [edx + ecx + 0x1800]
push ecx
push eax
mov dword [ebp - 0x2c], eax
lea eax, [ebp - 0x444]
push 0x40e41c
push eax
call esi
add esp, 0x10
push ebx
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x444]
push eax
call edi
push eax
lea eax, [ebp - 0x444]
push eax
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [ebp - 0x2c]
add dword [ebp - 8], 0x2000
cmp eax, dword [0x41c6fc]
jb 0x413b3b
lea eax, [ebp - 0x444]
push 0x40e3c8
push eax
call esi
pop ecx
pop ecx
push ebx
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x444]
push eax
call edi
push eax
lea eax, [ebp - 0x444]
push eax
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [ebp - 0x690]
mov dword [ebp - 0x1e9c], eax
lea eax, [ebp - 0x674]
push eax
lea eax, [ebp - 0x1e98]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
sub esp, 0x804
mov edi, esp
mov ecx, 0x201
lea esi, [ebp - 0x1e9c]
rep movsd dword es:[edi], dword [esi]
mov ecx, 0x41c710
call fcn.00412677
push dword [ebp - 0x690]
push 8
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov esi, eax
cmp esi, 0xffffffff
mov dword [ebp - 0x1c], esi
je 0x413e31
lea eax, [ebp - 0x46c]
push eax
push esi
mov dword [ebp - 0x46c], 0x428
call sub.KERNEL32.dll_Module32FirstW
test eax, eax
jne 0x413c3d
push esi
jmp 0x413e2b
mov esi, dword [sym.imp.KERNEL32.dll_lstrcpyW]
lea eax, [ebp - 0x24c]
push eax
lea eax, [ebp - 0x1698]
push eax
call esi
lea eax, [ebp - 0x1698]
push eax
call dword [sym.imp.USER32.dll_CharUpperW]
lea eax, [ebp - 0x24c]
push 0x40e330
push eax
call fcn.00411670
test al, al
pop ecx
pop ecx
je 0x413e11
cmp dword [0x41c6fc], ebx
mov dword [ebp - 0x10], ebx
jbe 0x413e11
mov dword [ebp - 8], ebx
mov eax, dword [0x41c6f4]
mov ecx, dword [ebp - 8]
lea eax, [ecx + eax + 0x1800]
push eax
lea eax, [ebp - 0x1698]
push eax
call dword [sym.imp.SHLWAPI.dll_StrStrW]
lea ecx, [ebp - 0x1698]
cmp eax, ecx
jne 0x413df8
or dword [ebp - 0x3eac], 0xffffffff
lea eax, [ebp - 0x674]
push eax
lea eax, [ebp - 0x3ea8]
push eax
call esi
mov eax, dword [ebp - 0x464]
or word [ebp - 0x36a4], 0xffff
mov dword [ebp - 0x36a8], eax
lea eax, [ebp - 0x24c]
push eax
lea eax, [ebp - 0x36a2]
push eax
call esi
push dword [ebp - 0x690]
push ebx
push 0x1f0fff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
cmp eax, ebx
mov dword [ebp - 4], eax
je 0x413d9c
xor eax, eax
mov word [ebp - 0xe98], bx
mov ecx, 0x1ff
lea edi, [ebp - 0xe96]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x34]
push eax
push 4
lea eax, [ebp - 0x24]
push eax
push dword [ebp - 4]
call sub.PSAPI.DLL_EnumProcessModules
test eax, eax
je 0x413d6a
mov edi, 0x400
push edi
lea eax, [ebp - 0x3ea8]
push eax
push dword [ebp - 0x24]
push dword [ebp - 4]
call sub.PSAPI.DLL_GetModuleBaseNameW
push edi
lea eax, [ebp - 0xe98]
push eax
push dword [ebp - 0x24]
push dword [ebp - 4]
call sub.PSAPI.DLL_GetModuleFileNameExW
lea eax, [ebp - 0xe98]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
test eax, eax
lea eax, [ebp - 0xe98]
jne 0x413d87
lea eax, [ebp - 0x674]
push eax
lea eax, [ebp - 0x2ea2]
push eax
call esi
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x413dac
lea eax, [ebp - 0x674]
push eax
lea eax, [ebp - 0x2ea2]
push eax
call esi
mov eax, dword [ebp - 0x450]
sub esp, 0x1810
mov edi, esp
mov dword [ebp - 0x26a0], eax
lea esi, [ebp - 0x3eac]
mov ecx, 0x604
rep movsd dword es:[edi], dword [esi]
mov ecx, 0x41c700
call fcn.00412561
call fcn.0040e83a
cmp byte [eax + 2], bl
je 0x413df2
lea eax, [ebp - 0x3eac]
push eax
push dword [ebp - 0xc]
call fcn.00412cc7
pop ecx
pop ecx
mov esi, dword [sym.imp.KERNEL32.dll_lstrcpyW]
inc dword [ebp - 0x10]
mov eax, dword [ebp - 0x10]
add dword [ebp - 8], 0x2000
cmp eax, dword [0x41c6fc]
jb 0x413c8d
lea eax, [ebp - 0x46c]
push eax
push dword [ebp - 0x1c]
call sub.KERNEL32.dll_Module32NextW
test eax, eax
jne 0x413c3d
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [ebp - 0x698]
push eax
push dword [ebp - 0x14]
call sub.KERNEL32.dll_Process32NextW
test eax, eax
jne 0x413bc2
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call fcn.00412161
cmp dword [ebp - 0x28], ebx
mov dword [ebp - 0x34], eax
mov dword [ebp - 8], ebx
jbe 0x41426a
mov esi, dword [ebp - 0x18]
movzx eax, byte [esi + 4]
cmp dword [ebp - 0x34], eax
jne 0x414255
push dword [esi]
mov edi, dword [sym.imp.KERNEL32.dll_OpenProcess]
push ebx
push 0x450
call edi
cmp eax, ebx
mov dword [ebp - 4], eax
jne 0x413e9e
push dword [esi]
push ebx
push 0x40
call edi
cmp eax, ebx
mov dword [ebp - 4], eax
je 0x414255
push ebx
push ebx
push ebx
lea eax, [ebp - 0x2c]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
movzx eax, word [esi + 6]
push eax
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_DuplicateHandle]
test eax, eax
je 0x41424c
push ebx
push ebx
push 3
push ebx
push ebx
push 0xc0000000
push 0x40e39c
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [ebp - 0x30], eax
je 0x414243
mov ecx, dword [ebp - 0x2c]
mov dword [ebp - 0x40], ecx
mov ecx, dword [esi + 8]
push ebx
mov dword [ebp - 0x3c], ecx
lea ecx, [ebp - 0x10]
push ecx
push 8
lea ecx, [ebp - 0x40]
push ecx
push eax
mov dword [ebp - 0x10], ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
xor eax, eax
mov byte [ebp - 0x444], bl
mov ecx, 0xff
lea edi, [ebp - 0x443]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
push ebx
stosb byte es:[edi], al
lea eax, [ebp - 0x10]
push eax
push 0x400
lea eax, [ebp - 0x444]
push eax
push dword [ebp - 0x30]
mov dword [ebp - 0x10], ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x41423a
cmp word [ebp - 0x444], bx
lea eax, [ebp - 0x43c]
mov dword [ebp - 0x440], eax
jbe 0x413f68
movzx eax, word [ebp - 0x444]
shr eax, 1
mov word [ebp + eax*2 - 0x43c], bx
push dword [ebp + 0xc]
mov esi, 0x1ff
push dword [ebp - 0x440]
mov word [ebp - 0xe98], bx
xor eax, eax
mov ecx, esi
lea edi, [ebp - 0xe96]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
call dword [sym.imp.SHLWAPI.dll_StrStrW]
mov ecx, dword [ebp - 0x440]
cmp eax, ecx
jne 0x413fd9
movzx edx, word [ebp - 0x444]
mov eax, dword [ebp + 0x10]
shr edx, 1
cmp eax, edx
jae 0x413fc9
lea eax, [ecx + eax*2]
push eax
push dword [ebp + 0x14]
lea eax, [ebp - 0xe98]
push 0x40e390
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
jmp 0x413fd9
push dword [ebp + 0x14]
lea eax, [ebp - 0xe98]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
lea eax, [ebp - 0xe98]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
test eax, eax
jle 0x414237
xor eax, eax
mov word [ebp - 0x269c], bx
mov ecx, esi
lea edi, [ebp - 0x269a]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0xe98]
push eax
lea eax, [ebp - 0x269c]
push eax
call fcn.00411693
pop ecx
pop ecx
lea eax, [ebp - 0x269c]
push eax
lea eax, [ebp - 0x1e98]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
lea eax, [ebp - 0x1e98]
push eax
call dword [sym.imp.USER32.dll_CharUpperW]
cmp dword [0x41c6fc], ebx
mov dword [ebp - 0x24], ebx
jbe 0x414237
mov dword [ebp - 0x1c], ebx
mov eax, dword [0x41c6f4]
mov ecx, dword [ebp - 0x1c]
lea eax, [ecx + eax + 0x1800]
push eax
lea eax, [ebp - 0x1e98]
push eax
call dword [sym.imp.SHLWAPI.dll_StrStrW]
lea ecx, [ebp - 0x1e98]
cmp eax, ecx
jne 0x41421e
push 7
pop ecx
mov esi, 0x40e370
lea edi, [ebp - 0x46ac]
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
xor eax, eax
mov edx, 0x1f8
mov ecx, edx
lea edi, [ebp - 0x468e]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
push 7
pop ecx
mov esi, 0x40e350
lea edi, [ebp - 0x1698]
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
xor eax, eax
mov ecx, edx
lea edi, [ebp - 0x167a]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x44]
push eax
push 4
lea eax, [ebp - 0x38]
push eax
push dword [ebp - 4]
call sub.PSAPI.DLL_EnumProcessModules
test eax, eax
je 0x4140fe
mov esi, 0x400
push esi
lea eax, [ebp - 0x46ac]
push eax
push dword [ebp - 0x38]
push dword [ebp - 4]
call sub.PSAPI.DLL_GetModuleBaseNameW
push esi
lea eax, [ebp - 0x1698]
push eax
push dword [ebp - 0x38]
push dword [ebp - 4]
call sub.PSAPI.DLL_GetModuleFileNameExW
jmp 0x414155
cmp dword [0x41c71c], ebx
mov dword [ebp - 0x14], ebx
jbe 0x414155
xor esi, esi
mov eax, dword [0x41c714]
mov edx, dword [ebp - 0x18]
add eax, esi
mov ecx, dword [eax]
cmp ecx, dword [edx]
jne 0x414141
mov edi, dword [sym.imp.KERNEL32.dll_lstrcpyW]
add eax, 4
push eax
lea eax, [ebp - 0x46ac]
push eax
call edi
mov eax, dword [0x41c714]
lea eax, [esi + eax + 4]
push eax
lea eax, [ebp - 0x1698]
push eax
call edi
inc dword [ebp - 0x14]
mov eax, dword [ebp - 0x14]
add esi, 0x804
cmp eax, dword [0x41c71c]
jb 0x41410b
mov eax, dword [ebp - 8]
mov esi, dword [sym.imp.KERNEL32.dll_lstrcpyW]
mov dword [ebp - 0x3eac], eax
lea eax, [ebp - 0x46ac]
push eax
lea eax, [ebp - 0x3ea8]
push eax
call esi
mov eax, dword [ebp - 0x18]
mov cx, word [eax + 6]
mov eax, dword [eax]
mov dword [ebp - 0x36a8], eax
push 0x40e348
lea eax, [ebp - 0x269c]
push eax
mov word [ebp - 0x36a4], cx
call dword [sym.imp.SHLWAPI.dll_StrStrW]
lea ecx, [ebp - 0x269c]
cmp eax, ecx
jne 0x4141c4
lea eax, [ebp - 0x2696]
push eax
lea eax, [ebp - 0x36a2]
push 0x40e33c
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
jmp 0x4141d4
lea eax, [ebp - 0x269c]
push eax
lea eax, [ebp - 0x36a2]
push eax
call esi
lea eax, [ebp - 0x1698]
push eax
lea eax, [ebp - 0x2ea2]
push eax
call esi
sub esp, 0x1810
mov edi, esp
lea esi, [ebp - 0x3eac]
mov ecx, 0x604
rep movsd dword es:[edi], dword [esi]
mov ecx, 0x41c700
call fcn.00412561
call fcn.0040e83a
cmp byte [eax + 2], bl
je 0x41421e
lea eax, [ebp - 0x3eac]
push eax
push dword [ebp - 0xc]
call fcn.00412cc7
pop ecx
pop ecx
inc dword [ebp - 0x24]
mov eax, dword [ebp - 0x24]
add dword [ebp - 0x1c], 0x2000
cmp eax, dword [0x41c6fc]
jb 0x41404b
mov esi, dword [ebp - 0x18]
push dword [ebp - 0x30]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 0x2c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
inc dword [ebp - 8]
mov eax, dword [ebp - 8]
add esi, 0x10
cmp eax, dword [ebp - 0x28]
mov dword [ebp - 0x18], esi
jb 0x413e65
call fcn.0040e83a
cmp byte [eax + 2], bl
je 0x414282
cmp dword [ebp - 0xc], ebx
je 0x414282
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0x20]
mov dword [eax], ecx
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret