Function at 0x4b77c3
Capabilities:
Check for protected handle exception
Create pipe
Create process on windows
Create process suspended
Write and execute a file
Write file on windows
Write pipe

Disassembly:
push r14
push r13
push r12
push rdi
push rsi
push rbx
sub rsp, 0x238
mov r8d, 0x105
lea r14, [rsp + 0x12b]
mov r13, rcx
xor ecx, ecx
mov rdx, r14
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea rdx, str.ERROR:_could_get_path_to_myself
test eax, eax
je 0x4b7968
lea rdx, [rsp + 0x68]
xor r9d, r9d
mov dword [rsp + 0x90], 0x18
lea rcx, [rsp + 0x60]
mov dword [rsp + 0xa0], 1
lea r8, [rsp + 0x90]
mov qword [rsp + 0x98], 0
call qword [sym.imp.KERNEL32.dll_CreatePipe]
lea rdx, str.ERROR:_CreatePipe_failed
test eax, eax
je 0x4b7968
lea rbx, [rsp + 0xc0]
xor r8d, r8d
mov edx, 1
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.KERNEL32.dll_SetHandleInformation]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetStartupInfoA]
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov rdi, qword [sym.imp.KERNEL32.dll_GetStdHandle]
mov ecx, 0xfffffff5
mov r12, rax
mov rax, qword [rsp + 0x60]
mov qword [rsp + 0x110], rax
call rdi
lea r9, [rsp + 0x118]
mov r8, r12
mov rcx, r12
mov rdx, rax
mov rsi, qword [sym.imp.KERNEL32.dll_DuplicateHandle]
mov dword [rsp + 0x30], 2
mov dword [rsp + 0x28], 1
mov dword [rsp + 0x20], 0
call rsi
mov ecx, 0xfffffff4
call rdi
lea r9, [rsp + 0x120]
mov r8, r12
mov rcx, r12
mov rdx, rax
mov dword [rsp + 0x30], 2
mov dword [rsp + 0x28], 1
mov dword [rsp + 0x20], 0
call rsi
xor r9d, r9d
xor r8d, r8d
mov byte [rsp + 0x7f], 0
mov qword [rsp + 0x40], rbx
lea rdx, [rsp + 0x77]
mov rcx, r14
movabs rax, 0x2d20786f626e6977
mov qword [rsp + 0x77], rax
lea rax, [rsp + 0xa8]
or dword [rsp + 0xfc], 0x100
mov qword [rsp + 0x48], rax
mov qword [rsp + 0x38], 0
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0
mov dword [rsp + 0x20], 1
call qword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
jne 0x4b7983
lea rdx, str.ERROR:_could_not_start_process
mov rcx, qword [0x0053cb90]
call fcn.004d0ff9
mov rcx, rax
call fcn.004d13bf
xor eax, eax
jmp 0x4b7ae1
lea r12, [rsp + 0x80]
mov rdx, r13
lea rsi, [rsp + 0x5c]
mov rcx, r12
call fcn.00512660
mov rax, qword [rsp + 0x88]
mov r9, rsi
sub rax, qword [rsp + 0x80]
mov dword [rsp + 0x58], eax
mov rcx, qword [rsp + 0x68]
lea rdx, [rsp + 0x58]
mov r8d, 4
mov dword [rsp + 0x5c], 0
mov rbx, qword [sym.imp.KERNEL32.dll_WriteFile]
mov qword [rsp + 0x20], 0
call rbx
test eax, eax
jne 0x4b7a0f
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, qword [0x0053cb90]
lea rdx, str.write_len_failed
mov r13d, eax
call fcn.004d0ff9
mov edx, r13d
mov rcx, rax
call fcn.004d10e2
mov rcx, rax
call fcn.004d13bf
mov rdx, qword [rsp + 0x80]
mov r8d, dword [rsp + 0x88]
mov r9, rsi
mov qword [rsp + 0x20], 0
mov rcx, qword [rsp + 0x68]
sub r8d, edx
call rbx
test eax, eax
jne 0x4b7a68
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, qword [0x0053cb90]
lea rdx, str.write_msg_failed
mov r13d, eax
call fcn.004d0ff9
mov edx, r13d
mov rcx, rax
call fcn.004d10e2
mov rcx, rax
call fcn.004d13bf
mov rax, qword [rsp + 0x88]
sub rax, qword [rsp + 0x80]
cmp dword [rsp + 0x5c], eax
jae 0x4b7acc
mov rcx, qword [0x0053cb90]
lea rdx, str.partial_write
call fcn.004d0ff9
mov edx, dword [rsp + 0x5c]
mov rcx, rax
call fcn.004d1044
lea rdx, str.__size
mov rcx, rax
call fcn.004d0ff9
mov rdx, qword [rsp + 0x88]
sub rdx, qword [rsp + 0x80]
mov rcx, rax
call fcn.004d1044
mov rcx, rax
call fcn.004d13bf
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, r12
call fcn.004cf846
mov al, 1
add rsp, 0x238
pop rbx
pop rsi
pop rdi
pop r12
pop r13
pop r14
ret