Function at 0x140159880
Capabilities:
Create process on windows
Create process suspended

Disassembly:
mov qword [rsp + 8], rcx
push rsi
push rdi
sub rsp, 0x278
mov rax, qword [0x140325ed8]
xor rax, rsp
mov qword [rsp + 0x260], rax
xor eax, eax
cmp eax, 1
je 0x1401598bf
call fcn.1401597d0
test eax, eax
je 0x1401598b2
jmp 0x1401598bf
mov ecx, 0x3e8
call qword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x1401598a0
call qword [sym.imp.KERNEL32.dll_WTSGetActiveConsoleSessionId]
mov dword [rsp + 0x60], eax
mov qword [rsp + 0x78], 0
mov qword [rsp + 0x68], 0
mov dword [rsp + 0x70], 0
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea r8, [rsp + 0x78]
mov edx, 0xf00ff
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
mov eax, listen
imul rax, rax, 0
lea rax, [rsp + rax + 0x124]
mov r8, rax
lea rdx, str.SeTcbPrivilege
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
mov dword [rsp + 0x120], 1
mov eax, listen
imul rax, rax, 0
mov dword [rsp + rax + 0x12c], 2
lea rax, [rsp + 0x70]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x130]
mov qword [rsp + 0x20], rax
mov r9d, reloc.WS2_32.dll_recv
lea r8, [rsp + 0x120]
xor edx, edx
mov rcx, qword [rsp + 0x78]
call qword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
lea rax, [rsp + 0x68]
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], 1
mov r9d, 1
xor r8d, r8d
mov edx, 0x2000000
mov rcx, qword [rsp + 0x78]
call qword [sym.imp.ADVAPI32.dll_DuplicateTokenEx]
mov r9d, 4
lea r8, [rsp + 0x60]
mov edx, listen
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.ADVAPI32.dll_SetTokenInformation]
mov qword [rsp + 0x88], 0
lea rdx, [rsp + 0x88]
mov ecx, dword [rsp + 0x60]
call qword [sym.imp.WTSAPI32.dll_WTSQueryUserToken]
mov qword [rsp + 0x80], 0
mov r8d, 1
mov rdx, qword [rsp + 0x88]
lea rcx, [rsp + 0x80]
call qword [sym.imp.USERENV.dll_CreateEnvironmentBlock]
lea rax, [rsp + 0x140]
lea rcx, str.WinSta0Default
mov rdi, rax
mov rsi, rcx
mov ecx, reloc.WS2_32.dll_recv
rep movsb byte [rdi], byte [rsi]
lea rax, [rsp + 0xb0]
mov rdi, rax
xor eax, eax
mov ecx, 0x68
rep stosb byte [rdi], al
mov dword [rsp + 0xb0], WSAGetLastError
lea rax, [rsp + 0x90]
mov rdi, rax
xor eax, eax
mov ecx, 0x18
rep stosb byte [rdi], al
lea rax, [rsp + 0x150]
mov rdi, rax
xor eax, eax
mov ecx, 0x104
rep stosb byte [rdi], al
mov dword [rsp + 0x74], 0x430
mov r8, qword [rsp + 0x290]
mov edx, 0x104
lea rcx, [rsp + 0x150]
call fcn.1401588f0
lea rax, [rsp + 0x90]
mov qword [rsp + 0x50], rax
lea rax, [rsp + 0xb0]
mov qword [rsp + 0x48], rax
mov qword [rsp + 0x40], 0
mov rax, qword [rsp + 0x80]
mov qword [rsp + 0x38], rax
mov eax, dword [rsp + 0x74]
mov dword [rsp + 0x30], eax
mov dword [rsp + 0x28], 0
mov qword [rsp + 0x20], 0
xor r9d, r9d
xor r8d, r8d
lea rdx, [rsp + 0x150]
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.ADVAPI32.dll_CreateProcessAsUserA]
mov edx, 0xffffffff
mov rcx, qword [rsp + 0x90]
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, qword [rsp + 0x98]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x90]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x80]
call qword [sym.imp.USERENV.dll_DestroyEnvironmentBlock]
mov rcx, qword [rsp + 0x88]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x260]
xor rcx, rsp
call fcn.14026d940
add rsp, 0x278
pop rdi
pop rsi
ret