Function at 0x140001400
Capabilities:
Acquire debug privileges
Get file size
Read file on windows

Disassembly:
push rbx
push r14
sub rsp, 0x98
mov rax, qword [0x140005008]
xor rax, rsp
mov qword [rsp + 0x80], rax
xor r14d, r14d
xorps xmm0, xmm0
mov qword [rsp + 0x40], r14
mov rbx, rdx
movups xmmword [rsp + 0x58], xmm0
cmp ecx, 2
jle 0x14000170c
mov rcx, qword [rdx + 8]
mov qword [rsp + 0xb0], rbp
call qword [sym.imp.api_ms_win_crt_convert_l1_1_0.dll_atoi]
mov ebp, eax
test eax, eax
jne 0x140001479
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
lea rdx, str.ProcessId_Error
call fcn.140001730
mov rcx, rax
lea rdx, [0x140001900]
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
jmp 0x140001704
mov rcx, qword [rbx + 0x10]
xor r9d, r9d
mov qword [rsp + 0x30], r14
xor r8d, r8d
mov dword [rsp + 0x28], 0x80
mov edx, 0x80000000
mov dword [rsp + 0x20], 3
mov qword [rsp + 0x90], rdi
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rdi, rax
cmp rax, 0xffffffffffffffff
jne 0x1400014dc
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
lea rdx, str.Failed_to_open_the_DLL_file.
call fcn.140001730
mov rcx, rax
lea rdx, [0x140001900]
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
jmp 0x1400016fc
xor edx, edx
mov qword [rsp + 0xc0], rsi
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
lea ecx, [rsi - 1]
cmp ecx, 0xfffffffd
ja 0x1400016d1
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8d, esi
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov rbx, rax
test rax, rax
jne 0x140001525
lea rdx, str.Failed_to_alloc_a_buffer.
jmp 0x1400016d8
lea r9, [rsp + 0x50]
mov dword [rsp + 0x50], r14d
mov r8d, esi
mov qword [rsp + 0x20], r14
mov rdx, rbx
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x140001553
lea rdx, str.Failed_to_read_the_DLL_file
jmp 0x14000169f
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea r8, [rsp + 0x40]
mov edx, 0x28
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x1400015c2
lea r8, [rsp + 0x5c]
mov dword [rsp + 0x58], 1
lea rdx, str.SeDebugPrivilege
mov dword [rsp + 0x64], 2
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueW]
test eax, eax
je 0x1400015b7
mov rcx, qword [rsp + 0x40]
lea r8, [rsp + 0x58]
mov qword [rsp + 0x28], r14
xor r9d, r9d
xor edx, edx
mov qword [rsp + 0x20], r14
call qword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea r8, [rsp + 0x48]
mov edx, 0x28
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x140001698
lea r8, [rsp + 0x68]
xor ecx, ecx
lea rdx, str.SeDebugPrivilege
call qword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueW]
test eax, eax
je 0x140001698
mov rax, qword [rsp + 0x68]
lea r8, [rsp + 0x70]
mov rcx, qword [rsp + 0x48]
mov r9d, 0x10
mov qword [rsp + 0x28], r14
xor edx, edx
mov qword [rsp + 0x74], rax
mov dword [rsp + 0x70], 1
mov dword [rsp + 0x7c], 2
mov qword [rsp + 0x20], r14
call qword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
test eax, eax
je 0x140001698
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r8d, ebp
xor edx, edx
mov ecx, 0x43a
call qword [sym.imp.KERNEL32.dll_OpenProcess]
mov rdi, rax
test rax, rax
jne 0x14000166b
lea rdx, str.Failed_to_Open_the_Target_Process.
jmp 0x14000169f
mov r8d, esi
mov rdx, rbx
mov rcx, rdi
call fcn.140001300
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, rbx
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x1400016f4
lea rdx, str.Failed_to_Escalate_Privilege.
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
call fcn.140001730
mov rcx, rax
lea rdx, [0x140001900]
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, rbx
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x1400016f4
lea rdx, str.Failed_to_get_the_DLL_file_size.
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
call fcn.140001730
lea rdx, [0x140001900]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
mov rsi, qword [rsp + 0xc0]
mov rdi, qword [rsp + 0x90]
mov rbp, qword [rsp + 0xb0]
xor eax, eax
mov rcx, qword [rsp + 0x80]
xor rcx, rsp
call fcn.1400019c0
add rsp, 0x98
pop r14
pop rbx
ret