Function at 0x46d9a0
Capabilities:
Check if file exists
Create directory
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d95ed
mov eax, dword fs:[0]
push eax
sub esp, 0x144
mov eax, dword [0x511070]
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 eax, dword [ebp + 0xc]
or ebx, 0xffffffff
mov esi, dword [ebp + 0x14]
mov dword [ebp - 0x150], eax
mov dword [ebp - 0x11c], 0xf
mov dword [ebp - 0x120], 0
mov byte [ebp - 0x130], 0
push 0x104
push 0
push 0x105
mov dword [ebp - 4], 0
push eax
mov dword [esi], 0
call fcn.004bbf39
push 0x105
lea eax, [ebp - 0x118]
push 0
push eax
call fcn.004a8960
add esp, 0x1c
lea eax, [ebp - 0x118]
push eax
push 0
push 0
push 0x801a
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathA]
test eax, eax
jns 0x46da54
mov dword [esi], 3
jmp 0x46dd59
cmp byte [ebp - 0x118], 0
jne 0x46da61
xor ecx, ecx
jmp 0x46da79
lea ecx, [ebp - 0x118]
lea edx, [ecx + 1]
nop word [eax + eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x46da70
sub ecx, edx
push ecx
lea eax, [ebp - 0x118]
push eax
lea ecx, [ebp - 0x130]
call fcn.00438c00
push 0x4fa3cc
lea edx, [ebp - 0x130]
lea ecx, [ebp - 0x148]
call fcn.004726b0
add esp, 4
mov edi, eax
lea eax, [ebp - 0x130]
cmp eax, edi
je 0x46daf6
mov eax, dword [ebp - 0x11c]
cmp eax, 0x10
jb 0x46dacf
inc eax
lea ecx, [ebp - 0x130]
push eax
push dword [ebp - 0x130]
call fcn.00433760
push edi
lea ecx, [ebp - 0x130]
mov dword [ebp - 0x11c], 0xf
mov dword [ebp - 0x120], 0
mov byte [ebp - 0x130], 0
call fcn.0044e280
mov byte [ebp - 4], 0
mov eax, dword [ebp - 0x134]
cmp eax, 0x10
jb 0x46db18
inc eax
lea ecx, [ebp - 0x148]
push eax
push dword [ebp - 0x148]
call fcn.00433760
cmp dword [ebp - 0x11c], 0x10
lea eax, [ebp - 0x130]
push 0
cmovae eax, dword [ebp - 0x130]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x46db5a
call edi
cmp eax, 0xb7
je 0x46db5a
call edi
cmp eax, 5
je 0x46db5a
mov dword [esi], 3
jmp 0x46dd59
push str.DeskUpdate
lea edx, [ebp - 0x130]
lea ecx, [ebp - 0x148]
call fcn.004726b0
add esp, 4
mov dword [ebp - 0x14c], eax
lea ecx, [ebp - 0x130]
cmp ecx, eax
je 0x46dbc7
mov eax, dword [ebp - 0x11c]
cmp eax, 0x10
jb 0x46db9b
inc eax
push eax
push dword [ebp - 0x130]
call fcn.00433760
push dword [ebp - 0x14c]
lea ecx, [ebp - 0x130]
mov dword [ebp - 0x11c], 0xf
mov dword [ebp - 0x120], 0
mov byte [ebp - 0x130], 0
call fcn.0044e280
mov byte [ebp - 4], 0
mov eax, dword [ebp - 0x134]
cmp eax, 0x10
jb 0x46dbe9
inc eax
lea ecx, [ebp - 0x148]
push eax
push dword [ebp - 0x148]
call fcn.00433760
cmp dword [ebp - 0x11c], 0x10
lea eax, [ebp - 0x130]
push 0
cmovae eax, dword [ebp - 0x130]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
jne 0x46dc25
call edi
cmp eax, 0xb7
je 0x46dc25
call edi
cmp eax, 5
je 0x46dc25
mov dword [esi], 3
jmp 0x46dd59
push str.GlobalMgr.db
lea edx, [ebp - 0x130]
lea ecx, [ebp - 0x148]
call fcn.004726b0
add esp, 4
mov ebx, eax
lea eax, [ebp - 0x130]
cmp eax, ebx
je 0x46dc8f
mov eax, dword [ebp - 0x11c]
cmp eax, 0x10
jb 0x46dc68
inc eax
lea ecx, [ebp - 0x130]
push eax
push dword [ebp - 0x130]
call fcn.00433760
push ebx
lea ecx, [ebp - 0x130]
mov dword [ebp - 0x11c], 0xf
mov dword [ebp - 0x120], 0
mov byte [ebp - 0x130], 0
call fcn.0044e280
mov eax, dword [ebp - 0x134]
cmp eax, 0x10
jb 0x46dcad
inc eax
lea ecx, [ebp - 0x148]
push eax
push dword [ebp - 0x148]
call fcn.00433760
cmp dword [ebp - 0x11c], 0x10
lea eax, [ebp - 0x130]
push 0
cmovae eax, dword [ebp - 0x130]
push 0x80
push 3
push 0
push 3
push 0xc0000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x46dce9
mov dword [esi], 0x50
jmp 0x46dd24
call edi
cmp eax, 2
jne 0x46dd53
cmp dword [ebp - 0x11c], 0x10
lea eax, [ebp - 0x130]
push 0
cmovae eax, dword [ebp - 0x130]
push 0x80
push 2
push 0
push 3
push 0xc0000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x46dd53
cmp dword [ebp - 0x11c], 0x10
lea eax, [ebp - 0x130]
push 0x104
cmovae eax, dword [ebp - 0x130]
push eax
push 0x105
push dword [ebp - 0x150]
call fcn.004bbcaa
add esp, 0x10
jmp 0x46dd59
mov dword [esi], 0x65f
mov eax, dword [ebp - 0x11c]
cmp eax, 0x10
jb 0x46dd77
inc eax
lea ecx, [ebp - 0x130]
push eax
push dword [ebp - 0x130]
call fcn.00433760
mov eax, ebx
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.004a5d13
mov esp, ebp
pop ebp
ret 0x10