Function at 0x40664b
Capabilities:
Get session user name

Disassembly:
push 0x51c
mov eax, 0x507368
call fcn.004c8468
mov ebx, ecx
xor eax, eax
push 0x105
push eax
lea eax, [ebp - 0x188]
push eax
call fcn.004df090
add esp, 0xc
mov dword [ebp - 0x3a0], 0x104
lea eax, [ebp - 0x3a0]
push eax
lea eax, [ebp - 0x188]
push eax
call dword [sym.imp.ADVAPI32.dll_GetUserNameA]
xor eax, eax
mov dword [ebp - 0x3a4], 0xf
lea ecx, [ebp - 0x188]
mov dword [ebp - 0x3a8], eax
mov byte [ebp - 0x3b8], al
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4066b2
sub ecx, edx
lea eax, [ebp - 0x188]
push ecx
push eax
lea ecx, [ebp - 0x3b8]
call fcn.00402313
xor eax, eax
mov dword [ebp - 4], eax
mov dword [ebp - 0x39c], eax
push 0x53
pop eax
push 0x4f
mov byte [ebp - 4], 1
mov word [ebp - 0x68], ax
pop eax
push 0x46
mov word [ebp - 0x66], ax
pop eax
push 0x54
mov word [ebp - 0x64], ax
pop eax
push 0x57
mov word [ebp - 0x62], ax
pop eax
push 0x41
mov word [ebp - 0x60], ax
pop eax
push 0x52
mov word [ebp - 0x5e], ax
pop eax
push 0x45
mov word [ebp - 0x5c], ax
pop eax
push 0x5c
pop ecx
push 0x4d
mov word [ebp - 0x5a], ax
pop eax
push 0x69
mov word [ebp - 0x56], ax
pop eax
push 0x63
mov word [ebp - 0x54], ax
pop eax
push 0x72
pop esi
push 0x6f
pop edi
push 0x73
mov word [ebp - 0x52], ax
pop eax
push 0x66
mov word [ebp - 0x4c], ax
pop eax
push 0x74
pop edx
push 0x43
mov word [ebp - 0x48], ax
pop eax
push 0x79
mov word [ebp - 0x50], si
mov word [ebp - 0x40], si
pop esi
push 0x70
mov word [ebp - 0x58], cx
mov word [ebp - 0x44], cx
pop ecx
push 0x67
mov word [ebp - 0x42], ax
pop eax
mov word [ebp - 0x4e], di
mov word [ebp - 0x4a], di
mov word [ebp - 0x46], dx
mov word [ebp - 0x3e], si
mov word [ebp - 0x3c], cx
mov word [ebp - 0x3a], dx
mov word [ebp - 0x38], di
mov word [ebp - 0x36], ax
push 0x72
pop eax
push 0x61
pop edi
mov word [ebp - 0x34], ax
push 0x68
pop eax
mov word [ebp - 0x2e], ax
xor eax, eax
mov word [ebp - 0x32], di
mov word [ebp - 0x30], cx
mov word [ebp - 0x2c], si
mov word [ebp - 0x2a], ax
call fcn.0040a009
lea ecx, [ebp - 0x4f4]
push ecx
cmp dword [eax], 0
je 0x4067e7
xor eax, eax
push 0x20119
push eax
mov dword [ebp - 0x4f4], eax
lea eax, [ebp - 0x68]
push eax
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x406815
mov eax, dword [ebp - 0x4f4]
mov dword [ebp - 0x39c], eax
jmp 0x406815
xor eax, eax
push 0x20019
push eax
mov dword [ebp - 0x4f4], eax
lea eax, [ebp - 0x68]
push eax
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
xor ecx, ecx
test eax, eax
cmove ecx, dword [ebp - 0x4f4]
mov dword [ebp - 0x39c], ecx
push 0x20a
lea eax, [ebp - 0x398]
push 0
push eax
call fcn.004df090
add esp, 0xc
mov dword [ebp - 0x4f4], 0x104
mov word [ebp - 0x26], di
push 0x4d
pop eax
push 0x63
mov word [ebp - 0x28], ax
pop eax
push 0x68
mov word [ebp - 0x24], ax
pop eax
push 0x69
pop ecx
push 0x6e
mov word [ebp - 0x22], ax
pop eax
push 0x65
mov word [ebp - 0x1e], ax
pop eax
push 0x47
mov word [ebp - 0x1c], ax
pop eax
push 0x75
mov word [ebp - 0x1a], ax
pop eax
mov word [ebp - 0x18], ax
push 0x64
pop eax
mov word [ebp - 0x14], ax
xor eax, eax
mov word [ebp - 0x12], ax
lea eax, [ebp - 0x4f4]
push eax
lea eax, [ebp - 0x398]
mov word [ebp - 0x20], cx
push eax
lea eax, [ebp - 0x28]
mov word [ebp - 0x16], cx
push eax
lea ecx, [ebp - 0x39c]
call fcn.00406568
and dword [ebp - 0x500], 0
lea ecx, [ebp - 0x510]
xor eax, eax
mov dword [ebp - 0x4fc], 7
mov word [ebp - 0x510], ax
lea eax, [ebp - 0x398]
push eax
call fcn.004020d1
push ecx
lea edx, [ebp - 0x510]
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x528]
call fcn.00401c94
pop ecx
push eax
lea eax, [ebp - 0x80]
mov byte [ebp - 4], 3
push 0x52b7a0
push eax
call fcn.00408ac9
add esp, 0xc
mov byte [ebp - 4], 4
mov ecx, eax
cmp dword [eax + 0x14], 0x10
jb 0x406906
mov ecx, dword [eax]
push dword [eax + 0x10]
push ecx
lea ecx, [ebp - 0x3b8]
call fcn.0040235c
lea ecx, [ebp - 0x80]
call fcn.0040216d
lea ecx, [ebp - 0x528]
call fcn.0040216d
lea ecx, [ebp - 0x510]
mov byte [ebp - 4], 1
call fcn.004020a3
xor eax, eax
lea edi, [ebp - 0x78]
stosd dword es:[edi], eax
lea ecx, [ebp - 0x4f0]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
call fcn.0040313b
cmp dword [ebp - 0x3a4], 0x10
lea edx, [ebp - 0x3b8]
push dword [ebp - 0x3a8]
cmovae edx, dword [ebp - 0x3b8]
call fcn.00403162
pop ecx
lea edx, [ebp - 0x78]
lea ecx, [ebp - 0x4f0]
call fcn.00403233
push 0x98
lea eax, [ebp - 0x450]
push 0
push eax
call fcn.004df090
add esp, 0xc
lea ecx, [ebp - 0x450]
push 1
push 2
call fcn.00406bb8
xor eax, eax
mov byte [ebp - 4], 5
mov esi, eax
mov ecx, dword [ebp - 0x450]
push eax
lea eax, [ebp - 0x508]
push 2
mov edx, dword [ecx + 4]
push eax
mov ecx, dword [ebp + edx - 0x43c]
and ecx, 0xfffff9ff
or ecx, 0x800
mov dword [ebp + edx - 0x43c], ecx
mov ecx, dword [ebp - 0x450]
mov ecx, dword [ecx + 4]
mov byte [ebp + ecx - 0x410], 0x30
call fcn.004c52d1
mov ecx, dword [ebp - 0x450]
lea edx, [ebp - 0x450]
add esp, 0xc
mov ecx, dword [ecx + 4]
push dword [eax + 0xc]
add ecx, edx
push dword [eax + 8]
push ecx
call dword [eax]
movzx eax, byte [ebp + esi - 0x78]
lea ecx, [ebp - 0x450]
add esp, 0xc
push eax
call fcn.00407062
inc esi
push 0
pop eax
cmp esi, 0x10
jl 0x4069a6
lea eax, [ebp - 0x510]
push eax
lea ecx, [ebp - 0x44c]
call fcn.00407d24
lea eax, [ebp - 0x510]
mov ecx, ebx
push eax
call fcn.00401fbf
lea ecx, [ebp - 0x510]
call fcn.0040216d
lea ecx, [ebp - 0x450]
call fcn.00406a7f
cmp dword [ebp - 0x39c], 0
je 0x406a6e
push dword [ebp - 0x39c]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea ecx, [ebp - 0x3b8]
call fcn.0040216d
call fcn.004c8412
ret