Function at 0x1400029f2
Capabilities:
Acquire debug privileges
Get token privileges

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x60
mov dword [rbp - 0x24], 0x10
mov rax, qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
call rax
lea rdx, [rbp - 0x10]
mov r8, rdx
mov edx, 0x28
mov rcx, rax
mov rax, qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
call rax
test eax, eax
sete al
test al, al
je 0x140002a5b
lea rax, str.Failed_to_open_process_token.
mov rdx, rax
mov rax, qword [sym.imp.libstdc_6.dll_std::cerr]
mov rcx, rax
call sym.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 rcx, rax
mov rax, qword [0x140008ab0]
mov rdx, rax
call sym.std::ostream::operator___std::ostream____std::ostream__
jmp 0x140002cac
mov rax, qword [rbp - 0x10]
lea rcx, [rbp - 0x20]
lea rdx, [rbp - 0x24]
mov qword [rsp + 0x20], rdx
mov r9d, 0x10
mov r8, rcx
mov edx, 3
mov rcx, rax
mov rax, qword [sym.imp.ADVAPI32.dll_GetTokenInformation]
call rax
test eax, eax
sete al
test al, al
je 0x140002acf
lea rax, str.Failed_to_get_token_information.
mov rdx, rax
mov rax, qword [sym.imp.libstdc_6.dll_std::cerr]
mov rcx, rax
call sym.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 rcx, rax
mov rax, qword [0x140008ab0]
mov rdx, rax
call sym.std::ostream::operator___std::ostream____std::ostream__
mov rax, qword [rbp - 0x10]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_CloseHandle]
call rax
jmp 0x140002cac
lea rax, str.Current_Privileges:
mov rdx, rax
mov rax, qword [sym.imp.libstdc_6.dll_std::cout]
mov rcx, rax
call sym.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 rcx, rax
mov rax, qword [0x140008ab0]
mov rdx, rax
call sym.std::ostream::operator___std::ostream____std::ostream__
mov dword [rbp - 4], 0
jmp 0x140002b55
lea rax, str.Privilege:
mov rdx, rax
mov rax, qword [sym.imp.libstdc_6.dll_std::cout]
mov rcx, rax
call sym.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 rcx, rax
mov edx, dword [rbp - 4]
mov rax, rdx
add rax, rax
add rax, rdx
shl rax, 2
add rax, rbp
sub rax, 0x14
mov eax, dword [rax]
mov edx, eax
call sym.std::ostream::operator___unsigned_long_
mov rcx, rax
mov rax, qword [0x140008ab0]
mov rdx, rax
call sym.std::ostream::operator___std::ostream____std::ostream__
add dword [rbp - 4], 1
mov eax, dword [rbp - 0x20]
cmp dword [rbp - 4], eax
jb 0x140002b03
lea rax, str.Privilege_escalation_steps:
mov rdx, rax
mov rax, qword [sym.imp.libstdc_6.dll_std::cout]
mov rcx, rax
call sym.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 rcx, rax
mov rax, qword [0x140008ab0]
mov rdx, rax
call sym.std::ostream::operator___std::ostream____std::ostream__
lea rax, [rbp - 0x2c]
mov r8, rax
lea rax, str.SeDebugPrivilege
mov rdx, rax
mov ecx, 0
mov rax, qword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
call rax
test eax, eax
sete al
test al, al
je 0x140002bf0
lea rax, str.LookupPrivilegeValue_failed.
mov rdx, rax
mov rax, qword [sym.imp.libstdc_6.dll_std::cerr]
mov rcx, rax
call sym.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 rcx, rax
mov rax, qword [0x140008ab0]
mov rdx, rax
call sym.std::ostream::operator___std::ostream____std::ostream__
mov rax, qword [rbp - 0x10]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_CloseHandle]
call rax
jmp 0x140002cac
mov dword [rbp - 0x20], 1
mov rax, qword [rbp - 0x2c]
mov qword [rbp - 0x1c], rax
mov dword [rbp - 0x14], 2
mov rax, qword [rbp - 0x10]
lea rdx, [rbp - 0x20]
mov qword [rsp + 0x28], 0
mov qword [rsp + 0x20], 0
mov r9d, 0x10
mov r8, rdx
mov edx, 0
mov rcx, rax
mov rax, qword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
call rax
test eax, eax
sete al
test al, al
je 0x140002c70
lea rax, str.AdjustTokenPrivileges_failed.
mov rdx, rax
mov rax, qword [sym.imp.libstdc_6.dll_std::cerr]
mov rcx, rax
call sym.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 rcx, rax
mov rax, qword [0x140008ab0]
mov rdx, rax
call sym.std::ostream::operator___std::ostream____std::ostream__
jmp 0x140002c9b
lea rax, str.Privilege_adjusted.
mov rdx, rax
mov rax, qword [sym.imp.libstdc_6.dll_std::cout]
mov rcx, rax
call sym.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 rcx, rax
mov rax, qword [0x140008ab0]
mov rdx, rax
call sym.std::ostream::operator___std::ostream____std::ostream__
mov rax, qword [rbp - 0x10]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_CloseHandle]
call rax
nop
add rsp, 0x60
pop rbp
ret