Function at 0x41e99b
Capabilities:
Create process on windows
Enumerate processes

Disassembly:
push 0x304
mov eax, 0x4bf721
call fcn.0049f5ab
mov esi, ecx
mov edi, edx
push str.CLocalSystemCommands::LaunchAppIntoDifferentSessionFromService___app_name
lea ecx, [ebp - 0x284]
mov dword [ebp - 0x298], esi
mov dword [ebp - 0x29c], edi
call fcn.00404bd0
lea eax, [ebp - 0x284]
push esi
xor ebx, ebx
push eax
mov dword [ebp - 4], ebx
call fcn.00401985
or dword [ebp - 4], 0xffffffff
pop ecx
pop ecx
xor esi, esi
push ebx
inc esi
push esi
lea ecx, [ebp - 0x284]
call fcn.004058b3
push str.CLocalSystemCommands::LaunchAppIntoDifferentSessionFromService___parameters
lea ecx, [ebp - 0x284]
call fcn.00404bd0
lea eax, [ebp - 0x284]
push edi
push eax
mov dword [ebp - 4], esi
call fcn.00401985
or dword [ebp - 4], 0xffffffff
pop ecx
pop ecx
push ebx
push esi
lea ecx, [ebp - 0x284]
call fcn.004058b3
push str.CLocalSystemCommands::LaunchAppIntoDifferentSessionFromService___session_id
lea ecx, [ebp - 0x284]
call fcn.00404bd0
push 2
pop edi
push dword [ebp + 8]
lea eax, [ebp - 0x284]
push eax
mov dword [ebp - 4], edi
call fcn.004018c5
pop ecx
pop ecx
push ebx
push esi
lea ecx, [ebp - 0x284]
call fcn.004058b3
push ebx
lea ecx, [ebp - 0x2c]
mov dword [ebp - 0x268], ebx
mov dword [ebp - 0x288], ebx
mov dword [ebp - 0x14], 7
call fcn.00405ece
push ebx
push edi
mov dword [ebp - 4], 3
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov edi, eax
cmp edi, 0xffffffff
jne 0x41eacd
push str.CLocalSystemCommands::LaunchAppIntoDifferentSessionFromService___CreateToolhelp32Snapshot_failed.
lea ecx, [ebp - 0x284]
call fcn.00404bd0
mov byte [ebp - 4], 4
lea eax, [ebp - 0x284]
push eax
call fcn.004017f5
pop ecx
push ebx
push esi
lea ecx, [ebp - 0x284]
call fcn.004058b3
push ebx
push esi
lea ecx, [ebp - 0x2c]
call fcn.004058b3
mov eax, 0x3eb
call fcn.0049f62e
ret
lea eax, [ebp - 0x260]
push eax
push edi
mov dword [ebp - 0x260], 0x22c
call sub.KERNEL32.dll_Process32FirstW
test eax, eax
jne 0x41eafe
push str.CLocalSystemCommands::LaunchAppIntoDifferentSessionFromService___Process32First_failed.
lea ecx, [ebp - 0x284]
call fcn.00404bd0
mov byte [ebp - 4], 5
jmp 0x41ea9e
lea eax, [ebp - 0x23c]
push str.explorer.exe
push eax
call fcn.004a1037
pop ecx
pop ecx
test eax, eax
jne 0x41eb3d
lea eax, [ebp - 0x264]
push eax
push dword [ebp - 0x258]
mov dword [ebp - 0x264], ebx
call dword [sym.imp.KERNEL32.dll_ProcessIdToSessionId]
test eax, eax
je 0x41eb3d
mov eax, dword [ebp + 8]
cmp dword [ebp - 0x264], eax
je 0x41eb92
lea eax, [ebp - 0x260]
push eax
push edi
call sub.KERNEL32.dll_Process32NextW
test eax, eax
jne 0x41eafe
push str.CLocalSystemCommands::LaunchAppIntoDifferentSessionFromService___didnt_get_winlogonPid.
lea ecx, [ebp - 0x284]
call fcn.00404bd0
lea eax, [ebp - 0x284]
push eax
mov byte [ebp - 4], 7
call fcn.004017f5
pop ecx
push ebx
push esi
lea ecx, [ebp - 0x284]
call fcn.004058b3
mov edi, 0x3eb
push ebx
push esi
lea ecx, [ebp - 0x2c]
call fcn.004058b3
mov eax, edi
jmp 0x41eac7
mov edi, dword [ebp - 0x258]
push str.CLocalSystemCommands::LaunchAppIntoDifferentSessionFromService___winlogonPid
lea ecx, [ebp - 0x284]
mov dword [ebp - 0x290], edi
call fcn.00404bd0
lea eax, [ebp - 0x284]
push edi
push eax
mov byte [ebp - 4], 6
call fcn.004018c5
pop ecx
pop ecx
push ebx
push esi
lea ecx, [ebp - 0x284]
mov byte [ebp - 4], 3
call fcn.004058b3
push 0x44
pop edi
push edi
lea eax, [ebp - 0x310]
push ebx
push eax
mov dword [ebp - 0x294], 0x30
call fcn.0049f650
mov dword [ebp - 0x310], edi
xor eax, eax
lea edi, [ebp - 0x2ac]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
add esp, 0xc
push dword [ebp - 0x290]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
push ebx
mov edi, 0x2000000
push edi
mov dword [ebp - 0x308], str.winsta0default
call dword [sym.imp.KERNEL32.dll_OpenProcess]
lea ecx, [ebp - 0x288]
push ecx
push 0x201eb
push eax
mov dword [ebp - 0x290], eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
jne 0x41ec7b
call dword [sym.imp.KERNEL32.dll_GetLastError]
push str.CLocalSystemCommands::LaunchAppIntoDifferentSessionFromService___OpenProcessToken_failed
lea ecx, [ebp - 0x284]
mov dword [ebp - 0x264], eax
call fcn.00404bd0
mov byte [ebp - 4], 8
push dword [ebp - 0x264]
lea eax, [ebp - 0x284]
push eax
call fcn.004018c5
pop ecx
pop ecx
lea ecx, [ebp - 0x284]
jmp 0x41ee60
lea eax, [ebp - 0x268]
push eax
push esi
push esi
push ebx
push edi
push dword [ebp - 0x288]
call dword [sym.imp.ADVAPI32.dll_DuplicateTokenEx]
test eax, eax
jne 0x41ecb8
call dword [sym.imp.KERNEL32.dll_GetLastError]
push str.CLocalSystemCommands::LaunchAppIntoDifferentSessionFromService___DuplicateTokenEx_failed
lea ecx, [ebp - 0x284]
mov dword [ebp - 0x264], eax
call fcn.00404bd0
mov byte [ebp - 4], 9
jmp 0x41ec5c
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x264], eax
cmp eax, 0x514
jne 0x41eced
push str.CLocalSystemCommands::LaunchAppIntoDifferentSessionFromService___we_got_ERROR_NOT_ALL_ASSIGNED
lea ecx, [ebp - 0x284]
call fcn.00404bd0
lea eax, [ebp - 0x284]
push eax
mov byte [ebp - 4], 0xa
call fcn.004017f5
jmp 0x41ec6f
push esi
push dword [ebp - 0x268]
lea eax, [ebp - 0x28c]
push eax
mov dword [ebp - 0x28c], ebx
call sub.USERENV.dll_CreateEnvironmentBlock
test eax, eax
je 0x41ed16
mov dword [ebp - 0x294], 0x430
jmp 0x41ed1c
mov dword [ebp - 0x28c], ebx
push 0xffffffffffffffff
push ebx
push dword [ebp - 0x298]
lea ecx, [ebp - 0x2c]
call fcn.00405301
push 0x4d53a8
lea ecx, [ebp - 0x2c]
call fcn.004052dd
push 0xffffffffffffffff
push ebx
push dword [ebp - 0x29c]
lea ecx, [ebp - 0x2c]
call fcn.00405c92
mov eax, dword [ebp - 0x18]
xor ecx, ecx
push 2
add eax, 0xa
pop edx
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0049e091
cmp dword [ebp - 0x14], 8
pop ecx
mov ecx, dword [ebp - 0x28]
mov dword [ebp - 0x264], eax
jae 0x41ed78
lea ecx, [ebp - 0x28]
mov edx, dword [ebp - 0x264]
movzx eax, word [ecx]
inc ecx
mov word [edx], ax
inc ecx
inc edx
inc edx
cmp ax, bx
jne 0x41ed7e
push ebx
call dword [sym.imp.KERNEL32.dll_SetLastError]
lea eax, [ebp - 0x2ac]
push eax
lea eax, [ebp - 0x310]
push eax
push ebx
push dword [ebp - 0x28c]
push dword [ebp - 0x294]
push ebx
push ebx
push ebx
push dword [ebp - 0x264]
push ebx
push dword [ebp - 0x268]
call dword [sym.imp.ADVAPI32.dll_CreateProcessAsUserW]
mov edi, eax
cmp edi, ebx
je 0x41edde
cmp byte [ebp + 0xc], bl
je 0x41edde
push 0xffffffffffffffff
push dword [ebp - 0x2ac]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push dword [ebp - 0x264]
call fcn.0049eec0
pop ecx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push str.CLocalSystemCommands::LaunchAppIntoDifferentSessionFromService___bResult
lea ecx, [ebp - 0x284]
mov dword [ebp - 0x264], eax
call fcn.00404bd0
cmp edi, ebx
setne al
movzx eax, al
push eax
lea eax, [ebp - 0x284]
push eax
mov byte [ebp - 4], 0xb
call fcn.00401927
pop ecx
pop ecx
push ebx
push esi
lea ecx, [ebp - 0x284]
mov byte [ebp - 4], 3
call fcn.004058b3
push str.CLocalSystemCommands::LaunchAppIntoDifferentSessionFromService___error
lea ecx, [ebp - 0x2c8]
call fcn.00404bd0
mov byte [ebp - 4], 0xc
push dword [ebp - 0x264]
lea eax, [ebp - 0x2c8]
push eax
call fcn.004018c5
pop ecx
pop ecx
lea ecx, [ebp - 0x2c8]
push ebx
push esi
call fcn.004058b3
push dword [ebp - 0x290]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call edi
push dword [ebp - 0x268]
call edi
push dword [ebp - 0x288]
call edi
mov edi, dword [ebp - 0x264]
jmp 0x41eb81