Function at 0x140024bc0
Capabilities:
Get token membership

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rdi
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x37]
sub rsp, 0xa0
mov rax, qword [0x140130ac8]
xor rax, rsp
mov qword [rbp + 0x2f], rax
xor r15d, r15d
mov rdi, rdx
mov rbx, rcx
test rdx, rdx
je 0x140024e0f
mov byte [rdx], r15b
xor edx, edx
mov r8d, dword [rcx + 0x220]
mov ecx, 0x1fffff
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_1.dll_OpenProcess]
mov r14, rax
test rax, rax
jne 0x140024c43
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
movzx edi, ax
or edi, 0x80070000
test eax, eax
cmovle edi, eax
mov eax, 0x80004005
test edi, edi
cmovns edi, eax
mov eax, edi
jmp 0x140024e14
lea r9, [rbp - 5]
mov dword [rbp - 5], 0x104
lea r8, [rbx + 0x224]
xor edx, edx
mov rcx, r14
call qword [sym.imp.api_ms_win_core_psapi_l1_1_0.dll_QueryFullProcessImageNameW]
or r12, 0xffffffffffffffff
test eax, eax
jne 0x140024c8e
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
lea r9, str.QueryFullProcessImageName___failed__error___u_n
mov r8, r12
lea rcx, [rbx + 0x224]
mov dword [rsp + 0x20], eax
mov edx, 0x104
call qword [sym.imp.msvcrt.dll__snwprintf_s]
lea rbx, [0x1400d7440]
mov qword [rbp + 0x17], r15
lea r8, [rbp + 0x17]
mov qword [rbp + 0xf], rbx
mov edx, 0xf01ff
mov rcx, r14
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_0.dll_OpenProcessToken]
test eax, eax
jne 0x140024cd6
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
movzx edi, ax
or edi, 0x80070000
test eax, eax
cmovle edi, eax
mov eax, 0x80004005
test edi, edi
cmovns edi, eax
jmp 0x140024de1
mov rcx, qword [rbp + 0x17]
lea r13, [0x1400d7440]
lea r8, [rbp + 7]
mov qword [rbp - 1], r13
mov edx, 2
mov qword [rbp + 7], r12
call qword [sym.imp.api_ms_win_security_base_l1_1_0.dll_DuplicateToken]
test eax, eax
je 0x140024d4d
lea rax, [rbp + 0x1f]
mov dword [rbp + 0x27], r15d
mov qword [rsp + 0x50], rax
lea rcx, [rbp + 0x27]
mov dword [rsp + 0x48], r15d
mov r9d, 0x220
mov dword [rsp + 0x40], r15d
mov r8d, 0x20
mov dword [rsp + 0x38], r15d
mov dl, 2
mov dword [rsp + 0x30], r15d
mov dword [rsp + 0x28], r15d
mov dword [rsp + 0x20], r15d
mov word [rbp + 0x2b], 0x500
mov qword [rbp + 0x1f], r15
call qword [sym.imp.api_ms_win_security_base_l1_1_0.dll_AllocateAndInitializeSid]
test eax, eax
jne 0x140024d6d
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
movzx edi, ax
or edi, 0x80070000
test eax, eax
cmovle edi, eax
mov eax, 0x80004005
test edi, edi
cmovns edi, eax
jmp 0x140024dc6
mov rbx, qword [rbp + 0x1f]
lea r8, [rbp - 9]
mov rcx, qword [rbp + 7]
mov rdx, rbx
mov dword [rbp - 9], r15d
call qword [sym.imp.api_ms_win_security_base_l1_1_0.dll_CheckTokenMembership]
test eax, eax
jne 0x140024daa
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
movzx edi, ax
or edi, 0x80070000
test eax, eax
cmovle edi, eax
mov eax, 0x80004005
test edi, edi
cmovns edi, eax
jmp 0x140024db6
cmp dword [rbp - 9], r15d
setne al
mov byte [rdi], al
mov edi, r15d
mov rcx, rbx
call qword [sym.imp.api_ms_win_security_base_l1_1_0.dll_FreeSid]
lea rbx, [0x1400d7440]
mov rcx, qword [rbp + 7]
mov qword [rbp - 1], r13
cmp rcx, r12
je 0x140024de1
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
test eax, eax
je 0x140024e3d
mov qword [rbp + 7], r12
mov rcx, qword [rbp + 0x17]
mov qword [rbp + 0xf], rbx
test rcx, rcx
je 0x140024dfc
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
test eax, eax
je 0x140024e57
mov qword [rbp + 0x17], r15
mov rcx, r14
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
test eax, eax
jne 0x140024c3c
jmp 0x140024e71
mov eax, 0x80004003
mov rcx, qword [rbp + 0x2f]
xor rcx, rsp
call fcn.1400cba70
lea r11, [rsp + 0xa0]
mov rbx, qword [r11 + 0x40]
mov rdi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
movzx ecx, ax
or ecx, 0x80070000
test eax, eax
cmovle ecx, eax
call fcn.14000bfec
int3
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
movzx ecx, ax
or ecx, 0x80070000
test eax, eax
cmovle ecx, eax
call fcn.14000bfec
int3
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
movzx ecx, ax
or ecx, 0x80070000
test eax, eax
cmovle ecx, eax
call fcn.14000bfec
int3