Function at 0x140001000
Capabilities:
Enumerate processes
Get session user name

Disassembly:
push rbp
push rbx
push rdi
push r14
push r15
lea rbp, [rsp - 0x1b0]
sub rsp, 0x2b0
mov rax, qword [0x140022008]
xor rax, rsp
mov qword [rbp + 0x1a0], rax
mov r14, rdx
mov rdi, rcx
xor edx, edx
xor r15d, r15d
mov qword [rsp + 0x50], r15
lea ecx, [rdx + 2]
call qword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
xor edx, edx
lea rcx, [rsp + 0x64]
mov r8d, 0x234
mov rbx, rax
call fcn.140003780
lea rdx, [rsp + 0x60]
mov dword [rsp + 0x60], 0x238
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_Process32FirstW]
test eax, eax
je 0x1400010aa
lea rax, [rbp - 0x74]
mov r8, rdi
sub r8, rax
nop word [rax + rax]
movzx edx, word [rax]
movzx ecx, word [rax + r8]
sub edx, ecx
jne 0x140001094
add rax, 2
test ecx, ecx
jne 0x140001080
test edx, edx
je 0x1400010c9
lea rdx, [rsp + 0x60]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_Process32NextW]
test eax, eax
jne 0x140001070
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rdx, rdi
lea rcx, str._____s_process_not_found_n
call fcn.140001b50
xor eax, eax
jmp 0x140001363
mov ebx, dword [rsp + 0x68]
test ebx, ebx
je 0x1400010b3
mov rdx, rdi
mov qword [rsp + 0x2f0], rsi
lea rcx, str.____s_process_found__n
call fcn.140001b50
mov r8d, ebx
mov edx, 1
mov ecx, 0x1000
call qword [sym.imp.KERNEL32.dll_OpenProcess]
mov rsi, rax
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rdx, rdi
test eax, eax
jne 0x1400013a5
lea rcx, str.____s_OpenProcess___success__n
call fcn.140001b50
lea r8, [rsp + 0x50]
mov edx, 0xf
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rdx, rdi
test eax, eax
jne 0x140001381
lea rcx, str.____s_OpenProcessToken___success__n
call fcn.140001b50
mov rcx, qword [rsp + 0x50]
mov r9d, 2
xor r8d, r8d
mov qword [rsp + 0x28], r14
mov edx, 0xf01ff
mov dword [rsp + 0x20], 2
call qword [sym.imp.ADVAPI32.dll_DuplicateTokenEx]
test eax, eax
je 0x140001390
mov rdx, rdi
lea rcx, str.____s_DuplicateTokenEx___success__n
call fcn.140001b50
mov rcx, qword [r14]
call qword [sym.imp.ADVAPI32.dll_ImpersonateLoggedOnUser]
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rdx, rdi
test eax, eax
jne 0x140001332
lea rcx, str.____s_ImpersonatedLoggedOnUser___success__n
call fcn.140001b50
lea rdx, [rsp + 0x58]
mov dword [rsp + 0x58], 0x101
lea rcx, [rsp + 0x60]
call qword [sym.imp.ADVAPI32.dll_GetUserNameW]
mov rbx, 0xffffffffffffffff
mov qword [rsp + 0x30], r15
mov r8, rbx
mov qword [rsp + 0x40], r15
mov qword [rsp + 0x48], 7
lea rax, [rsp + 0x60]
nop word [rax + rax]
inc r8
cmp word [rax + r8*2], r15w
jne 0x1400011f0
lea rdx, [rsp + 0x60]
lea rcx, [rsp + 0x30]
call fcn.140001d70
cmp qword [rsp + 0x48], 8
lea r8, [rsp + 0x30]
mov rdx, rdi
lea rcx, str.____s_Current_user_is:__s_n
cmovae r8, qword [rsp + 0x30]
call fcn.140001b50
mov rdx, qword [rsp + 0x48]
cmp rdx, 8
jb 0x14000126b
mov rcx, qword [rsp + 0x30]
lea rdx, [rdx*2 + 2]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140001266
mov rcx, qword [rcx - 8]
add rdx, 0x27
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400013cf
call fcn.140001f20
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rdx, [rsp + 0x58]
mov dword [rsp + 0x58], 0x101
lea rcx, [rsp + 0x60]
call qword [sym.imp.ADVAPI32.dll_GetUserNameW]
lea rax, [rsp + 0x60]
mov qword [rsp + 0x30], r15
mov qword [rsp + 0x40], r15
mov qword [rsp + 0x48], 7
nop
inc rbx
cmp word [rax + rbx*2], r15w
jne 0x1400012b0
mov r8, rbx
lea rdx, [rsp + 0x60]
lea rcx, [rsp + 0x30]
call fcn.140001d70
cmp qword [rsp + 0x48], 8
lea rdx, [rsp + 0x30]
lea rcx, str.___Current_user_is:__s_n
cmovae rdx, qword [rsp + 0x30]
call fcn.140001b50
mov rdx, qword [rsp + 0x48]
cmp rdx, 8
jb 0x14000132b
mov rcx, qword [rsp + 0x30]
lea rdx, [rdx*2 + 2]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140001326
mov rcx, qword [rcx - 8]
add rdx, 0x27
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400013c9
call fcn.140001f20
mov eax, 1
jmp 0x14000135b
mov r8d, ebx
lea rcx, str._____s_ImpersonatedLoggedOnUser___Return_Code:__i_n
call fcn.140001b50
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rdx, rdi
lea rcx, str._____s_ImpersonatedLoggedOnUser___Error:__i_n
mov r8d, eax
call fcn.140001b50
xor eax, eax
mov rsi, qword [rsp + 0x2f0]
mov rcx, qword [rbp + 0x1a0]
xor rcx, rsp
call fcn.140001f00
add rsp, 0x2b0
pop r15
pop r14
pop rdi
pop rbx
pop rbp
ret
mov r8d, ebx
lea rcx, str._____s_OpenProcessToken___Return_Code:__i_n
call fcn.140001b50
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rdx, rdi
lea rcx, str._____s_OpenProcessToken___Error:__i_n
mov r8d, eax
jmp 0x140001354
mov r8, rsi
lea rcx, str._____s_OpenProcess___Return_Code:__i_n
call fcn.140001b50
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rdx, rdi
lea rcx, str._____s_OpenProcess___Error:__i_n
mov r8d, eax
jmp 0x140001354
call fcn.140005fa8
int3
call fcn.140005fa8
int3