Function at 0x402980
Capabilities:
Create a process with modified i/o handles and window
Create pipe
Create process on windows
Read file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1084
call fcn.0043a3c0
mov eax, dword [0x450398]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 8]
push esi
push edi
push 0
mov dword [ebp - 0x1020], eax
mov dword [eax], 0xffffffff
lea eax, [ebp - 0x102c]
mov edi, ecx
push eax
lea ecx, [ebp - 0x1014]
push ecx
lea edx, [ebp - 0x1010]
push edx
mov dword [ebp - 0x102c], 0xc
mov dword [ebp - 0x1028], 0
mov dword [ebp - 0x1024], 1
call dword [sym.imp.KERNEL32.dll_CreatePipe]
test eax, eax
jne 0x402a0a
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x402c19
or eax, 0xffffffff
pop edi
pop esi
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004267a3
mov esp, ebp
pop ebp
ret
push 0x44
lea eax, [ebp - 0x1084]
push 0
push eax
call fcn.00429770
add esp, 0xc
lea ecx, [ebp - 0x1084]
push ecx
mov dword [ebp - 0x1084], 0x44
call dword [sym.imp.KERNEL32.dll_GetStartupInfoW]
mov eax, dword [ebp - 0x1014]
mov dword [ebp - 0x1044], eax
mov dword [ebp - 0x1048], eax
mov eax, dword [edi + 0x10]
xor edx, edx
mov word [ebp - 0x1054], dx
xor ecx, ecx
inc eax
mov edx, 2
mul edx
seto cl
mov dword [ebp - 0x1058], 0x101
neg ecx
or ecx, eax
push ecx
call fcn.00426317
mov esi, eax
add esp, 4
test esi, esi
jne 0x402a8f
or eax, 0xffffffff
pop edi
pop esi
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004267a3
mov esp, ebp
pop ebp
ret
mov eax, dword [edi + 0x10]
lea ecx, [eax + eax + 2]
push ecx
push 0
push esi
call fcn.00429770
mov eax, dword [edi + 0x10]
add esp, 0xc
cmp dword [edi + 0x14], 8
jb 0x402aad
mov edi, dword [edi]
lea edx, [eax + eax]
push edx
push edi
push esi
call fcn.0042aac0
add esp, 0xc
lea eax, [ebp - 0x103c]
push eax
lea ecx, [ebp - 0x1084]
push ecx
push 0
push 0
push 0
push 1
push 0
push 0
push esi
push 0
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
push esi
test eax, eax
jne 0x402b25
call fcn.00426f68
add esp, 4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [ebp - 0x1010]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push edx
mov esi, eax
call edi
mov eax, dword [ebp - 0x1014]
push eax
call edi
test esi, esi
je 0x4029f7
mov eax, esi
pop edi
pop esi
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004267a3
mov esp, ebp
pop ebp
ret
call fcn.00426f68
mov ecx, dword [ebp - 0x1014]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
add esp, 4
push ecx
call edi
push 0xfff
lea edx, [ebp - 0x100b]
push 0
push edx
mov byte [ebp - 0x100c], 0
call fcn.00429770
mov edx, dword [ebp - 0x1010]
mov esi, dword [sym.imp.KERNEL32.dll_ReadFile]
add esp, 0xc
push 0
lea eax, [ebp - 0x1018]
push eax
push 0xfff
lea ecx, [ebp - 0x100c]
push ecx
push edx
call esi
test eax, eax
je 0x402bd0
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x402b90
mov eax, dword [ebp - 0x1018]
push eax
lea eax, [ebp - 0x100c]
mov ecx, ebx
call fcn.004144d0
push 0x64
call edi
mov eax, dword [ebp - 0x1010]
push 0
lea ecx, [ebp - 0x1018]
push ecx
push 0xfff
lea edx, [ebp - 0x100c]
push edx
push eax
call esi
test eax, eax
jne 0x402b90
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 0x103c]
lea ecx, [ebp - 0x101c]
push ecx
push edx
mov dword [ebp - 0x101c], 0
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
mov edx, dword [ebp - 0x1010]
mov eax, dword [ebp - 0x101c]
mov ecx, dword [ebp - 0x1020]
push edx
mov dword [ecx], eax
call edi
mov eax, dword [ebp - 0x1038]
push eax
call edi
mov ecx, dword [ebp - 0x103c]
push ecx
call edi
xor eax, eax
mov ecx, dword [ebp - 8]
pop edi
xor ecx, ebp
pop esi
call fcn.004267a3
mov esp, ebp
pop ebp
ret