Function at 0x41e7c0
Capabilities:
Get logon sessions
Get session information

Disassembly:
push 0xffffffffffffffff
push 0x4880a8
mov eax, dword fs:[0]
push eax
sub esp, 0x88
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4a2120]
xor eax, esp
push eax
lea eax, [esp + 0x9c]
mov dword fs:[0], eax
mov esi, ecx
xor ebx, ebx
lea edi, [esi + 0x60]
mov dword [esp + 0x20], ebx
cmp byte [edi + 0x48], bl
je 0x41e833
lea eax, [edi + 4]
push eax
call dword [sym.imp.ADVAPI32.dll_IsValidSid]
test eax, eax
setne al
cmp al, bl
je 0x41e833
mov esi, dword [esp + 0xac]
push esi
mov ecx, edi
call fcn.004209d0
mov dword [esp + 0xa4], ebx
mov dword [esp + 0x20], 1
jmp 0x41eab6
mov dword [esp + 0x18], ebx
mov ebp, 1
mov dword [esp + 0xa4], ebp
lea ecx, [esp + 0x34]
push ecx
lea edx, [esp + 0x1c]
push edx
push 0x18
mov dword [esp + 0x40], ebx
call dword [sym.imp.KERNEL32.dll_WTSGetActiveConsoleSessionId]
push eax
push ebx
call sub.WTSAPI32.dll_WTSQuerySessionInformationW
test eax, eax
jne 0x41e8b0
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, ebx
jle 0x41e878
and eax, 0xffff
or eax, 0x80070000
push eax
push 0x35
call fcn.00423310
mov edi, dword [esp + 0xb4]
add esp, 8
push edi
call fcn.0041e6b0
mov dword [esp + 0x20], ebp
mov byte [esp + 0xa4], bl
mov eax, dword [esp + 0x18]
cmp eax, ebx
je 0x41e8a9
push eax
call sub.WTSAPI32.dll_WTSFreeMemory
mov eax, edi
jmp 0x41eab8
mov dword [esp + 0x28], ebx
mov dword [esp + 0x24], ebx
mov byte [esp + 0xa4], 2
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0x2c]
push ecx
call sub.Secur32.dll_LsaEnumerateLogonSessions
cmp eax, ebx
je 0x41e91e
push eax
call sub.ADVAPI32.dll_LsaNtStatusToWinError
cmp eax, ebx
jle 0x41e8e7
and eax, 0xffff
or eax, 0x80070000
push eax
push 0x3e
call fcn.00423310
mov edi, dword [esp + 0xb4]
add esp, 8
push edi
call fcn.0041e6b0
mov dword [esp + 0x20], ebp
mov byte [esp + 0xa4], 1
mov eax, dword [esp + 0x24]
cmp eax, ebx
je 0x41e894
push eax
call sub.Secur32.dll_LsaFreeReturnBuffer
jmp 0x41e894
mov edx, dword [esp + 0x18]
add edx, 0x82
push edx
lea ecx, [esp + 0x34]
call fcn.00420030
mov byte [esp + 0xa4], 3
mov eax, dword [esp + 0x18]
add eax, 0x60
push eax
lea ecx, [esp + 0x30]
call fcn.00420030
mov byte [esp + 0xa4], 4
xor ebp, ebp
cmp dword [esp + 0x28], ebx
jbe 0x41ea37
nop
cmp byte [edi + 0x48], bl
je 0x41e97c
lea ecx, [edi + 4]
push ecx
call dword [sym.imp.ADVAPI32.dll_IsValidSid]
test eax, eax
setne al
cmp al, bl
jne 0x41ea37
mov dword [esp + 0x1c], ebx
mov byte [esp + 0xa4], 5
mov eax, dword [esp + 0x24]
lea edx, [esp + 0x1c]
push edx
lea ecx, [eax + ebp*8]
push ecx
call sub.Secur32.dll_LsaGetLogonSessionData
test eax, eax
jne 0x41ea16
mov eax, dword [esp + 0x1c]
cmp dword [eax + 0x24], 2
jne 0x41ea16
mov edx, dword [eax + 0x28]
mov ecx, dword [esp + 0x18]
cmp edx, dword [ecx + 4]
jne 0x41ea16
mov ecx, dword [eax + 0x10]
lea edx, [esp + 0x30]
push edx
call fcn.0041f430
add esp, 4
test al, al
je 0x41ea16
mov ecx, dword [esp + 0x1c]
mov ecx, dword [ecx + 0x18]
lea eax, [esp + 0x2c]
push eax
call fcn.0041f430
add esp, 4
test al, al
je 0x41ea16
mov edx, dword [esp + 0x1c]
mov eax, dword [edx + 0x2c]
push eax
lea ecx, [esp + 0x3c]
push ecx
call fcn.0041fcd0
mov byte [esp + 0xa4], 6
mov ebx, eax
mov esi, edi
call fcn.0041fdf0
mov byte [esp + 0xa4], 5
lea ecx, [esp + 0x38]
call fcn.00420c30
xor ebx, ebx
mov byte [esp + 0xa4], 4
mov eax, dword [esp + 0x1c]
cmp eax, ebx
je 0x41ea2c
push eax
call sub.Secur32.dll_LsaFreeReturnBuffer
inc ebp
cmp ebp, dword [esp + 0x28]
jb 0x41e960
push edi
call fcn.00420310
push eax
push str.Active_user_SID___S
push 0x51
push str.Environment::GetActiveUserSid
call fcn.00423290
mov esi, dword [esp + 0xbc]
add esp, 0x10
push esi
mov ecx, edi
call fcn.004209d0
mov dword [esp + 0x20], 1
mov byte [esp + 0xa4], 3
lea ecx, [esp + 0x2c]
call fcn.00421e90
mov byte [esp + 0xa4], 2
lea ecx, [esp + 0x30]
call fcn.00421e90
mov byte [esp + 0xa4], 1
mov eax, dword [esp + 0x24]
cmp eax, ebx
je 0x41eaa1
push eax
call sub.Secur32.dll_LsaFreeReturnBuffer
mov byte [esp + 0xa4], bl
mov eax, dword [esp + 0x18]
cmp eax, ebx
je 0x41eab6
push eax
call sub.WTSAPI32.dll_WTSFreeMemory
mov eax, esi
mov ecx, dword [esp + 0x9c]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x94
ret 4