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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x424
push ebx
push esi
push edi
mov edi, dword [0x597bec]
push 6
call fcn.004059ff
xor ebx, ebx
cmp eax, ebx
je 0x4052e1
call eax
movzx eax, ax
push eax
push 0x59e000
call fcn.0040587a
jmp 0x40532b
push ebx
mov esi, 0x5941d0
push esi
push ebx
push str.Control_PanelDesktopResourceLocale
push 0x80000001
mov dword [0x59e000], 0x7830
call fcn.00405803
cmp byte [0x5941d0], bl
jne 0x405320
push ebx
push esi
push 0x40752a
push str..DEFAULTControl_PanelInternational
push 0x80000003
call fcn.00405803
push esi
push 0x59e000
call sub.KERNEL32.dll_lstrcatA
call fcn.0040394a
mov eax, dword [0x597c48]
and eax, 0x20
push 0x59d400
mov dword [0x597ca0], eax
mov dword [0x597cbc], 0x10000
call fcn.00405afb
test eax, eax
jne 0x4053e4
mov ecx, dword [edi + 0x48]
cmp ecx, ebx
je 0x4053e4
mov eax, dword [0x597c18]
mov edx, dword [edi + 0x4c]
push ebx
mov esi, 0x596b80
push esi
add edx, eax
push edx
add ecx, eax
push ecx
push dword [edi + 0x44]
call fcn.00405803
mov al, byte [0x596b80]
cmp al, bl
je 0x4053e4
cmp al, 0x22
jne 0x40539f
mov eax, 0x596b81
push 0x22
push eax
mov esi, eax
call fcn.0040569b
mov byte [eax], bl
push esi
call sub.KERNEL32.dll_lstrlenA
lea eax, [eax + esi - 4]
cmp eax, esi
jbe 0x4053d3
push str..exe
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
jne 0x4053d3
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x4053cd
test al, 0x10
jne 0x4053d3
push esi
call fcn.00405ad4
push esi
call fcn.00405aa7
push eax
push 0x59d400
call fcn.0040591c
mov esi, 0x59d400
push esi
call fcn.00405afb
test eax, eax
jne 0x4053ff
push dword [edi + 0x118]
push esi
call fcn.00405bd3
push 0x8040
push ebx
push ebx
push 1
push 0x67
push dword [0x597be8]
call dword [sym.imp.USER32.dll_LoadImageA]
mov dword [0x5973b0], eax
cmp dword [edi + 0x50], 0xffffffff
mov esi, 0x597380
je 0x4054a5
mov ecx, dword [0x597be8]
mov dword [0x597394], eax
lea eax, [ebp - 4]
push esi
mov dword [ebp - 4], 0x624e5f
mov dword [0x597384], 0x401000
mov dword [0x597390], ecx
mov dword [0x5973a4], eax
call dword [sym.imp.USER32.dll_RegisterClassA]
test ax, ax
je 0x4055cf
push ebx
lea eax, [ebp - 0x14]
push eax
push ebx
push 0x30
call dword [sym.imp.USER32.dll_SystemParametersInfoA]
mov eax, dword [ebp - 8]
sub eax, dword [ebp - 0x10]
push ebx
push dword [0x597be8]
push ebx
push ebx
push eax
mov eax, dword [ebp - 0xc]
sub eax, dword [ebp - 0x14]
push eax
push dword [ebp - 0x10]
lea eax, [ebp - 4]
push dword [ebp - 0x14]
push 0x80000000
push ebx
push eax
push 0x80
call dword [sym.imp.USER32.dll_CreateWindowExA]
mov dword [0x5935cc], eax
push ebx
call fcn.0040144f
test eax, eax
je 0x4054b7
push 2
pop eax
jmp 0x4055d1
call fcn.0040394a
cmp dword [0x597cc0], ebx
jne 0x4055a6
push 5
push dword [0x5935cc]
call dword [sym.imp.USER32.dll_ShowWindow]
push 0x208
lea eax, [ebp - 0x424]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
mov edi, dword [sym.imp.USER32.dll_wsprintfA]
push str.RichEd20
lea eax, [ebp - 0x424]
push eax
lea eax, [ebp - 0x21c]
push str._s_s.dll
push eax
call edi
add esp, 0x10
lea eax, [ebp - 0x21c]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
test eax, eax
jne 0x405546
push str.RichEd32
lea eax, [ebp - 0x424]
push eax
lea eax, [ebp - 0x21c]
push str._s_s.dll
push eax
call edi
add esp, 0x10
lea eax, [ebp - 0x21c]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, dword [sym.imp.USER32.dll_GetClassInfoA]
push esi
push str.RichEdit20A
push ebx
call edi
test eax, eax
jne 0x405573
push esi
push str.RichEdit
push ebx
call edi
push esi
mov dword [0x5973a4], 0x4074ac
call dword [sym.imp.USER32.dll_RegisterClassA]
mov eax, dword [0x5973bc]
push ebx
push 0x404e02
add eax, 0x69
movzx eax, ax
push ebx
push eax
push dword [0x597be8]
call dword [sym.imp.USER32.dll_DialogBoxParamA]
push 5
mov esi, eax
call fcn.0040144f
push 1
call fcn.0040373e
mov eax, esi
jmp 0x4055d1
push ebx
call fcn.00404a09
test eax, eax
je 0x4055c8
cmp dword [0x5973b4], ebx
jne 0x4054af
push 2
call fcn.0040144f
jmp 0x4054af
push 1
call fcn.0040144f
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret