Function at 0x411929
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 [0x415024]
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 - 0x1c], eax
call fcn.0040f9bc
lea ecx, [ebp - 0x28]
push ecx
mov ecx, dword [0x415024]
shl ecx, 2
push ecx
push dword [ebp - 0x1c]
push 0x10
call dword [eax]
mov edi, 0xc0000004
jmp 0x4119ab
mov eax, dword [0x415024]
push dword [ebp - 0x1c]
add eax, eax
mov dword [0x415024], eax
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov eax, dword [0x415024]
shl eax, 2
push eax
push 0x40
call esi
mov dword [ebp - 0x1c], eax
call fcn.0040f9bc
lea ecx, [ebp - 0x28]
push ecx
mov ecx, dword [0x415024]
shl ecx, 2
push ecx
push dword [ebp - 0x1c]
push 0x10
call dword [eax]
cmp eax, edi
je 0x41196c
mov eax, dword [ebp - 0x1c]
shr dword [ebp - 0x28], 4
xor ebx, ebx
push ebx
add eax, 4
push 2
mov dword [ebp - 0x10], eax
mov dword [0x41a5e4], ebx
mov dword [0x41a604], ebx
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov esi, eax
cmp esi, 0xffffffff
mov dword [ebp - 0x24], esi
je 0x4119fe
lea eax, [ebp - 0x698]
push eax
push esi
mov dword [ebp - 0x698], 0x22c
call sub.KERNEL32.dll_Process32FirstW
test eax, eax
jne 0x411a06
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
inc eax
jmp 0x41223c
mov dword [ebp - 0xc], ebx
call fcn.0040d29e
cmp byte [eax + 2], bl
je 0x411bae
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 0x40cf0c
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, ebx
mov dword [ebp - 0xc], eax
je 0x411bae
mov esi, dword [sym.imp.USER32.dll_wsprintfA]
lea eax, [ebp - 0x444]
push 0x40ceb8
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 [0x41a5f4]
lea eax, [ebp - 0x444]
push 0x40ce88
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 0x40ce84
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 [0x41a5f4], ebx
jbe 0x411b7f
mov dword [ebp - 8], ebx
mov ecx, dword [0x41a5ec]
mov edx, dword [ebp - 8]
inc eax
lea ecx, [edx + ecx + 0x1800]
push ecx
push eax
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x444]
push 0x40ce74
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 - 0x14]
add dword [ebp - 8], 0x2000
cmp eax, dword [0x41a5f4]
jb 0x411b27
lea eax, [ebp - 0x444]
push 0x40ce20
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, 0x41a608
call fcn.00410738
push dword [ebp - 0x690]
push 8
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov esi, eax
cmp esi, 0xffffffff
mov dword [ebp - 0x18], esi
je 0x411def
lea eax, [ebp - 0x46c]
push eax
push esi
mov dword [ebp - 0x46c], 0x428
call sub.KERNEL32.dll_Module32FirstW
test eax, eax
jne 0x411c29
push esi
jmp 0x411de9
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 0x40cd88
push eax
call fcn.0040faf7
test al, al
pop ecx
pop ecx
je 0x411dcf
cmp dword [0x41a5f4], ebx
mov dword [ebp - 4], ebx
jbe 0x411dcf
mov dword [ebp - 8], ebx
mov eax, dword [0x41a5ec]
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 0x411db6
or dword [ebp - 0x3eac], 0xffffffff
lea eax, [ebp - 0x674]
push eax
lea eax, [ebp - 0x3ea8]
push eax
call esi
mov ax, word [ebp - 0x468]
mov word [ebp - 0x36a4], ax
mov eax, dword [ebp - 0x464]
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 - 0x20], eax
je 0x411d5a
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 - 0x14]
push eax
push dword [ebp - 0x20]
call sub.PSAPI.DLL_EnumProcessModules
test eax, eax
je 0x411d43
push 0x400
lea eax, [ebp - 0xe98]
push eax
push dword [ebp - 0x14]
push dword [ebp - 0x20]
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 0x411d60
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, 0x41a5f8
call fcn.00410622
call fcn.0040d29e
cmp byte [eax + 2], bl
je 0x411db0
lea eax, [ebp - 0x3eac]
push eax
push dword [ebp - 0xc]
call fcn.00410bea
pop ecx
pop ecx
mov esi, dword [sym.imp.KERNEL32.dll_lstrcpyW]
inc dword [ebp - 4]
mov eax, dword [ebp - 4]
add dword [ebp - 8], 0x2000
cmp eax, dword [0x41a5f4]
jb 0x411c79
lea eax, [ebp - 0x46c]
push eax
push dword [ebp - 0x18]
call sub.KERNEL32.dll_Module32NextW
test eax, eax
jne 0x411c29
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [ebp - 0x698]
push eax
push dword [ebp - 0x24]
call sub.KERNEL32.dll_Process32NextW
test eax, eax
jne 0x411bae
push dword [ebp - 0x24]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call fcn.00410410
cmp dword [ebp - 0x28], ebx
mov dword [ebp - 0x38], eax
mov dword [ebp - 8], ebx
jbe 0x41221a
mov esi, dword [ebp - 0x10]
movzx eax, byte [esi + 4]
cmp eax, dword [ebp - 0x38]
jne 0x412205
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 0x411e5c
push dword [esi]
push ebx
push 0x40
call edi
cmp eax, ebx
mov dword [ebp - 4], eax
je 0x412205
push ebx
push ebx
push ebx
lea eax, [ebp - 0x14]
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 0x4121fc
push ebx
push ebx
push 3
push ebx
push ebx
push 0xc0000000
push 0x40cdf4
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, ebx
mov dword [ebp - 0x30], eax
je 0x4121f3
mov ecx, dword [ebp - 0x14]
mov dword [ebp - 0x40], ecx
mov ecx, dword [esi + 8]
push ebx
mov dword [ebp - 0x3c], ecx
lea ecx, [ebp - 0x34]
push ecx
push 8
lea ecx, [ebp - 0x40]
push ecx
push eax
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 - 0x34]
push eax
push 0x400
lea eax, [ebp - 0x444]
push eax
push dword [ebp - 0x30]
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp word [ebp - 0x444], bx
lea eax, [ebp - 0x43c]
mov dword [ebp - 0x440], eax
jbe 0x411f17
movzx eax, word [ebp - 0x444]
shr eax, 1
mov word [ebp + eax*2 - 0x43c], bx
push dword [ebp + 0xc]
mov word [ebp - 0xe98], bx
push dword [ebp - 0x440]
xor eax, eax
mov ecx, 0x1ff
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 0x411f86
movzx edx, word [ebp - 0x444]
mov eax, dword [ebp + 0x10]
shr edx, 1
cmp edx, eax
jbe 0x411f76
lea eax, [ecx + eax*2]
push eax
push dword [ebp + 0x14]
lea eax, [ebp - 0xe98]
push 0x40cde8
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
jmp 0x411f86
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
je 0x4121ea
xor eax, eax
mov word [ebp - 0x269c], bx
mov ecx, 0x1ff
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.0040fb1a
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 [0x41a5f4], ebx
mov dword [ebp - 0x20], ebx
jbe 0x4121ea
mov dword [ebp - 0x18], ebx
mov eax, dword [0x41a5ec]
mov ecx, dword [ebp - 0x18]
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 0x4121d1
push 7
pop ecx
mov esi, 0x40cdc8
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, 0x40cda8
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 - 0x2c]
push eax
push dword [ebp - 4]
call sub.PSAPI.DLL_EnumProcessModules
test eax, eax
je 0x4120ae
mov esi, 0x400
push esi
lea eax, [ebp - 0x46ac]
push eax
push dword [ebp - 0x2c]
push dword [ebp - 4]
call sub.PSAPI.DLL_GetModuleBaseNameW
push esi
lea eax, [ebp - 0x1698]
push eax
push dword [ebp - 0x2c]
push dword [ebp - 4]
call sub.PSAPI.DLL_GetModuleFileNameExW
jmp 0x412105
cmp dword [0x41a614], ebx
mov dword [ebp - 0x24], ebx
jbe 0x412105
xor esi, esi
mov eax, dword [0x41a60c]
mov edx, dword [ebp - 0x10]
add eax, esi
mov ecx, dword [eax]
cmp ecx, dword [edx]
jne 0x4120f1
mov edi, dword [sym.imp.KERNEL32.dll_lstrcpyW]
add eax, 4
push eax
lea eax, [ebp - 0x46ac]
push eax
call edi
mov eax, dword [0x41a60c]
lea eax, [esi + eax + 4]
push eax
lea eax, [ebp - 0x1698]
push eax
call edi
inc dword [ebp - 0x24]
mov eax, dword [ebp - 0x24]
add esi, 0x804
cmp eax, dword [0x41a614]
jb 0x4120bb
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 - 0x10]
mov cx, word [eax + 6]
mov eax, dword [eax]
mov dword [ebp - 0x36a8], eax
push 0x40cda0
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 0x412174
lea eax, [ebp - 0x2696]
push eax
lea eax, [ebp - 0x36a2]
push 0x40cd94
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
jmp 0x412184
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, 0x41a5f8
call fcn.00410622
call fcn.0040d29e
cmp byte [eax + 2], bl
je 0x4121ce
lea eax, [ebp - 0x3eac]
push eax
push dword [ebp - 0xc]
call fcn.00410bea
pop ecx
pop ecx
mov esi, dword [ebp - 0x10]
inc dword [ebp - 0x20]
mov eax, dword [ebp - 0x20]
add dword [ebp - 0x18], 0x2000
cmp eax, dword [0x41a5f4]
jb 0x411ffb
push dword [ebp - 0x30]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
add esi, 0x10
inc dword [ebp - 8]
mov eax, dword [ebp - 8]
cmp eax, dword [ebp - 0x28]
mov dword [ebp - 0x10], esi
jb 0x411e23
call fcn.0040d29e
cmp byte [eax + 2], bl
je 0x412232
cmp dword [ebp - 0xc], ebx
je 0x412232
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0x1c]
mov dword [eax], ecx
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret