Function at 0x1400bd770
Capabilities:
Acquire debug privileges
Create process on windows
Enumerate processes

Disassembly:
push rbp
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x2c8]
sub rsp, 0x3c8
mov rax, qword [0x14013c010]
xor rax, rsp
mov qword [rbp + 0x2b0], rax
mov r14, r8
mov r15, rdx
mov qword [rsp + 0x68], rdx
mov r13, rcx
mov qword [rsp + 0x78], rcx
mov qword [rbp - 0x80], rdx
mov qword [rbp - 0x78], r8
mov dword [rbp + 0x40], r9d
mov rax, qword [rbp + 0x330]
mov qword [rsp + 0x70], rax
xor r12d, r12d
mov qword [rbp - 0x58], r12
mov qword [rbp - 0x70], r12
mov qword [rbp - 0x68], r12
call fcn.1400046f0
mov rcx, rax
test rax, rax
je 0x1400bddb2
mov rax, qword [rax]
mov rax, qword [rax + 0x18]
call qword [case.0x140048c62.0]
lea rbx, [rax + 0x18]
mov qword [rbp + 0x50], rbx
mov eax, dword [rbp + 0x40]
mov dword [rsp + 0x30], eax
mov rax, qword [r14]
mov qword [rsp + 0x28], rax
mov rax, qword [r15]
mov qword [rsp + 0x20], rax
mov r9, qword [r13]
lea r8d, [r12 + 0x42]
lea rdx, str.CWin32AppMgr::LaunchAppIntoDifferentSession
lea rcx, str._s__d_sFile_s_sArgs_s_sAppNameForClonePrivilege_s_dwSessionId_d
call fcn.14005b9a0
xor edx, edx
lea ecx, [rdx + 2]
call qword [sym.imp.api_ms_win_core_toolhelp_l1_1_0.dll_CreateToolhelp32Snapshot]
mov rsi, rax
mov rdi, 0xffffffffffffffff
cmp rax, rdi
jne 0x1400bd858
lea r8d, [r12 + 0x4b]
lea rcx, str._s__d_EXIT_ON_TRUE
jmp 0x1400bd8d1
mov dword [rbp + 0x70], 0x238
lea rdx, [rbp + 0x70]
mov rcx, rsi
call qword [sym.imp.api_ms_win_core_toolhelp_l1_1_0.dll_Process32FirstW]
test eax, eax
jne 0x1400bd880
lea r8d, [rax + 0x50]
jmp 0x1400bd8ca
mov rdx, qword [r14]
lea rcx, [rbp + 0x9c]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsicmp]
test eax, eax
jne 0x1400bd8b5
mov dword [rbp + 0x48], r12d
lea rdx, [rbp + 0x48]
mov ecx, dword [rbp + 0x78]
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_0.dll_ProcessIdToSessionId]
test eax, eax
je 0x1400bd8b5
mov ecx, dword [rbp + 0x40]
cmp dword [rbp + 0x48], ecx
je 0x1400bd9e4
lea rdx, [rbp + 0x70]
mov rcx, rsi
call qword [sym.imp.api_ms_win_core_toolhelp_l1_1_0.dll_Process32NextW]
test eax, eax
jne 0x1400bd880
lea r8d, [rax + 0x63]
lea rcx, str._s__d_EXIT_ON_FALSE
lea rdx, str.CWin32AppMgr::LaunchAppIntoDifferentSession
call fcn.14005b9a0
mov rcx, qword [rbp - 0x58]
test rcx, rcx
je 0x1400bd8f0
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
mov qword [rbp - 0x58], r12
mov rcx, qword [rbp - 0x70]
test rcx, rcx
je 0x1400bd903
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
mov qword [rbp - 0x70], r12
mov rcx, qword [rbp - 0x68]
test rcx, rcx
je 0x1400bd916
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
mov qword [rbp - 0x68], r12
test rsi, rsi
je 0x1400bd925
mov rcx, rsi
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
nop
lea rdx, [rbx - 0x18]
mov eax, edi
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x1400bd949
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
mov rax, qword [rax + 8]
call qword [case.0x140048c62.0]
nop
mov rdx, qword [r13]
sub rdx, 0x18
mov eax, edi
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x1400bd971
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
mov rax, qword [rax + 8]
call qword [case.0x140048c62.0]
nop
mov rdx, qword [r15]
sub rdx, 0x18
mov eax, edi
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x1400bd998
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
mov rax, qword [rax + 8]
call qword [case.0x140048c62.0]
nop
mov rdx, qword [r14]
sub rdx, 0x18
lock xadd dword [rdx + 0x10], edi
sub edi, 1
jg 0x1400bd9bc
lfence
mov rcx, qword [rdx]
mov r8, qword [rcx]
mov rax, qword [r8 + 8]
call qword [case.0x140048c62.0]
mov eax, 1
mov rcx, qword [rbp + 0x2b0]
xor rcx, rsp
call fcn.1400c17f0
add rsp, 0x3c8
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret
mov r15d, dword [rbp + 0x78]
lea rdx, [rbp - 0x58]
call qword [sym.imp.WTSAPI32.dll_WTSQueryUserToken]
mov dword [rsp + 0x60], 0x30
xorps xmm0, xmm0
xor eax, eax
movups xmmword [rbp - 0x30], xmm0
movups xmmword [rbp - 0x20], xmm0
movups xmmword [rbp - 0x10], xmm0
movups xmmword [rbp], xmm0
movups xmmword [rbp + 0x10], xmm0
movups xmmword [rbp + 0x20], xmm0
mov qword [rbp + 0x30], rax
mov dword [rbp - 0x30], 0x68
lea rax, str.winsta0default
mov qword [rbp - 0x20], rax
xor eax, eax
movups xmmword [rbp - 0x50], xmm0
mov qword [rbp - 0x40], rax
mov r8d, r15d
xor edx, edx
mov ecx, 0x2000000
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_1.dll_OpenProcess]
mov r12, rax
test rax, rax
jne 0x1400bda7e
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov dword [rsp + 0x20], eax
mov r9d, r15d
lea r8d, [r12 + 0x73]
lea rdx, str.CWin32AppMgr::LaunchAppIntoDifferentSession
lea rcx, str._s__d_OpenProcess_ClonePrivilegeProcPid_d_Err_u
call fcn.14005b9a0
mov r15, qword [rsp + 0x68]
jmp 0x1400bd8dd
lea r8, [rbp - 0x68]
mov edx, 0x201eb
mov rcx, r12
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_0.dll_OpenProcessToken]
test eax, eax
jne 0x1400bdacc
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov r9d, eax
mov r8d, 0x7b
lea rdx, str.CWin32AppMgr::LaunchAppIntoDifferentSession
lea rcx, str._s__d_OpenProcessToken_Err_u
call fcn.14005b9a0
mov r15, qword [rsp + 0x68]
mov rcx, r12
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
xor r12d, r12d
jmp 0x1400bd8dd
lea rax, [rbp - 0x70]
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], 1
mov r9d, 1
xor r8d, r8d
mov edx, 0x2000000
mov rcx, qword [rbp - 0x68]
call qword [sym.imp.api_ms_win_security_base_l1_1_0.dll_DuplicateTokenEx]
test eax, eax
jne 0x1400bdb31
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov r9d, eax
mov r8d, 0x82
lea rdx, str.CWin32AppMgr::LaunchAppIntoDifferentSession
lea rcx, str._s__d_DuplicateTokenEx_Err_u
call fcn.14005b9a0
mov r15, qword [rsp + 0x68]
mov rcx, r12
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
xor r12d, r12d
jmp 0x1400bd8dd
mov r9d, 4
lea r8, [rbp + 0x40]
lea edx, [r9 + 8]
mov rcx, qword [rbp - 0x70]
call qword [sym.imp.api_ms_win_security_base_l1_1_0.dll_SetTokenInformation]
test eax, eax
jne 0x1400bdb6f
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov r9d, eax
mov r8d, 0x89
lea rdx, str.CWin32AppMgr::LaunchAppIntoDifferentSession
lea rcx, str._s__d_SetTokenInformation_Err_u
call fcn.14005b9a0
lea r8, [rbp + 0x58]
lea rdx, str.SeDebugPrivilege
xor ecx, ecx
call qword [sym.imp.api_ms_win_security_lsalookup_l2_1_0.dll_LookupPrivilegeValueW]
test eax, eax
jne 0x1400bdba8
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov r9d, eax
mov r8d, 0x8f
lea rdx, str.CWin32AppMgr::LaunchAppIntoDifferentSession
lea rcx, str._s__d_LookupPrivilegeValue_Err_u
call fcn.14005b9a0
mov dword [rbp + 0x60], 1
mov rax, qword [rbp + 0x58]
mov qword [rbp + 0x64], rax
mov dword [rbp + 0x6c], 2
xor r15d, r15d
mov qword [rsp + 0x28], r15
mov qword [rsp + 0x20], r15
lea r9d, [r15 + 0x10]
lea r8, [rbp + 0x60]
xor edx, edx
mov rcx, qword [rbp - 0x70]
call qword [sym.imp.api_ms_win_security_base_l1_1_0.dll_AdjustTokenPrivileges]
test eax, eax
jne 0x1400bdc20
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
lea rdx, str.CWin32AppMgr::LaunchAppIntoDifferentSession
cmp eax, 0x514
jne 0x1400bdc0b
mov r8d, 0x9b
lea rcx, str._s__d_Token_does_not_have_the_provilege
call fcn.14005b9a0
jmp 0x1400bdc20
mov r9d, eax
mov r8d, 0x9f
lea rcx, str._s__d_AdjustTokenPrivileges_Err_u
call fcn.14005b9a0
mov qword [rbp - 0x60], r15
mov r8d, 1
mov rdx, qword [rbp - 0x70]
lea rcx, [rbp - 0x60]
call qword [sym.imp.USERENV.dll_CreateEnvironmentBlock]
test eax, eax
je 0x1400bdc46
mov dword [rsp + 0x60], 0x430
jmp 0x1400bdc4a
mov qword [rbp - 0x60], r15
mov rdx, qword [r13]
lea rcx, [rdx - 0x18]
add rbx, 0xffffffffffffffe8
cmp rcx, rbx
je 0x1400bdcaa
cmp dword [rbx + 0x10], r15d
jl 0x1400bdc9d
mov rax, qword [rbx]
cmp qword [rcx], rax
jne 0x1400bdc9d
call fcn.140006460
mov r15, rax
mov ecx, edi
lock xadd dword [rbx + 0x10], ecx
sub ecx, 1
jg 0x1400bdc93
lfence
mov rcx, qword [rbx]
mov r8, qword [rcx]
mov rdx, rbx
mov rax, qword [r8 + 8]
call qword [case.0x140048c62.0]
lea rax, [r15 + 0x18]
mov qword [rbp + 0x50], rax
jmp 0x1400bdcaa
mov r8d, dword [rdx - 0x10]
lea rcx, [rbp + 0x50]
call fcn.1400040e0
lea rdx, [0x1400fb9bc]
mov rax, rdi
inc rax
cmp word [rdx + rax*2], 0
jne 0x1400bdcb4
mov r8d, eax
lea rcx, [rbp + 0x50]
call fcn.140010240
mov r15, qword [rsp + 0x68]
mov rdx, qword [r15]
mov r8d, dword [rdx - 0x10]
lea rcx, [rbp + 0x50]
call fcn.140010240
lea rax, [rbp - 0x50]
mov qword [rsp + 0x50], rax
lea rax, [rbp - 0x30]
mov qword [rsp + 0x48], rax
xor ecx, ecx
mov qword [rsp + 0x40], rcx
mov rax, qword [rbp - 0x60]
mov qword [rsp + 0x38], rax
mov eax, dword [rsp + 0x60]
mov dword [rsp + 0x30], eax
mov dword [rsp + 0x28], ecx
mov qword [rsp + 0x20], rcx
xor r9d, r9d
mov rbx, qword [rbp + 0x50]
mov r8, rbx
xor edx, edx
mov rcx, qword [rbp - 0x70]
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_0.dll_CreateProcessAsUserW]
mov ecx, dword [rbp - 0x40]
mov rdx, qword [rsp + 0x70]
mov dword [rdx], ecx
test eax, eax
je 0x1400bdd7f
mov rcx, qword [rbp - 0x50]
lea rax, [rcx - 1]
cmp rax, 0xfffffffffffffffd
ja 0x1400bdd52
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
mov qword [rbp - 0x50], 0
mov rcx, qword [rbp - 0x48]
lea rax, [rcx - 1]
cmp rax, 0xfffffffffffffffd
ja 0x1400bdda1
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
mov qword [rbp - 0x48], 0
mov rcx, r12
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
xor r12d, r12d
jmp 0x1400bd8dd
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov r9d, eax
mov r8d, 0xcb
lea rdx, str.CWin32AppMgr::LaunchAppIntoDifferentSession
lea rcx, str._s__d_CreateProcessAsUser_Err_u
call fcn.14005b9a0
mov rcx, r12
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
xor r12d, r12d
jmp 0x1400bd8dd
mov ecx, 0x80004005
call fcn.140004820
int3