Function at 0x1801b75d
Capabilities:
Get session information
Get session user name

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x44
mov eax, dword [0x181d700c]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov eax, ecx
xor ebx, ebx
push esi
push edi
mov dword [ebp - 0x30], eax
mov byte [eax], bl
mov dword [ebp - 0xc], ebx
call fcn.18006f9c
push eax
lea ecx, [ebp - 0xc]
call fcn.180076af
mov dword [ebp - 8], ebx
call fcn.18006f9c
push eax
lea ecx, [ebp - 8]
call fcn.180076af
lea edx, [ebp - 0xc]
lea ecx, [ebp - 8]
call fcn.18019d15
mov esi, dword [ebp - 0xc]
mov ebx, eax
mov edi, dword [ebp - 8]
test ebx, ebx
jns 0x1801b7fe
movzx ecx, byte [0x181dd05a]
neg ecx
sbb ecx, ecx
and ecx, 0x181dcf50
je 0x1801b950
push 0xfffffffffffffffe
pop eax
lfence
push eax
push 7
mov dword [ebp - 0x44], ecx
mov dword [ebp - 0x40], 7
mov dword [ebp - 0x3c], eax
call fcn.18008b5d
push ebx
mov dword [ebp - 0x38], eax
lea eax, [ebp - 0x44]
push str._GetUserAccountAndDomainNames_failed__0x_08x_
push eax
call fcn.18007230
add esp, 0xc
jmp 0x1801b950
lea eax, [ebp - 0x10]
xor ecx, ecx
push eax
lea eax, [ebp - 0x1c]
mov dword [ebp - 0x1c], ecx
push eax
push 1
push ecx
push ecx
mov dword [ebp - 0x10], ecx
call dword [sym.imp.WTSAPI32.dll_WTSEnumerateSessionsW]
test eax, eax
jne 0x1801b828
call fcn.1801bab5
mov ebx, eax
jmp 0x1801b950
mov ecx, dword [ebp - 0x1c]
xor eax, eax
mov dword [ebp - 0x34], ecx
mov dword [ebp - 0x28], eax
cmp dword [ebp - 0x10], eax
jbe 0x1801b947
mov dword [ebp - 8], eax
mov ecx, dword [eax + ecx]
call fcn.18019116
test al, al
je 0x1801b910
mov ecx, dword [ebp - 8]
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x24]
xor edx, edx
push eax
mov eax, dword [ebp - 0x1c]
push 7
mov dword [ebp - 0x24], edx
mov dword [ebp - 0x14], edx
push dword [ecx + eax]
push edx
call dword [sym.imp.WTSAPI32.dll_WTSQuerySessionInformationW]
test eax, eax
jne 0x1801b881
call fcn.1801bab5
mov ebx, eax
jmp 0x1801b910
mov eax, dword [ebp - 0x24]
xor edx, edx
mov ecx, dword [ebp - 8]
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x20]
mov dword [ebp - 0x20], edx
push eax
mov eax, dword [ebp - 0x1c]
push 5
mov dword [ebp - 0x18], edx
push dword [ecx + eax]
push edx
call dword [sym.imp.WTSAPI32.dll_WTSQuerySessionInformationW]
test eax, eax
jne 0x1801b8b6
call fcn.1801bab5
mov ebx, eax
jmp 0x1801b907
mov ecx, dword [ebp - 0x24]
mov eax, dword [ebp - 0x20]
mov dword [ebp - 0x2c], eax
test ecx, ecx
je 0x1801b8fb
xor edx, edx
cmp word [ecx], dx
je 0x1801b8fb
test eax, eax
je 0x1801b8fb
cmp word [eax], dx
je 0x1801b8fb
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_lstrcmpiW]
test eax, eax
jne 0x1801b8f6
cmp dword [ebp - 0x20], eax
je 0x1801b971
push dword [ebp - 0x20]
push edi
call dword [sym.imp.KERNEL32.dll_lstrcmpiW]
test eax, eax
je 0x1801b92d
push dword [ebp - 0x2c]
jmp 0x1801b901
mov ebx, 0x80004005
push eax
call dword [sym.imp.WTSAPI32.dll_WTSFreeMemory]
push dword [ebp - 0xc]
call dword [sym.imp.WTSAPI32.dll_WTSFreeMemory]
mov ecx, dword [ebp - 0x28]
mov eax, dword [ebp - 8]
inc ecx
add eax, 0xc
mov dword [ebp - 0x28], ecx
mov dword [ebp - 8], eax
cmp ecx, dword [ebp - 0x10]
jae 0x1801b947
mov ecx, dword [ebp - 0x1c]
jmp 0x1801b83f
mov eax, dword [ebp - 0x30]
push dword [ebp - 0x2c]
mov byte [eax], 1
call dword [sym.imp.WTSAPI32.dll_WTSFreeMemory]
push dword [ebp - 0xc]
call dword [sym.imp.WTSAPI32.dll_WTSFreeMemory]
xor ebx, ebx
push dword [ebp - 0x34]
call dword [sym.imp.WTSAPI32.dll_WTSFreeMemory]
lea ecx, [edi - 0x10]
call fcn.18006f72
lea ecx, [esi - 0x10]
call fcn.18006f72
mov ecx, dword [ebp - 4]
mov eax, ebx
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.18122538
leave
ret
push 0x80004005
call fcn.18006be5
int3