Function at 0x45f1d0
Capabilities:
Get common file path

Disassembly:
push 0xffffffffffffffff
push 0x4b8482
mov eax, dword fs:[0]
push eax
sub esp, 0x460
mov eax, dword [0x4e1370]
xor eax, esp
mov dword [esp + 0x458], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4e1370]
xor eax, esp
push eax
lea eax, [esp + 0x474]
mov dword fs:[0], eax
mov ebp, dword [esp + 0x484]
mov esi, ecx
mov edi, edx
test esi, esi
je 0x45f6b4
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
test eax, eax
je 0x45f6b4
lea eax, [esp + 0x24]
push eax
mov ecx, esi
call fcn.00405a20
lea ebx, [esp + 0x24]
mov dword [esp + 0x47c], 0
call fcn.00461db0
call fcn.00461d30
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
call fcn.0040bbd0
add eax, 0x10
mov dword [esp + 0x20], eax
lea ecx, [esp + 0x20]
push edi
mov byte [esp + 0x480], 1
mov eax, dword [esp + 0x28]
push ecx
push ecx
add eax, 0xfffffff0
mov dword [esp + 0x24], esp
mov esi, esp
call fcn.0040bbd0
add eax, 0x10
mov dword [esi], eax
call fcn.0045ff00
mov esi, dword [esp + 0x2c]
mov eax, dword [esi - 0xc]
add esp, 0xc
test eax, eax
je 0x45f3b7
push esi
call dword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
test eax, eax
je 0x45f2bd
lea eax, [esp + 0x20]
mov edi, ebp
call fcn.0040d2b0
jmp 0x45f3b7
push esi
call dword [sym.imp.SHLWAPI.dll_PathFindFileNameW]
lea edx, [esp + 0x18]
push edx
mov ecx, eax
call fcn.00405a20
mov byte [esp + 0x47c], 2
xor ebx, ebx
mov dword [esp + 0x2c], str.MsiExec.exe
mov dword [esp + 0x30], str.RunDll32.exe
mov dword [esp + 0x34], str.spuninst.exe
xor esi, esi
mov edi, dword [esp + esi*4 + 0x2c]
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
test eax, eax
je 0x45f316
mov eax, dword [esp + 0x18]
push edi
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpW]
test eax, eax
jne 0x45f316
lea ebx, [eax + 1]
inc esi
cmp esi, 3
jl 0x45f2f4
test ebx, ebx
jne 0x45f38f
lea eax, [esp + 0x20]
mov edi, ebp
call fcn.0040d2b0
mov eax, dword [ebp]
sub eax, 0x10
mov ecx, 1
sub ecx, dword [eax + 0xc]
mov eax, dword [eax + 8]
sub eax, 0x400
or eax, ecx
jge 0x45f351
mov ecx, 0x400
mov eax, ebp
call fcn.00405860
mov eax, dword [ebp]
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
mov eax, dword [ebp]
mov ecx, dword [eax - 8]
test eax, eax
je 0x45f377
push ecx
push eax
call fcn.004913b1
add esp, 8
test eax, eax
jl 0x45f4f3
mov ecx, dword [ebp]
cmp eax, dword [ecx - 8]
jg 0x45f4f3
mov dword [ecx - 0xc], eax
mov ecx, dword [ebp]
xor edx, edx
mov word [ecx + eax*2], dx
mov byte [esp + 0x47c], 1
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x45f3b7
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp]
push eax
call dword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
test eax, eax
je 0x45f64f
mov eax, dword [ebp]
mov ebx, dword [sym.imp.SHLWAPI.dll_PathFindFileNameW]
push eax
call ebx
lea ecx, [esp + 0x1c]
push ecx
mov ecx, eax
call fcn.00405a20
xor edx, edx
push 0x206
push edx
lea eax, [esp + 0x66]
mov byte [esp + 0x484], 3
push eax
mov word [esp + 0x68], dx
call fcn.00494b20
add esp, 0xc
xor ecx, ecx
push 0x206
push ecx
lea edx, [esp + 0x26e]
push edx
mov word [esp + 0x270], cx
call fcn.00494b20
mov eax, dword [0x4e7464]
mov edx, dword [eax + 0xc]
add esp, 0xc
mov ecx, 0x4e7464
call edx
add eax, 0x10
mov dword [esp + 0x18], eax
mov byte [esp + 0x47c], 4
mov eax, dword [0x4e7464]
mov edx, dword [eax + 0xc]
mov ecx, 0x4e7464
call edx
add eax, 0x10
mov dword [esp + 0x28], eax
push 0
push 0x10
lea eax, [esp + 0x64]
push eax
mov byte [esp + 0x488], 5
mov esi, dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
push 0
call esi
test eax, eax
je 0x45f488
lea ecx, [esp + 0x5c]
push ecx
call ebx
mov edx, eax
lea edi, [esp + 0x18]
call fcn.004059e0
push 0
push 5
lea edx, [esp + 0x26c]
push edx
push 0
call esi
test eax, eax
je 0x45f4b1
lea eax, [esp + 0x264]
push eax
call ebx
mov edx, eax
lea edi, [esp + 0x28]
call fcn.004059e0
mov ecx, dword [esp + 0x1c]
cmp dword [ecx - 0xc], 0
jl 0x45f4de
push 0x4cb6d8
push ecx
call fcn.004915bc
mov ecx, dword [esp + 0x24]
add esp, 8
test eax, eax
je 0x45f4de
sub eax, ecx
sar eax, 1
cmp eax, 0xffffffff
jne 0x45f63c
xor eax, eax
test ecx, ecx
setne al
test eax, eax
jne 0x45f4fd
push 0x80004005
call fcn.004058d0
push 0x80070057
call fcn.004058d0
push ecx
mov ecx, dword [esp + 0x1c]
push ecx
call fcn.004920dc
add esp, 8
test eax, eax
je 0x45f63c
mov ecx, dword [esp + 0x1c]
lea edx, [esp + 0x28]
push edx
call fcn.0042c350
test eax, eax
je 0x45f63c
mov ebx, dword [sym.imp.KERNEL32.dll_lstrcmpiW]
mov dword [esp + 0x38], str.Windows
mov dword [esp + 0x3c], str.Winnt
mov dword [esp + 0x40], str.System
mov dword [esp + 0x44], str.System32
mov dword [esp + 0x48], str.Program_Files
mov dword [esp + 0x4c], str.Documents_and_Settings
mov dword [esp + 0x50], 0x4cb260
mov dword [esp + 0x54], str.Desktop
mov dword [esp + 0x58], str.My_Documents
xor edi, edi
lea esp, [esp]
mov esi, dword [esp + edi*4 + 0x38]
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
test eax, eax
je 0x45f59f
mov eax, dword [esp + 0x1c]
push esi
push eax
call ebx
test eax, eax
je 0x45f63c
inc edi
cmp edi, 9
jb 0x45f580
mov eax, 0x4ca3d4
mov ebx, ebp
call fcn.00461eb0
push 0x4ca3d4
mov eax, ebp
call fcn.00461e50
mov esi, 1
mov byte [esp + 0x47c], 4
mov eax, dword [esp + 0x28]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x45f5ea
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x47c], 3
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x45f612
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x47c], 1
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x45f65d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
jmp 0x45f65d
mov edx, 0x4c4788
mov edi, ebp
call fcn.004059e0
xor esi, esi
jmp 0x45f5c2
mov edx, 0x4c4788
mov edi, ebp
call fcn.004059e0
xor esi, esi
mov byte [esp + 0x47c], 0
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x45f685
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x47c], 0xffffffff
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x45f6b0
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, esi
jmp 0x45f6b6
xor eax, eax
mov ecx, dword [esp + 0x474]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x458]
xor ecx, esp
call fcn.0049021b
add esp, 0x46c
ret