Function at 0x453740
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x54f0f6
mov eax, dword fs:[0]
push eax
sub esp, 0x20
push esi
push edi
mov eax, dword [0x6fb4c0]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x10], 0x6e80cc
mov eax, dword [0x6fe8d4]
mov dword [ebp - 4], 0
cmp eax, 0xfffffffe
jle 0x45378b
call fcn.00453f80
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea ecx, [ebp - 0x14]
mov dword [ebp - 0x14], 0
push ecx
push 8
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
or esi, 0xffffffff
test eax, eax
je 0x453826
lea eax, [ebp - 0x18]
mov dword [ebp - 0x18], 0
push eax
push 0
push dword [ebp - 0x14]
call dword [sym.imp.USERENV.dll_GetUserProfileDirectoryW]
test eax, eax
jne 0x45381d
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x45381d
mov ecx, 2
mul ecx
cmovb eax, esi
push eax
call fcn.00524d72
add esp, 4
mov edi, eax
lea eax, [ebp - 0x18]
push eax
push edi
push dword [ebp - 0x14]
call dword [sym.imp.USERENV.dll_GetUserProfileDirectoryW]
test eax, eax
je 0x453814
push esi
lea eax, [ebp - 0x24]
push edi
push eax
call fcn.00420d90
mov edx, dword [ebp - 0x10]
add esp, 0xc
mov ecx, dword [eax]
mov dword [ebp - 0x10], ecx
lea ecx, [ebp - 0x24]
mov dword [eax], edx
call fcn.00401a70
push edi
call fcn.00524d7b
add esp, 4
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x10]
cmp dword [eax + 4], 0
je 0x453843
lea eax, [ebp - 0x10]
push eax
call fcn.00449e00
add esp, 4
test al, al
jne 0x453b47
lea eax, [ebp - 0x14]
push str.USERPROFILE
push eax
call fcn.004261b0
push eax
lea eax, [ebp - 0x18]
mov byte [ebp - 4], 1
push eax
call fcn.004531b0
mov edx, dword [ebp - 0x10]
add esp, 0x10
mov ecx, dword [eax]
mov dword [ebp - 0x10], ecx
mov dword [eax], edx
mov eax, dword [ebp - 0x18]
mov eax, dword [eax]
test eax, eax
je 0x45388b
cmp eax, 0xffffffff
je 0x45389a
mov eax, dword [ebp - 0x18]
mov ecx, esi
lock xadd dword [eax], ecx
dec ecx
setne al
test al, al
jne 0x45389a
push 4
push 2
push dword [ebp - 0x18]
call fcn.00403690
add esp, 0xc
mov eax, dword [ebp - 0x14]
mov byte [ebp - 4], 0
mov eax, dword [eax]
test eax, eax
je 0x4538bd
cmp eax, 0xffffffff
je 0x4538cc
mov eax, dword [ebp - 0x14]
mov ecx, esi
lock xadd dword [eax], ecx
dec ecx
setne al
test al, al
jne 0x4538cc
push 4
push 1
push dword [ebp - 0x14]
call fcn.00403690
add esp, 0xc
mov eax, dword [ebp - 0x10]
cmp dword [eax + 4], 0
je 0x4538e9
lea eax, [ebp - 0x10]
push eax
call fcn.00449e00
add esp, 4
test al, al
jne 0x453b47
lea eax, [ebp - 0x24]
push str.HOMEPATH
push eax
call fcn.004261b0
push eax
lea eax, [ebp - 0x20]
mov byte [ebp - 4], 2
push eax
call fcn.004531b0
mov edi, eax
lea eax, [ebp - 0x1c]
mov byte [ebp - 4], 3
push str.HOMEDRIVE
push eax
call fcn.004261b0
push eax
lea eax, [ebp - 0x18]
mov byte [ebp - 4], 4
push eax
call fcn.004531b0
add esp, 0x20
mov eax, dword [eax]
mov dword [ebp - 0x14], eax
mov byte [ebp - 4], 6
mov eax, dword [eax]
test eax, eax
je 0x453944
cmp eax, 0xffffffff
je 0x453944
mov eax, dword [ebp - 0x14]
lock inc dword [eax]
push edi
lea ecx, [ebp - 0x14]
mov dword [ebp - 0x28], 2
call fcn.004061e0
mov ecx, dword [ebp - 0x10]
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x14], ecx
mov eax, dword [ecx]
test eax, eax
je 0x453979
cmp eax, 0xffffffff
je 0x453988
mov eax, esi
lock xadd dword [ecx], eax
dec eax
setne al
test al, al
jne 0x453988
push 4
push 2
push dword [ebp - 0x14]
call fcn.00403690
add esp, 0xc
mov eax, dword [ebp - 0x18]
mov eax, dword [eax]
test eax, eax
je 0x4539a7
cmp eax, 0xffffffff
je 0x4539b6
mov eax, dword [ebp - 0x18]
mov ecx, esi
lock xadd dword [eax], ecx
dec ecx
setne al
test al, al
jne 0x4539b6
push 4
push 2
push dword [ebp - 0x18]
call fcn.00403690
add esp, 0xc
mov eax, dword [ebp - 0x1c]
mov eax, dword [eax]
test eax, eax
je 0x4539d5
cmp eax, 0xffffffff
je 0x4539e4
mov eax, dword [ebp - 0x1c]
mov ecx, esi
lock xadd dword [eax], ecx
dec ecx
setne al
test al, al
jne 0x4539e4
push 4
push 1
push dword [ebp - 0x1c]
call fcn.00403690
add esp, 0xc
mov eax, dword [ebp - 0x20]
mov eax, dword [eax]
test eax, eax
je 0x453a03
cmp eax, 0xffffffff
je 0x453a12
mov eax, dword [ebp - 0x20]
mov ecx, esi
lock xadd dword [eax], ecx
dec ecx
setne al
test al, al
jne 0x453a12
push 4
push 2
push dword [ebp - 0x20]
call fcn.00403690
add esp, 0xc
mov eax, dword [ebp - 0x24]
mov byte [ebp - 4], 0
mov eax, dword [eax]
test eax, eax
je 0x453a35
cmp eax, 0xffffffff
je 0x453a44
mov eax, dword [ebp - 0x24]
mov ecx, esi
lock xadd dword [eax], ecx
dec ecx
setne al
test al, al
jne 0x453a44
push 4
push 1
push dword [ebp - 0x24]
call fcn.00403690
add esp, 0xc
mov eax, dword [ebp - 0x10]
cmp dword [eax + 4], 0
je 0x453a61
lea eax, [ebp - 0x10]
push eax
call fcn.00449e00
add esp, 4
test al, al
jne 0x453b47
lea eax, [ebp - 0x20]
push str.HOME
push eax
call fcn.004261b0
push eax
lea eax, [ebp - 0x24]
mov byte [ebp - 4], 7
push eax
call fcn.004531b0
mov edx, dword [ebp - 0x10]
add esp, 0x10
mov ecx, dword [eax]
mov dword [ebp - 0x10], ecx
mov dword [eax], edx
mov eax, dword [ebp - 0x24]
mov eax, dword [eax]
test eax, eax
je 0x453aa9
cmp eax, 0xffffffff
je 0x453ab8
mov eax, dword [ebp - 0x24]
mov ecx, esi
lock xadd dword [eax], ecx
dec ecx
setne al
test al, al
jne 0x453ab8
push 4
push 2
push dword [ebp - 0x24]
call fcn.00403690
add esp, 0xc
mov eax, dword [ebp - 0x20]
mov byte [ebp - 4], 0
mov eax, dword [eax]
test eax, eax
je 0x453adb
cmp eax, 0xffffffff
je 0x453aea
mov eax, dword [ebp - 0x20]
mov ecx, esi
lock xadd dword [eax], ecx
dec ecx
setne al
test al, al
jne 0x453aea
push 4
push 1
push dword [ebp - 0x20]
call fcn.00403690
add esp, 0xc
mov eax, dword [ebp - 0x10]
cmp dword [eax + 4], 0
je 0x453b03
lea eax, [ebp - 0x10]
push eax
call fcn.00449e00
add esp, 4
test al, al
jne 0x453b47
lea eax, [ebp - 0x24]
push eax
call fcn.00455b60
mov edx, dword [ebp - 0x10]
add esp, 4
mov ecx, dword [eax]
mov dword [ebp - 0x10], ecx
mov dword [eax], edx
mov eax, dword [ebp - 0x24]
mov eax, dword [eax]
test eax, eax
je 0x453b38
cmp eax, 0xffffffff
je 0x453b47
mov eax, dword [ebp - 0x24]
mov ecx, esi
lock xadd dword [eax], ecx
dec ecx
setne al
test al, al
jne 0x453b47
push 4
push 2
push dword [ebp - 0x24]
call fcn.00403690
add esp, 0xc
mov edi, dword [ebp + 8]
lea eax, [ebp - 0x10]
push eax
push edi
call fcn.00424650
mov eax, dword [ebp - 0x10]
add esp, 8
mov eax, dword [eax]
test eax, eax
je 0x453b74
cmp eax, 0xffffffff
je 0x453b83
mov ecx, dword [ebp - 0x10]
lock xadd dword [ecx], esi
dec esi
setne cl
test cl, cl
jne 0x453b83
push 4
push 2
push dword [ebp - 0x10]
call fcn.00403690
add esp, 0xc
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret