Function at 0x48b5f0
Capabilities:
Get logon sessions

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x514645
mov eax, dword fs:[0]
push eax
sub esp, 0x120
mov eax, dword [0x58fa2c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 4], 0
mov ecx, dword [ebp + 8]
mov eax, dword [ebp + 0xc]
mov esi, dword [ebp + 0x14]
mov dword [ebp - 0x4c], 0
mov dword [ebp - 0x50], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x58], ecx
mov dword [ebp - 0x6c], ecx
mov dword [ebp - 0x34], eax
mov dword [ecx], 0
mov dword [ecx + 4], 0
mov dword [ecx + 8], 0
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x7c]
mov dword [ebp - 0x4c], 1
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x2c], 0
call fcn.00429d50
mov dword [ebp - 4], 1
xor edi, edi
mov dword [ebp - 0x68], 0
mov dword [ebp - 0x64], edi
mov byte [ebp - 4], 2
xor ebx, ebx
mov dword [ebp - 0x40], edi
mov dword [ebp - 0x3c], ebx
mov byte [ebp - 4], 3
xor ecx, ecx
mov dword [ebp - 0x48], ebx
mov dword [ebp - 0x44], ecx
mov byte [ebp - 4], 4
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x14], 0xf
mov dword [ebp - 0x18], ecx
mov byte [ebp - 0x28], cl
mov byte [ebp - 4], 5
lea eax, [ebp - 0xc4]
mov byte [ebp - 0x54], cl
mov dword [ebp - 0x12c], 0x56a190
mov dword [ebp - 0x11c], 0x56881c
mov dword [ebp - 0x5c], eax
mov dword [ebp - 0xc4], vtable.std::ios_base.0
mov byte [ebp - 4], 6
mov dword [ebp - 0xc4], vtable.std::basic_ios_char__struct_std::char_traits_char__.0
mov byte [ebp - 4], 7
lea eax, [ebp - 0x114]
push ecx
push eax
lea ecx, [ebp - 0x12c]
mov dword [ebp - 0x4c], 3
call fcn.0041a710
mov dword [ebp - 4], 8
mov eax, dword [ebp - 0x12c]
mov eax, dword [eax + 4]
mov dword [ebp + eax - 0x12c], 0x568828
mov eax, dword [ebp - 0x12c]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x68]
mov dword [ebp + ecx - 0x130], eax
lea eax, [ebp - 0x114]
mov ecx, eax
mov dword [ebp - 0x5c], eax
call fcn.0041b910
mov byte [ebp - 4], 9
cmp dword [esi + 0x14], 0x10
mov eax, dword [esi + 0x10]
mov dword [ebp - method.std::basic_stringbuf_char__struct_std::char_traits_char___class_std::allocator_char__.virtual_0], vtable.std::basic_stringbuf_char__struct_std::char_traits_char___class_std::allocator_char__.0
jb 0x48b776
mov esi, dword [esi]
push 0
push eax
push esi
lea ecx, [ebp - 0x114]
call fcn.0041b710
mov byte [ebp - 4], 0xb
lea eax, [ebp - 0x30]
mov esi, dword [ebp - 0x34]
push eax
lea eax, [ebp - 0x38]
push eax
mov byte [esi], 0
call sub.Secur32.dll_LsaEnumerateLogonSessions
test eax, eax
jne 0x48ba25
xor ebx, ebx
cmp dword [ebp - 0x38], ebx
jbe 0x48b9b4
nop
lea eax, [ebp - 0x2c]
push eax
mov eax, dword [ebp - 0x30]
lea eax, [eax + ebx*8]
push eax
call sub.Secur32.dll_LsaGetLogonSessionData
test eax, eax
jne 0x48b966
mov edx, dword [ebp - 0x2c]
mov eax, dword [edx + 0x24]
cmp eax, 2
je 0x48b7e1
cmp eax, 0xa
je 0x48b7e1
cmp eax, 0xb
jne 0x48b996
movzx eax, word [edx + 0xc]
inc ax
movzx edi, ax
movzx eax, word [edx + 0x14]
inc ax
push edi
movzx esi, ax
call fcn.004a4577
add esp, 4
lea ecx, [ebp - 0x68]
push eax
call fcn.0048acc0
push esi
call fcn.004a4577
add esp, 4
lea ecx, [ebp - 0x40]
push eax
call fcn.0048acc0
push edi
mov edi, dword [ebp - 0x68]
push 0
push edi
call fcn.004b8570
push esi
mov esi, dword [ebp - 0x40]
push 0
push esi
call fcn.004b8570
mov ecx, dword [ebp - 0x2c]
movzx eax, word [ecx + 0xc]
push eax
push dword [ecx + 0x10]
push edi
call fcn.00489c10
mov ecx, dword [ebp - 0x2c]
movzx eax, word [ecx + 0x14]
push eax
push dword [ecx + 0x18]
push esi
call fcn.00489c10
mov edi, dword [ebp - 0x50]
push edi
push esi
call fcn.004c8d34
add esp, 0x38
test eax, eax
jne 0x48b8a3
add edi, 0x10
mov eax, edi
lea edx, [eax + 1]
nop word [eax + eax]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x48b870
sub eax, edx
lea esi, [eax + 1]
push esi
call fcn.004a4577
add esp, 4
lea ecx, [ebp - 0x40]
push eax
call fcn.0048acc0
push edi
push esi
mov esi, dword [ebp - 0x40]
push esi
call fcn.004c562f
mov edi, dword [ebp - 0x50]
add esp, 0xc
mov byte [ebp - 0x54], 1
push 0x68
call fcn.00472260
add esp, 4
mov dword [ebp - 0x5c], eax
mov byte [ebp - 4], 0xc
test eax, eax
je 0x48b8c9
push dword [ebp - 0x54]
mov ecx, eax
push edi
push esi
push dword [ebp - 0x68]
call fcn.004914e0
jmp 0x48b8cb
xor eax, eax
mov byte [ebp - 4], 0xb
lea ecx, [ebp - 0x48]
push eax
call fcn.0048ad60
mov ecx, dword [ebp - 0x48]
lea eax, [ebp - 0x28]
push 1
push eax
call fcn.004919c0
sub esp, 0x18
lea eax, [ebp - 0x28]
mov ecx, esp
mov dword [ebp - 0x60], esp
push 0xffffffffffffffff
push 0
mov dword [ecx + 0x14], 0xf
mov dword [ecx + 0x10], 0
push eax
mov byte [ecx], 0
call fcn.004060f0
mov byte [ebp - 4], 0xd
mov byte [ebp - 4], 0xb
lea ecx, [ebp - 0x7c]
call fcn.0042a060
test al, al
jne 0x48b961
sub esp, 0x18
mov ecx, esp
mov dword [ebp - 0x60], esp
push 0xffffffffffffffff
mov dword [ecx + 0x14], 0xf
mov dword [ecx + 0x10], 0
mov byte [ecx], al
lea eax, [ebp - 0x28]
push 0
push eax
call fcn.004060f0
mov byte [ebp - 4], 0xe
mov byte [ebp - 4], 0xb
lea ecx, [ebp - 0x7c]
call fcn.00429f70
mov ecx, dword [ebp - 0x58]
lea eax, [ebp - 0x48]
push eax
call fcn.0048d750
mov esi, dword [ebp - 0x34]
jmp 0x48b993
push 0x525360
push eax
lea eax, [ebp - 0x11c]
mov byte [esi], 1
push str.____Unable_to_get_session_information_for_user__
push eax
call fcn.00426c40
add esp, 8
mov ecx, eax
call fcn.0048ae00
push eax
call fcn.00426c40
add esp, 8
mov edx, dword [ebp - 0x2c]
test edx, edx
je 0x48b9a7
push edx
call sub.Secur32.dll_LsaFreeReturnBuffer
mov dword [ebp - 0x2c], 0
inc ebx
cmp ebx, dword [ebp - 0x38]
jb 0x48b7b0
mov edi, dword [ebp - 0x64]
mov ebx, dword [ebp - 0x3c]
mov eax, dword [ebp - 0x30]
test eax, eax
je 0x48b9cb
push eax
call sub.Secur32.dll_LsaFreeReturnBuffer
mov dword [ebp - 0x30], 0
mov byte [ebp - 4], 5
lea ecx, [ebp - 0xc4]
call fcn.00418b30
lea eax, [ebp - 0xc4]
mov dword [ebp - 0xc4], vtable.std::basic_ios_char__struct_std::char_traits_char__.0
mov dword [ebp - 0x60], eax
mov byte [ebp - 4], 5
push eax
mov dword [ebp - 0xc4], vtable.std::ios_base.0
call fcn.004a5c40
add esp, 4
mov byte [ebp - 4], 4
mov eax, dword [ebp - 0x14]
cmp eax, 0x10
jb 0x48ba84
mov ecx, dword [ebp - 0x28]
inc eax
cmp eax, 0x1000
jb 0x48ba7b
test cl, 0x1f
je 0x48ba57
call fcn.004c2059
push 0x525360
push eax
lea eax, [ebp - 0x11c]
mov byte [esi], 1
push str.____Unable_to_enumerate_logon_sessions__
push eax
call fcn.00426c40
add esp, 8
mov ecx, eax
call fcn.0048ae00
push eax
call fcn.00426c40
add esp, 8
jmp 0x48b9b7
mov eax, dword [ecx - 4]
cmp eax, ecx
jb 0x48ba63
call fcn.004c2059
sub ecx, eax
cmp ecx, 4
jae 0x48ba6f
call fcn.004c2059
cmp ecx, 0x23
jbe 0x48ba79
call fcn.004c2059
mov ecx, eax
push ecx
call fcn.004722b0
add esp, 4
mov dword [ebp - 0x14], 0xf
mov dword [ebp - 0x18], 0
mov byte [ebp - 0x28], 0
mov byte [ebp - 4], 3
or esi, 0xffffffff
mov ecx, dword [ebp - 0x44]
test ecx, ecx
je 0x48bac2
mov eax, esi
lock xadd dword [ecx + 4], eax
jne 0x48bac2
mov eax, dword [ecx]
call dword [eax]
mov ecx, dword [ebp - 0x44]
mov eax, esi
lock xadd dword [ecx + 8], eax
jne 0x48bac2
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 2
test ebx, ebx
je 0x48bae9
mov eax, esi
lock xadd dword [ebx + 4], eax
jne 0x48bae9
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax]
mov eax, esi
lock xadd dword [ebx + 8], eax
jne 0x48bae9
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax + 4]
mov byte [ebp - 4], 1
test edi, edi
je 0x48bb0f
mov eax, esi
lock xadd dword [edi + 4], eax
jne 0x48bb0f
mov eax, dword [edi]
mov ecx, edi
call dword [eax]
lock xadd dword [edi + 8], esi
dec esi
jne 0x48bb0f
mov edx, dword [edi]
mov ecx, edi
call dword [edx + 4]
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x7c]
call fcn.00429ea0
mov eax, dword [ebp - 0x58]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004a4566
mov esp, ebp
pop ebp
ret