Function at 0x40a840
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffeb0
push ebx
push esi
push edi
xor edx, edx
mov dword [ebp - 0x150], edx
mov dword [ebp - 0x14c], edx
mov dword [ebp - 0x148], edx
mov dword [ebp - 0x144], edx
mov dword [ebp - 0x13c], edx
mov dword [ebp - 0x140], edx
mov dword [ebp - 4], eax
xor eax, eax
push ebp
push 0x40ab61
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 4]
mov edx, dword [0x40a514]
call fcn.00404830
xor eax, eax
mov dword [ebp - 8], eax
call sub.KERNEL32.DLL_UnmapViewOfFile
test eax, 0x80000000
jne 0x40aaa7
cmp dword [0x41898c], 0xffffffff
jne 0x40a918
lea edx, [ebp - 0x140]
mov eax, 0x40ab78
call fcn.004070f0
mov eax, dword [ebp - 0x140]
lea ecx, [ebp - 0x13c]
mov dl, 1
call fcn.00407160
mov eax, dword [ebp - 0x13c]
push eax
call sub.KERNEL32.DLL_WinExec
mov dword [0x41898c], eax
cmp dword [0x41898c], 0
je 0x40a918
xor eax, eax
mov dword [0x4189bc], eax
lea edx, [ebp - 0x144]
mov eax, 0x40ab90
call fcn.004070f0
mov edx, dword [ebp - 0x144]
mov eax, dword [0x41898c]
call fcn.00407574
mov dword [0x4189c0], eax
cmp dword [0x4189bc], 0
je 0x40a9b6
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x10]
push eax
push 1
push 0
push 0
call dword [0x4189bc]
test eax, eax
je 0x40a9b6
cmp dword [ebp - 0xc], 0
jbe 0x40a9b6
mov esi, dword [ebp - 0x10]
mov ebx, dword [ebp - 0xc]
test ebx, ebx
jbe 0x40a9aa
mov eax, dword [ebp - 0x10]
mov edi, dword [eax + 8]
test edi, edi
je 0x40a985
push ebp
mov eax, dword [ebp - 0x10]
mov eax, dword [eax + 0xc]
push eax
lea edx, [ebp - 0x148]
mov eax, edi
call fcn.00407200
mov ecx, dword [ebp - 0x148]
mov eax, dword [ebp - 0x10]
mov edx, dword [eax]
mov eax, dword [ebp - 0x10]
mov eax, dword [eax + 4]
call fcn.0040a700
pop ecx
jmp 0x40a9a3
push ebp
mov eax, dword [ebp - 0x10]
mov eax, dword [eax + 0xc]
push eax
mov eax, dword [ebp - 0x10]
mov edx, dword [eax]
mov eax, dword [ebp - 0x10]
mov eax, dword [eax + 4]
mov ecx, 0x40aba8
call fcn.0040a700
pop ecx
add dword [ebp - 0x10], 0x10
dec ebx
jne 0x40a94d
push esi
call dword [0x4189c0]
jmp 0x40ab29
cmp dword [0x4189b8], 0
jne 0x40a9ce
mov eax, 0x40abc4
call fcn.0040a0e4
mov dword [0x4189b8], eax
xor eax, eax
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0xc]
push eax
push 0
push 0
push 5
call dword [0x4189b8]
xor esi, esi
cmp dword [ebp - 0xc], 0
jne 0x40aa2b
mov dword [ebp - 0xc], 0x10000
mov eax, dword [ebp - 0xc]
add eax, eax
mov dword [ebp - 0xc], eax
push esi
call sub.KERNEL32.DLL_lstrcpyA
mov eax, dword [ebp - 0xc]
push eax
push pe_nt_image_headers32
call sub.KERNEL32.DLL_lstrcatW
mov esi, eax
push 0
mov eax, dword [ebp - 0xc]
push eax
push esi
push 5
call dword [0x4189b8]
test eax, eax
je 0x40aa4f
cmp dword [ebp - 0xc], 0x400000
jne 0x40a9f2
jmp 0x40aa4f
mov eax, dword [ebp - 0xc]
add eax, eax
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0xc]
push eax
push pe_nt_image_headers32
call sub.KERNEL32.DLL_lstrcatW
mov esi, eax
push 0
mov eax, dword [ebp - 0xc]
push eax
push esi
push 5
call dword [0x4189b8]
test eax, eax
jne 0x40aa9c
mov ebx, esi
mov edi, dword [ebx + 0x3c]
test edi, edi
je 0x40aa7f
push ebp
push 0
lea edx, [ebp - 0x14c]
mov eax, edi
call fcn.00407200
mov ecx, dword [ebp - 0x14c]
xor edx, edx
mov eax, dword [ebx + 0x44]
call fcn.0040a700
pop ecx
jmp 0x40aa92
push ebp
push 0
mov ecx, 0x40aba8
xor edx, edx
mov eax, dword [ebx + 0x44]
call fcn.0040a700
pop ecx
mov eax, dword [ebx]
test eax, eax
je 0x40aa9c
add ebx, eax
jmp 0x40aa55
push esi
call sub.KERNEL32.DLL_lstrcpyA
jmp 0x40ab29
call fcn.0040a540
push 0
push 2
call dword [0x418988]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0xffffffff
je 0x40ab29
mov dword [ebp - 0x138], 0x128
lea eax, [ebp - 0x138]
push eax
mov eax, dword [ebp - 0xc]
push eax
call dword [0x418978]
test eax, eax
je 0x40ab20
push ebp
push 0
lea eax, [ebp - 0x150]
lea edx, [ebp - 0x114]
mov ecx, 0x104
call fcn.00403cdc
mov ecx, dword [ebp - 0x150]
xor edx, edx
mov eax, dword [ebp - 0x130]
call fcn.0040a700
pop ecx
lea eax, [ebp - 0x138]
push eax
mov eax, dword [ebp - 0xc]
push eax
call dword [0x41897c]
test eax, eax
jne 0x40aade
mov eax, dword [ebp - 0xc]
push eax
call sub.KERNEL32.DLL_FormatMessageA
mov eax, dword [ebp - 8]
push eax
mov eax, dword [ebp - 4]
mov ecx, 1
mov edx, dword [0x40a514]
call fcn.00404824
add esp, 4
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x40ab68
lea eax, [ebp - 0x150]
mov edx, 6
call fcn.00403b94
ret