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

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x4289b0
push eax
mov dword fs:[0], esp
sub esp, 0x134
push ebx
push ebp
push esi
push edi
mov esi, ecx
call fcn.004185b0
test eax, eax
je 0x4185a3
lea eax, [esp + 0x40]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
xor edi, edi
cmp eax, edi
ja 0x417ca9
call dword [sym.imp.KERNEL32.dll_GetLastError]
lea ecx, [esp + 0x28]
mov esi, eax
call sub.MFC42.DLL_CString::CString_1
push edi
lea ecx, [esp + 0x30]
push edi
push ecx
push 0x400
push esi
push edi
push 0x1300
mov dword [esp + 0x168], edi
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
mov edx, dword [esp + 0x2c]
lea ecx, [esp + 0x10]
push edx
call fcn.0042687e
lea ecx, [esp + 0x10]
mov byte [esp + 0x14c], 1
call sub.MFC42.DLL_CString::TrimLeft
lea ecx, [esp + 0x10]
call sub.MFC42.DLL_CString::TrimRight
mov eax, dword [esp + 0x10]
push esi
push eax
lea ecx, [esp + 0x30]
push str._s__d__n_n_
push ecx
call sub.MFC42.DLL_CString::Format
mov edx, dword [esp + 0x38]
push edi
push edi
push 1
push edi
push edx
push 0x4339ec
push 0x4339c8
call fcn.0041f890
mov eax, dword [esp + 0x58]
add esp, 0x2c
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
lea ecx, [esp + 0x10]
mov byte [esp + 0x14c], 0
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x28]
mov dword [esp + 0x14c], 0xffffffff
call sub.MFC42.DLL_CString::CString
xor eax, eax
jmp 0x4181e5
lea ecx, [esp + 0x1c]
mov byte [esp + eax + 0x40], 0
call sub.MFC42.DLL_CString::CString_1
lea ecx, [esp + 0x20]
mov dword [esp + 0x14c], 2
call sub.MFC42.DLL_CString::CString_1
lea ecx, [esp + 0x18]
mov byte [esp + 0x14c], 3
call sub.MFC42.DLL_CString::CString_1
lea ecx, [esp + 0x30]
mov byte [esp + 0x14c], 4
call sub.MFC42.DLL_CString::CString_1
lea ecx, [esp + 0x40]
push 0x432cec
push ecx
lea edx, [esp + 0x28]
push 0x4339b4
push edx
mov byte [esp + 0x15c], 5
call sub.MFC42.DLL_CString::Format
mov eax, dword [esi + 0x14]
mov ebp, dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
mov dword [esp + 0x34], eax
mov eax, dword [esi + 0x18]
add esp, 0x10
cmp eax, edi
mov dword [esp + 0x14], edi
jle 0x418134
mov eax, dword [esi + 0x14]
xor ebx, ebx
test eax, eax
mov dword [esp + 0x10], ebx
jle 0x417f1e
mov ecx, dword [esp + 0x14]
lea edi, [ecx*8]
mov edx, dword [esi + 0x20]
mov eax, edi
lea ecx, [edx + ebx*8]
mov edx, dword [esi + 0x24]
add eax, edx
mov ecx, dword [ecx]
mov eax, dword [eax]
push ecx
push eax
call dword [sym.imp.MSVCRT.dll__mbscmp]
add esp, 8
test eax, eax
je 0x417d7a
mov eax, dword [esi + 0x14]
inc ebx
cmp ebx, eax
jl 0x417d49
mov dword [esp + 0x10], ebx
jmp 0x417f1e
mov eax, dword [esi + 0x24]
mov ecx, dword [esi + 0x20]
lea ebp, [ebx*8]
mov dword [esp + 0x10], ebx
mov eax, dword [edi + eax + 4]
mov ebx, dword [ecx + ebp + 4]
push eax
call dword [sym.imp.MSVCRT.dll_atoi]
mov edx, eax
push ebx
mov dword [esp + 0x3c], edx
call dword [sym.imp.MSVCRT.dll_atoi]
mov edx, dword [esp + 0x3c]
add esp, 8
cmp edx, eax
jle 0x417f14
lea eax, [esp + 0x40]
lea ecx, [esp + 0x1c]
push eax
call fcn.00426980
push 0x432860
lea ecx, [esp + 0x20]
call fcn.00426a0a
mov ebx, dword [esi + 0x20]
mov ecx, ebp
add ecx, ebx
push ecx
lea ecx, [esp + 0x20]
call sub.MFC42.DLL_CString::operator
mov edx, dword [esp + 0x1c]
push 0x80
push edx
call dword [sym.imp.MSVCRT.dll__chmod]
mov eax, dword [esi + 4]
add esp, 8
test eax, eax
jne 0x417e1c
mov ecx, dword [esi + 0x20]
push str.INITray.exe
add ebp, ecx
mov ebp, dword [ebp]
push ebp
call dword [sym.imp.MSVCRT.dll__mbscmp]
add esp, 8
test eax, eax
je 0x417f14
mov eax, dword [esp + 0x1c]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
jne 0x417e3e
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebx
mov ebp, eax
cmp ebp, 2
jne 0x4181fe
mov ecx, dword [esi + 0x24]
mov eax, dword [esi + 0x1c]
mov edx, dword [edi + ecx]
lea ecx, [esp + 0x18]
push edx
push eax
push str._sfiles__s.gz
push ecx
call sub.MFC42.DLL_CString::Format
mov edx, dword [esi + 0x24]
mov ecx, dword [esi + 8]
add esp, 0x10
mov eax, dword [edi + edx]
mov edx, dword [ecx + 0x70]
push eax
push edx
lea eax, [esp + 0x38]
push 0x4339b4
push eax
call sub.MFC42.DLL_CString::Format
add esp, 0x10
lea edx, [esp + 0x18]
push 1
push ecx
mov ecx, esp
mov dword [esp + 0x3c], esp
push edx
call sub.MFC42.DLL_CString::CString_2
push ecx
lea eax, [esp + 0x3c]
mov ecx, esp
mov dword [esp + 0x44], esp
push eax
mov byte [esp + 0x15c], 0xa
call sub.MFC42.DLL_CString::CString_2
mov ecx, dword [esi + 8]
mov byte [esp + 0x158], 5
call fcn.004107f0
test eax, eax
jne 0x4180e6
mov ecx, dword [esi + 0x24]
mov eax, edi
add eax, ecx
push str.INIbank.dll
mov eax, dword [eax]
push eax
call dword [sym.imp.MSVCRT.dll__mbsicmp]
add esp, 8
test eax, eax
je 0x4180e6
mov ecx, dword [esi + 0x24]
lea eax, [esp + 0x18]
mov edx, dword [edi + ecx]
push edx
push str.__s_
push eax
call sub.MFC42.DLL_CString::Format
mov ecx, dword [esp + 0x24]
push 0
push 0
push 1
push 0
push ecx
push 0x434e48
push 0x43144c
call fcn.0041f890
add esp, 0x28
mov ebp, dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
mov ebx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
lea eax, [edx + 1]
mov dword [esp + 0x34], eax
push eax
lea eax, [esp + 0x1c]
push 0x434e44
push eax
call sub.MFC42.DLL_CString::Format
mov ecx, dword [esp + 0x20]
mov edx, dword [esi + 0x24]
add esp, 0xc
lea edi, [ecx*8]
mov ecx, dword [esp + 0x20]
push ecx
mov eax, dword [edi + edx]
mov edx, dword [esp + 0x1c]
push eax
push edx
push str.VERSION
call ebp
test eax, eax
jne 0x417f99
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 5
jne 0x417f99
mov eax, dword [esp + 0x20]
push 0x80
push eax
call dword [sym.imp.MSVCRT.dll__chmod]
mov ecx, dword [esi + 0x24]
mov edx, dword [esp + 0x28]
add esp, 8
mov eax, dword [edi + ecx]
push edx
push eax
mov eax, dword [esp + 0x20]
push eax
push str.VERSION
call ebp
cmp ebx, dword [esi + 0x14]
jl 0x418121
mov eax, dword [esp + 0x24]
lea ecx, [esp + 0x40]
inc eax
push ecx
lea ecx, [esp + 0x20]
mov dword [esp + 0x28], eax
call fcn.00426980
push 0x432860
lea ecx, [esp + 0x20]
call fcn.00426a0a
mov ecx, dword [esi + 0x24]
mov edx, edi
add edx, ecx
lea ecx, [esp + 0x1c]
push edx
call sub.MFC42.DLL_CString::operator
mov eax, dword [esp + 0x1c]
push 0x80
push eax
call dword [sym.imp.MSVCRT.dll__chmod]
mov eax, dword [esi + 4]
add esp, 8
test eax, eax
jne 0x418012
mov edx, dword [esi + 0x24]
mov eax, edi
add eax, edx
push str.INITray.exe
mov eax, dword [eax]
push eax
call dword [sym.imp.MSVCRT.dll__mbscmp]
add esp, 8
test eax, eax
je 0x418121
mov ecx, dword [esp + 0x1c]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
jne 0x418032
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
cmp ebx, 2
jne 0x4183ab
mov edx, dword [esi + 0x24]
mov ecx, dword [esi + 0x1c]
mov eax, dword [edi + edx]
lea edx, [esp + 0x18]
push eax
push ecx
push str._sfiles__s.gz
push edx
call sub.MFC42.DLL_CString::Format
mov eax, dword [esi + 0x24]
mov edx, dword [esi + 8]
add esp, 0x10
mov ecx, dword [edi + eax]
mov eax, dword [edx + 0x70]
push ecx
push eax
lea ecx, [esp + 0x38]
push 0x4339b4
push ecx
call sub.MFC42.DLL_CString::Format
add esp, 0x10
lea edx, [esp + 0x18]
push 1
push ecx
mov ecx, esp
mov dword [esp + 0x40], esp
push edx
call sub.MFC42.DLL_CString::CString_2
push ecx
lea eax, [esp + 0x3c]
mov ecx, esp
mov dword [esp + 0x48], esp
push eax
mov byte [esp + 0x15c], 0xf
call sub.MFC42.DLL_CString::CString_2
mov ecx, dword [esi + 8]
mov byte [esp + 0x158], 5
call fcn.004107f0
test eax, eax
jne 0x418109
mov ecx, dword [esi + 0x24]
lea eax, [esp + 0x18]
mov edx, dword [edi + ecx]
push edx
push str.__s_
push eax
call sub.MFC42.DLL_CString::Format
mov ecx, dword [esp + 0x24]
push 0
push 0
push 1
push 0
push ecx
push 0x434e48
push 0x43144c
call fcn.0041f890
add esp, 0x28
jmp 0x418121
mov edx, dword [esi + 0x24]
mov ecx, dword [esp + 0x20]
mov ebp, dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
add edi, edx
push ecx
mov eax, dword [edi + 4]
mov edi, dword [edi]
push eax
push edi
push str.VERSION
call ebp
jmp 0x417f1a
mov edx, dword [esi + 0x24]
mov ecx, dword [esp + 0x20]
add edi, edx
push ecx
mov eax, dword [edi + 4]
mov edi, dword [edi]
push eax
push edi
push str.VERSION
call ebp
mov eax, dword [esp + 0x34]
mov ecx, dword [esi + 0x18]
cmp eax, ecx
mov dword [esp + 0x14], eax
jl 0x417d2d
mov ecx, dword [esp + 0x24]
lea edx, [esp + 0x18]
push ecx
push 0x434e44
push edx
call sub.MFC42.DLL_CString::Format
mov eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0x24]
add esp, 0xc
push eax
push ecx
push str.filecount
push str.VERSION
call ebp
test eax, eax
jne 0x418199
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 5
jne 0x418199
mov edx, dword [esp + 0x20]
push 0x80
push edx
call dword [sym.imp.MSVCRT.dll__chmod]
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x20]
add esp, 8
push eax
push ecx
push str.filecount
push str.VERSION
call ebp
lea ecx, [esp + 0x30]
mov byte [esp + 0x14c], 4
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x18]
mov byte [esp + 0x14c], 3
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x20]
mov byte [esp + 0x14c], 2
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x1c]
mov dword [esp + 0x14c], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov eax, 1
mov ecx, dword [esp + 0x144]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
pop ebx
add esp, 0x140
ret
lea ecx, [esp + 0x28]
call sub.MFC42.DLL_CString::CString_1
lea ecx, [esp + 0x2c]
mov byte [esp + 0x14c], 6
call sub.MFC42.DLL_CString::CString_1
push 0x104
push 0x104
lea ecx, [esp + 0x34]
mov byte [esp + 0x154], 7
call sub.MFC42.DLL_CString::GetBuffer
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
push 0xffffffffffffffff
lea ecx, [esp + 0x30]
call sub.MFC42.DLL_CString::ReleaseBuffer
mov edx, dword [esp + 0x2c]
lea eax, [esp + 0x28]
push edx
push str._sTest.file
push eax
call sub.MFC42.DLL_CString::Format
mov ecx, dword [esp + 0x34]
push 0x432434
push ecx
call dword [sym.imp.MSVCRT.dll_fopen]
add esp, 0x14
test eax, eax
je 0x418290
push eax
call dword [sym.imp.MSVCRT.dll_fclose]
mov edx, dword [esp + 0x2c]
add esp, 4
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
jne 0x418292
call ebx
cmp eax, 2
je 0x418292
xor ebp, ebp
lea ecx, [esp + 0x10]
call sub.MFC42.DLL_CString::CString_1
mov bl, 8
test ebp, ebp
mov byte [esp + 0x14c], bl
jne 0x4182e2
push 0x433bf4
lea ecx, [esp + 0x14]
call fcn.00426980
push 0x433bc0
lea ecx, [esp + 0x14]
call fcn.00426a0a
push 0x433b78
lea ecx, [esp + 0x14]
call fcn.00426a0a
push 0x433b2c
lea ecx, [esp + 0x14]
call fcn.00426a0a
jmp 0x418359
push 0
lea eax, [esp + 0x28]
push 0
push eax
push 0x400
push ebp
push 0
push 0x1300
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
mov ecx, dword [esp + 0x24]
push ecx
lea ecx, [esp + 0x18]
call fcn.0042687e
lea ecx, [esp + 0x14]
mov byte [esp + 0x14c], 9
call sub.MFC42.DLL_CString::TrimLeft
lea ecx, [esp + 0x14]
call sub.MFC42.DLL_CString::TrimRight
mov edx, dword [esp + 0x14]
push ebp
push edx
lea eax, [esp + 0x18]
push 0x433a50
push eax
call sub.MFC42.DLL_CString::Format
mov ecx, dword [esp + 0x34]
add esp, 0x10
push ecx
call dword [sym.imp.KERNEL32.dll_LocalFree]
lea ecx, [esp + 0x14]
mov byte [esp + 0x14c], bl
call sub.MFC42.DLL_CString::CString
mov edx, dword [esp + 0x10]
push 0
push 0
push 5
push 0
push edx
push 0x434dd0
push 0x434d9c
call fcn.0041f890
add esp, 0x1c
lea ecx, [esp + 0x10]
mov byte [esp + 0x14c], 7
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x2c]
mov byte [esp + 0x14c], 6
call sub.MFC42.DLL_CString::CString
mov byte [esp + 0x14c], 5
lea ecx, [esp + 0x28]
jmp 0x418557
lea ecx, [esp + 0x24]
call sub.MFC42.DLL_CString::CString_1
lea ecx, [esp + 0x38]
mov byte [esp + 0x14c], 0xb
call sub.MFC42.DLL_CString::CString_1
push 0x104
push 0x104
lea ecx, [esp + 0x40]
mov byte [esp + 0x154], 0xc
call sub.MFC42.DLL_CString::GetBuffer
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
push 0xffffffffffffffff
lea ecx, [esp + 0x3c]
call sub.MFC42.DLL_CString::ReleaseBuffer
mov eax, dword [esp + 0x38]
lea ecx, [esp + 0x24]
push eax
push str._sTest.file
push ecx
call sub.MFC42.DLL_CString::Format
mov edx, dword [esp + 0x30]
push 0x432434
push edx
call dword [sym.imp.MSVCRT.dll_fopen]
add esp, 0x14
test eax, eax
je 0x418441
push eax
call dword [sym.imp.MSVCRT.dll_fclose]
mov eax, dword [esp + 0x28]
add esp, 4
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
jne 0x418443
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
je 0x418443
xor ebx, ebx
lea ecx, [esp + 0x14]
call sub.MFC42.DLL_CString::CString_1
test ebx, ebx
mov byte [esp + 0x14c], 0xd
jne 0x418492
push 0x433bf4
lea ecx, [esp + 0x18]
call fcn.00426980
push 0x433bc0
lea ecx, [esp + 0x18]
call fcn.00426a0a
push 0x433b78
lea ecx, [esp + 0x18]
call fcn.00426a0a
push 0x433b2c
lea ecx, [esp + 0x18]
call fcn.00426a0a
jmp 0x41850a
push 0
lea ecx, [esp + 0x38]
push 0
push ecx
push 0x400
push ebx
push 0
push 0x1300
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
mov edx, dword [esp + 0x34]
lea ecx, [esp + 0x3c]
push edx
call fcn.0042687e
lea ecx, [esp + 0x3c]
mov byte [esp + 0x14c], 0xe
call sub.MFC42.DLL_CString::TrimLeft
lea ecx, [esp + 0x3c]
call sub.MFC42.DLL_CString::TrimRight
mov eax, dword [esp + 0x3c]
push ebx
push eax
lea ecx, [esp + 0x1c]
push 0x433a50
push ecx
call sub.MFC42.DLL_CString::Format
mov edx, dword [esp + 0x44]
add esp, 0x10
push edx
call dword [sym.imp.KERNEL32.dll_LocalFree]
lea ecx, [esp + 0x3c]
mov byte [esp + 0x14c], 0xd
call sub.MFC42.DLL_CString::CString
mov eax, dword [esp + 0x14]
push 0
push 0
push 5
push 0
push eax
push 0x434dd0
push 0x434d9c
call fcn.0041f890
add esp, 0x1c
lea ecx, [esp + 0x14]
mov byte [esp + 0x14c], 0xc
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x38]
mov byte [esp + 0x14c], 0xb
call sub.MFC42.DLL_CString::CString
mov byte [esp + 0x14c], 5
lea ecx, [esp + 0x24]
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x30]
mov byte [esp + 0x14c], 4
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x18]
mov byte [esp + 0x14c], 3
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x20]
mov byte [esp + 0x14c], 2
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x1c]
mov dword [esp + 0x14c], 0xffffffff
call sub.MFC42.DLL_CString::CString
xor eax, eax
jmp 0x4181e5