Function at 0x14005f3b0
Capabilities:
Check if file exists
Get token membership

Disassembly:
push r14
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x80
mov edi, edx
mov rax, qword [0x14022a038]
xor rax, rsp
mov qword [rsp + 0x78], rax
movabs r14, 0xaaaaaaaaaaaaaaaa
lea rsi, [rsp + 0x68]
mov qword [rsi], r14
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov rcx, rax
mov edx, 0xa
mov r8, rsi
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x14005f426
mov rsi, qword [rsp + 0x68]
test rsi, rsi
je 0x14005f42d
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
cmp rsi, 0xffffffffffffffff
je 0x14005f60e
call fcn.1400fc5f0
mov ecx, ebx
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x14005f42f
xor edi, edi
jmp 0x14005f5dd
xor esi, esi
cmp edi, 1
jne 0x14005f4e1
call fcn.14010f210
cmp eax, 3
jl 0x14005f4e1
mov eax, 0xaaaaaaaa
lea r8, [rsp + 0x70]
mov dword [r8], eax
lea rdi, [rsp + 0x64]
mov dword [rdi], eax
mov qword [rsp + 0x20], rdi
mov rcx, rsi
mov edx, shutdown
mov r9d, 4
call qword [sym.imp.ADVAPI32.dll_GetTokenInformation]
test eax, eax
je 0x14005f525
cmp dword [rsp + 0x70], 3
jne 0x14005f4e1
lea r8, [rsp + 0x58]
mov qword [r8], r14
mov qword [rsp + 0x20], rdi
mov rcx, rsi
mov edx, shutdown
mov r9d, 8
call qword [sym.imp.ADVAPI32.dll_GetTokenInformation]
test eax, eax
je 0x14005f525
mov rbx, qword [rsp + 0x58]
cmp rsi, rbx
je 0x14005f4e1
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
lea rax, [rsi + 1]
cmp rax, 2
jae 0x14005f5fa
lea rax, [rbx + 1]
cmp rax, 2
jb 0x14005f4d9
call fcn.1400fc5f0
mov rsi, rbx
mov ecx, edi
call qword [sym.imp.KERNEL32.dll_SetLastError]
lea r8, [rsp + 0x68]
mov rcx, rsi
mov edx, 1
call qword [sym.imp.ADVAPI32.dll_DuplicateToken]
test eax, eax
je 0x14005f525
mov rbx, qword [rsp + 0x68]
xor edi, edi
test rbx, rbx
je 0x14005f52c
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebp, eax
cmp rbx, 0xffffffffffffffff
je 0x14005f615
call fcn.1400fc5f0
mov ecx, ebp
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x14005f52e
xor edi, edi
jmp 0x14005f5c6
xor ebx, ebx
lea rcx, [rsp + 0x70]
mov dword [rcx], edi
mov word [rcx + 4], 0x500
lea rax, [rsp + 0x58]
mov qword [rax], r14
mov qword [rsp + 0x50], rax
mov dword [rsp + 0x48], edi
mov dword [rsp + 0x40], edi
mov dword [rsp + 0x38], edi
mov dword [rsp + 0x30], edi
mov dword [rsp + 0x28], edi
mov dword [rsp + 0x20], edi
mov dl, 2
mov r8d, 0x20
mov r9d, 0x220
call qword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
mov dword [rsp + 0x64], eax
test eax, eax
je 0x14005f5af
mov rdx, qword [rsp + 0x58]
lea r8, [rsp + 0x64]
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_CheckTokenMembership]
test eax, eax
jne 0x14005f59b
mov dword [rsp + 0x64], 0
mov rcx, qword [rsp + 0x58]
call qword [sym.imp.ADVAPI32.dll_FreeSid]
cmp dword [rsp + 0x64], 1
sete dil
lea rax, [rbx + 1]
cmp rax, 2
jb 0x14005f5c6
call fcn.1400fc5f0
mov rcx, rbx
call fcn.14010ef00
lea rax, [rsi + 1]
cmp rax, 2
jb 0x14005f5dd
call fcn.1400fc5f0
mov rcx, rsi
call fcn.14010ef00
mov rcx, qword [rsp + 0x78]
xor rcx, rsp
call fcn.140148f60
mov eax, edi
add rsp, 0x80
pop rbx
pop rbp
pop rdi
pop rsi
pop r14
ret
call fcn.1400fc5f0
mov rcx, rsi
call fcn.14010ef00
xor esi, esi
jmp 0x14005f4c7
xor esi, esi
jmp 0x14005f41c
xor ebx, ebx
jmp 0x14005f51b