Function at 0x4021b3
Capabilities:
Check if file exists
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x494
mov eax, dword [0x433024]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
lea eax, [ebp - 0x470]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemTime]
sub esp, 0x10
lea esi, [ebp - 0x470]
mov edi, esp
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
call fcn.00401e59
add esp, 0x10
push 7
pop ecx
mov dword [ebp - 0x474], eax
mov ebx, 0x104
push ebx
lea eax, [ebp - 0x248]
mov esi, str._bootstat.dat
lea edi, [ebp - 0x20]
push eax
rep movsd dword es:[edi], dword [esi]
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x248]
push ebx
push eax
call fcn.0041628a
add esp, 0xc
lea eax, [ebp - 0x248]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x4022c7
push 0
push 0x80
push 3
push 0
push 1
push SysReAllocString
lea eax, [ebp - 0x248]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x480], eax
cmp eax, 0xffffffff
je 0x4022c7
lea ecx, [ebp - 0x47c]
push ecx
lea ecx, [ebp - 0x488]
push ecx
lea ecx, [ebp - 0x490]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileTime]
lea eax, [ebp - 0x460]
push eax
lea eax, [ebp - 0x47c]
push eax
call dword [sym.imp.KERNEL32.dll_FileTimeToSystemTime]
sub esp, 0x10
lea esi, [ebp - 0x460]
mov edi, esp
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
call fcn.00401e59
add esp, 0x10
cmp eax, dword [ebp - 0x474]
jbe 0x4022bb
mov dword [ebp - 0x474], eax
push dword [ebp - 0x480]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 8
pop ecx
push ebx
lea eax, [ebp - 0x450]
mov esi, str.configdefault
lea edi, [ebp - 0x40]
push eax
rep movsd dword es:[edi], dword [esi]
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
lea eax, [ebp - 0x40]
push eax
lea eax, [ebp - 0x450]
push ebx
push eax
call fcn.0041628a
add esp, 0xc
lea eax, [ebp - 0x450]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x40238d
push 0
push 0x80
push 3
push 0
push 1
push SysReAllocString
lea eax, [ebp - 0x248]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x40238d
lea eax, [ebp - 0x47c]
push eax
lea eax, [ebp - 0x490]
push eax
lea eax, [ebp - 0x488]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileTime]
lea eax, [ebp - 0x460]
push eax
lea eax, [ebp - 0x47c]
push eax
call dword [sym.imp.KERNEL32.dll_FileTimeToSystemTime]
sub esp, 0x10
lea esi, [ebp - 0x460]
mov edi, esp
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
call fcn.00401e59
add esp, 0x10
cmp eax, dword [ebp - 0x474]
jbe 0x402386
mov dword [ebp - 0x474], eax
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call fcn.0040249b
cmp dword [ebp - 0x474], eax
jae 0x40239e
xor eax, eax
jmp 0x4023b0
push dword [ebp - 0x474]
call fcn.004023bf
mov eax, dword [ebp - 0x474]
pop ecx
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00416201
leave
ret