Function at 0x424940
Capabilities:
Get session information
Get session user name
Print debug messages

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4ba58e
mov eax, dword fs:[0]
push eax
sub esp, 0x20
mov eax, dword [0x4ff684]
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 edi, ecx
mov dword [ebp - 0x20], edi
mov dword [ebp - 0x2c], edi
xor eax, eax
mov dword [ebp - 0x24], 0
push 0xe
mov dword [edi], 0
mov dword [edi + 0x10], 0
mov dword [edi + 0x14], 7
push 0x4ebf28
mov word [edi], ax
push edi
mov dword [edi + 0x10], 7
call fcn.0048af40
xor eax, eax
add esp, 0xc
mov word [edi + 0xe], ax
mov dword [ebp - 4], eax
mov dword [ebp - 0x24], 1
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x14], eax
call dword [sym.imp.KERNEL32.dll_WTSGetActiveConsoleSessionId]
cmp eax, 0xffffffff
jne 0x4249d5
push str.Error_retrieving_session_id_for_generating_log_name.
jmp 0x424b5c
lea ecx, [ebp - 0x14]
push ecx
lea ecx, [ebp - 0x18]
push ecx
push 5
push eax
push 0
call dword [sym.imp.WTSAPI32.dll_WTSQuerySessionInformationW]
test eax, eax
je 0x424b57
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x28], eax
test eax, eax
je 0x424b57
mov esi, dword [ebp - 0x14]
cmp esi, 2
jbe 0x424b41
mov ecx, dword [edi + 0x14]
shr esi, 1
dec esi
mov dword [ebp - 0x20], ecx
cmp esi, ecx
ja 0x424a44
mov ebx, edi
cmp ecx, 8
jb 0x424a20
mov ebx, dword [edi]
mov dword [edi + 0x10], esi
add esi, esi
push esi
push eax
push ebx
call fcn.0048af40
add esp, 0xc
xor eax, eax
mov word [esi + ebx], ax
push dword [ebp - 0x18]
call dword [sym.imp.WTSAPI32.dll_WTSFreeMemory]
jmp 0x424b62
cmp esi, 0x7ffffffe
ja 0x424b80
mov ebx, esi
or ebx, 7
cmp ebx, 0x7ffffffe
jbe 0x424a64
mov ebx, SysReAllocString
jmp 0x424a82
mov edx, ecx
mov eax, SysReAllocString
shr edx, 1
sub eax, edx
cmp ecx, eax
jbe 0x424a7a
mov ebx, SysReAllocString
jmp 0x424a82
lea eax, [edx + ecx]
cmp ebx, eax
cmovb ebx, eax
xor ecx, ecx
mov dword [ebp - 0x1c], ebx
add ebx, 1
setb cl
neg ecx
or ecx, ebx
cmp ecx, 0x7fffffff
ja 0x424b8a
add ecx, ecx
cmp ecx, 0x1000
jb 0x424ace
lea eax, [ecx + 0x23]
cmp eax, ecx
jbe 0x424b8a
push eax
call fcn.004892b3
add esp, 4
test eax, eax
je 0x424b85
lea ebx, [eax + 0x23]
and ebx, 0xffffffe0
mov dword [ebx - 4], eax
jmp 0x424ae1
test ecx, ecx
je 0x424adf
push ecx
call fcn.004892b3
add esp, 4
mov ebx, eax
jmp 0x424ae1
xor ebx, ebx
mov eax, dword [ebp - 0x1c]
mov dword [edi + 0x10], esi
add esi, esi
push esi
push dword [ebp - 0x28]
mov dword [edi + 0x14], eax
push ebx
call fcn.0048af40
mov ecx, dword [ebp - 0x20]
xor eax, eax
add esp, 0xc
mov word [esi + ebx], ax
cmp ecx, 8
jb 0x424b34
mov eax, dword [edi]
lea ecx, [ecx*2 + 2]
cmp ecx, 0x1000
jb 0x424b2a
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x424b85
mov eax, edx
push ecx
push eax
call fcn.00488f15
add esp, 8
push dword [ebp - 0x18]
mov dword [edi], ebx
call dword [sym.imp.WTSAPI32.dll_WTSFreeMemory]
jmp 0x424b62
push str.WTSQuerySessionInformation_failed_to_retrieve_the_size_of_the_current_user_name_for_the_log_name.
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
push dword [ebp - 0x18]
call dword [sym.imp.WTSAPI32.dll_WTSFreeMemory]
jmp 0x424b62
push str.WTSQuerySessionInformation_failed_to_retrieve_current_user_name_for_the_log_name.
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
mov eax, edi
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.00488f07
mov esp, ebp
pop ebp
ret
call fcn.00414470
call fcn.0048e1b0
call fcn.00414539
int3