Function at 0x1400971f0
Capabilities:
Enumerate processes

Disassembly:
push rbp
push r12
lea rbp, [rsp - 0xc8]
sub rsp, 0x1c8
mov r12, rcx
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea r8, [rsp + 0x38]
mov edx, 0xa
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x14009752d
mov rcx, qword [rsp + 0x38]
lea rax, [rsp + 0x48]
mov r9d, 4
mov qword [rsp + 0x20], rax
lea r8, [rbp + 0xe8]
mov qword [rsp + 0x1c0], rbx
mov edx, listen
call qword [sym.imp.ADVAPI32.dll_GetTokenInformation]
test eax, eax
je 0x140097505
mov qword [rsp + 0x1a0], r15
lea r8, [rsp + 0x58]
mov r15d, dword [rbp + 0xe8]
lea rdx, str.SeTcbPrivilege
xor ecx, ecx
mov qword [rsp + 0x1b8], rsi
mov dword [rsp + 0x50], 1
mov dword [rsp + 0x54], 1
call qword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
je 0x14009742a
xor edx, edx
mov ecx, 2
call qword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
mov rsi, rax
cmp rax, 0xffffffffffffffff
je 0x14009742a
mov qword [rsp + 0x1a8], r14
lea rdx, [rsp + 0x70]
mov rcx, rax
mov dword [rsp + 0x70], pe_nt_image_headers64
xor r14d, r14d
mov ebx, 0x490
call qword [sym.imp.KERNEL32.dll_Process32First]
test eax, eax
je 0x140097417
mov qword [rsp + 0x1b0], rdi
lea rdx, str.winlogon.exe
lea rcx, [rbp - 0x64]
call qword [sym.imp.api_ms_win_crt_multibyte_l1_1_0.dll__mbsicmp]
test eax, eax
jne 0x1400973f9
mov r8d, dword [rsp + 0x78]
xor edx, edx
mov ecx, 0x1000
call qword [sym.imp.KERNEL32.dll_OpenProcess]
mov rdi, rax
test rax, rax
je 0x1400973f4
lea r8, [rsp + 0x30]
mov edx, 0xa
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x1400973eb
mov rcx, qword [rsp + 0x30]
lea r8, [rbp + 0xf0]
lea rdx, [rsp + 0x50]
call qword [sym.imp.ADVAPI32.dll_PrivilegeCheck]
test eax, eax
je 0x1400973e0
cmp dword [rbp + 0xf0], 0
je 0x1400973e0
mov rcx, qword [rsp + 0x30]
lea rax, [rsp + 0x4c]
mov r9d, 4
mov qword [rsp + 0x20], rax
lea r8, [rbp + 0xf8]
mov edx, listen
call qword [sym.imp.ADVAPI32.dll_GetTokenInformation]
test eax, eax
je 0x1400973e0
cmp dword [rbp + 0xf8], r15d
jne 0x1400973e0
mov rcx, qword [rsp + 0x30]
lea rax, [rsp + 0x40]
mov qword [rsp + 0x28], rax
mov r9d, 2
xor r8d, r8d
mov dword [rsp + 0x20], 2
mov edx, 4
mov r14d, 1
call qword [sym.imp.ADVAPI32.dll_DuplicateTokenEx]
test eax, eax
je 0x1400973d8
xor ebx, ebx
jmp 0x1400973e0
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test r14d, r14d
jne 0x14009740f
lea rdx, [rsp + 0x70]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_Process32Next]
test eax, eax
jne 0x1400972f1
mov rdi, qword [rsp + 0x1b0]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r14, qword [rsp + 0x1a8]
jmp 0x140097432
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
mov r15, qword [rsp + 0x1a0]
mov rsi, qword [rsp + 0x1b8]
test ebx, ebx
jne 0x14009750d
mov rdx, qword [rsp + 0x40]
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_SetThreadToken]
test eax, eax
je 0x1400974f0
mov rcx, qword [rsp + 0x38]
xor r9d, r9d
mov qword [rsp + 0x28], r12
xor r8d, r8d
mov edx, Ordinal_143
mov dword [rsp + 0x20], 1
call qword [sym.imp.ADVAPI32.dll_DuplicateTokenEx]
test eax, eax
je 0x1400974d5
mov rcx, qword [r12]
lea r8, [rbp + 0xf0]
mov r9d, 4
mov dword [rbp + 0xf0], 1
mov edx, reloc.WLDAP32.dll_Ordinal_26
call qword [sym.imp.ADVAPI32.dll_SetTokenInformation]
test eax, eax
jne 0x1400974dd
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, qword [r12]
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_CloseHandle]
call qword [sym.imp.ADVAPI32.dll_RevertToSelf]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x14009750d
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
call qword [sym.imp.ADVAPI32.dll_RevertToSelf]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x14009750d
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, qword [rsp + 0x40]
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x14009750d
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, ebx
mov rbx, qword [rsp + 0x1c0]
add rsp, 0x1c8
pop r12
pop rbp
ret
call qword [sym.imp.KERNEL32.dll_GetLastError]
add rsp, 0x1c8
pop r12
pop rbp
ret