Function at 0x4011a7
Capabilities:
Check if file exists
Delete file
Enumerate files on windows
Get common file path
Get file attributes
Get file size
Move file
Read file on windows
Set file attributes

Disassembly:
push 0x3d4
mov eax, 0x4121e7
call fcn.00407649
lea eax, [ebp - 0x3a4]
mov esi, ecx
push eax
mov dword [ebp - 0x388], esi
call fcn.004022a4
push esi
xor ebx, ebx
lea eax, [ebp - 0x220]
mov dword [ebp - 4], ebx
mov esi, dword [sym.imp.USER32.dll_wsprintfA]
push 0x414ca8
push eax
call esi
add esp, 0xc
lea eax, [ebp - 0x380]
push eax
lea eax, [ebp - 0x220]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov dword [ebp - 0x384], eax
cmp eax, 0xffffffff
je 0x4012d2
lea eax, [ebp - 0x354]
push eax
push dword [ebp - 0x388]
lea eax, [ebp - 0x220]
push 0x414cb0
push eax
call esi
lea eax, [ebp - 0x354]
push 0x414cb8
push eax
call fcn.00406640
add esp, 0x18
test eax, eax
je 0x40129b
lea eax, [ebp - 0x354]
push 0x414cbc
push eax
call fcn.00406640
pop ecx
pop ecx
test eax, eax
je 0x40129b
lea eax, [ebp - 0x220]
push eax
lea ecx, [ebp - 0x3dc]
call fcn.00402252
mov byte [ebp - 4], 1
mov eax, dword [ebp - 0x390]
mov ecx, dword [ebp - 0x3a4]
push eax
push ecx
lea eax, [ebp - 0x3dc]
push eax
lea edi, [ebp - 0x3a4]
call fcn.00402475
push ebx
push 1
lea ecx, [ebp - 0x3dc]
mov byte [ebp - 4], bl
call fcn.0040242a
lea eax, [ebp - 0x380]
push eax
push dword [ebp - 0x384]
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
cmp eax, ebx
jne 0x4012c5
push dword [ebp - 0x384]
call dword [sym.imp.KERNEL32.dll_FindClose]
or dword [ebp - 0x384], 0xffffffff
cmp dword [ebp - 0x384], 0xffffffff
jne 0x40120a
push dword [ebp - 0x388]
lea ecx, [ebp - 0x3dc]
call fcn.00402252
mov byte [ebp - 4], 2
mov eax, dword [ebp - 0x390]
mov ecx, dword [ebp - 0x3a4]
push eax
push ecx
lea eax, [ebp - 0x3dc]
push eax
lea edi, [ebp - 0x3a4]
call fcn.00402475
push ebx
push 1
lea ecx, [ebp - 0x3dc]
mov byte [ebp - 4], bl
call fcn.0040242a
mov eax, edi
call fcn.0040232d
push eax
lea ecx, [ebp - 0x23c]
call fcn.00402274
mov eax, edi
mov byte [ebp - 4], 3
call fcn.00402353
cmp dword [ebp - 0x224], 0x10
mov eax, dword [ebp - 0x238]
jae 0x40134b
lea eax, [ebp - 0x238]
mov esi, dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push 0x80
push eax
call esi
cmp dword [ebp - 0x224], 0x10
mov eax, dword [ebp - 0x238]
jae 0x40136e
lea eax, [ebp - 0x238]
mov edi, dword [sym.imp.KERNEL32.dll_MoveFileExA]
push 4
push ebx
push eax
call edi
cmp eax, ebx
jne 0x401450
mov eax, dword [ebp - 0x390]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x3a4]
push eax
push ecx
lea eax, [ebp - 0x23c]
push eax
lea edi, [ebp - 0x3a4]
call fcn.00402475
push 0x104
lea eax, [ebp - 0x118]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
lea eax, [ebp - 0x118]
push str.wininit.ini
push eax
call fcn.00405f70
pop ecx
pop ecx
lea eax, [ebp - 0x118]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x4014b1
lea eax, [ebp - 0x118]
push 0x414cd0
push eax
call fcn.00406485
mov esi, eax
push str._rename__n
push esi
call fcn.0040651a
add esp, 0x10
jmp 0x401490
lea eax, [ebp - 0x3a4]
call fcn.0040232d
cmp dword [eax + 0x18], 0x10
jb 0x40141b
mov eax, dword [eax + 4]
jmp 0x40141e
add eax, 4
push 0x80
push eax
call esi
lea eax, [ebp - 0x3a4]
call fcn.0040232d
cmp dword [eax + 0x18], 0x10
jb 0x40143c
mov eax, dword [eax + 4]
jmp 0x40143f
add eax, 4
push 4
push ebx
push eax
call edi
lea eax, [ebp - 0x3a4]
call fcn.00402353
cmp dword [ebp - 0x38c], ebx
ja 0x401405
jmp 0x401784
lea eax, [ebp - 0x3a4]
call fcn.0040232d
cmp dword [eax + 0x18], 0x10
jb 0x401473
mov eax, dword [eax + 4]
jmp 0x401476
add eax, 4
push eax
push str.NUL_s_n
push esi
call fcn.0040651a
add esp, 0xc
lea eax, [ebp - 0x3a4]
call fcn.00402353
cmp dword [ebp - 0x38c], ebx
ja 0x40145d
push 0x414ce8
push esi
call fcn.0040651a
push esi
call fcn.00406818
add esp, 0xc
jmp 0x401784
lea eax, [ebp - 0x3c0]
push eax
call fcn.004022a4
push ebx
push ebx
push 3
push ebx
push ebx
push 0x80000000
lea eax, [ebp - 0x118]
push eax
mov byte [ebp - 4], 4
call dword [sym.imp.KERNEL32.dll_CreateFileA]
push ebx
push eax
mov dword [ebp - 0x388], eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
lea eax, [esi + 1]
push eax
call fcn.00405c9a
pop ecx
mov edi, eax
push ebx
lea eax, [ebp - 0x3e0]
push eax
push esi
push edi
push dword [ebp - 0x388]
mov byte [edi + esi], bl
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x388]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x384], edi
mov esi, edi
cmp byte [edi], bl
je 0x40161c
jmp 0x401537
mov al, byte [esi]
cmp al, 0xd
je 0x401540
cmp al, 0xa
je 0x40153b
inc esi
cmp byte [esi], bl
jne 0x40152c
cmp byte [esi], 0xd
jne 0x40154a
cmp byte [esi + 1], 0xa
mov byte [esi], bl
jne 0x40154a
inc esi
inc esi
cmp byte [esi], 0xa
jne 0x401552
mov byte [esi], bl
inc esi
push dword [ebp - 0x384]
lea ecx, [ebp - 0x3dc]
call fcn.00402252
mov byte [ebp - 4], 5
mov eax, dword [ebp - 0x3ac]
mov ecx, dword [ebp - 0x3c0]
push eax
push ecx
lea eax, [ebp - 0x3dc]
push eax
lea edi, [ebp - 0x3c0]
call fcn.00402475
push ebx
push 1
lea ecx, [ebp - 0x3dc]
mov byte [ebp - 4], 4
call fcn.0040242a
push str._rename_
push dword [ebp - 0x384]
call fcn.00408342
pop ecx
pop ecx
test eax, eax
jne 0x40160e
jmp 0x401606
lea eax, [ebp - 0x3a4]
call fcn.0040232d
push eax
lea eax, [ebp - 0x3dc]
push eax
call fcn.00402865
pop ecx
pop ecx
mov byte [ebp - 4], 6
mov ecx, dword [ebp - 0x3ac]
mov edx, dword [ebp - 0x3c0]
push ecx
push edx
push eax
lea edi, [ebp - 0x3c0]
call fcn.00402475
push ebx
push 1
lea ecx, [ebp - 0x3dc]
mov byte [ebp - 4], 4
call fcn.0040242a
lea eax, [ebp - 0x3a4]
call fcn.00402353
cmp dword [ebp - 0x38c], ebx
ja 0x4015b1
mov dword [ebp - 0x384], esi
cmp byte [esi], bl
jne 0x40152c
cmp dword [ebp - 0x38c], ebx
jbe 0x40170f
push str._rename_
lea ecx, [ebp - 0x3dc]
call fcn.00402252
mov byte [ebp - 4], 7
mov eax, dword [ebp - 0x3ac]
mov ecx, dword [ebp - 0x3c0]
push eax
push ecx
lea eax, [ebp - 0x3dc]
push eax
lea edi, [ebp - 0x3c0]
call fcn.00402475
push ebx
push 1
lea ecx, [ebp - 0x3dc]
mov byte [ebp - 4], 4
call fcn.0040242a
jmp 0x4016c5
lea eax, [ebp - 0x3a4]
call fcn.0040232d
push eax
lea eax, [ebp - 0x3dc]
push eax
call fcn.00402865
pop ecx
pop ecx
mov byte [ebp - 4], 8
mov ecx, dword [ebp - 0x3ac]
mov edx, dword [ebp - 0x3c0]
push ecx
push edx
push eax
lea edi, [ebp - 0x3c0]
call fcn.00402475
push ebx
push 1
lea ecx, [ebp - 0x3dc]
mov byte [ebp - 4], 4
call fcn.0040242a
lea eax, [ebp - 0x3a4]
call fcn.00402353
cmp dword [ebp - 0x38c], ebx
ja 0x401670
push 0x414cfd
lea ecx, [ebp - 0x3dc]
call fcn.00402252
mov byte [ebp - 4], 9
mov eax, dword [ebp - 0x3ac]
mov ecx, dword [ebp - 0x3c0]
push eax
push ecx
lea eax, [ebp - 0x3dc]
push eax
lea edi, [ebp - 0x3c0]
call fcn.00402475
push ebx
push 1
lea ecx, [ebp - 0x3dc]
call fcn.0040242a
lea eax, [ebp - 0x118]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea eax, [ebp - 0x118]
push 0x414cd0
push eax
call fcn.00406485
mov esi, eax
pop ecx
pop ecx
cmp esi, ebx
je 0x401779
jmp 0x40176a
lea eax, [ebp - 0x3c0]
call fcn.0040232d
cmp dword [eax + 0x18], 0x10
jb 0x40174d
mov eax, dword [eax + 4]
jmp 0x401750
add eax, 4
push eax
push 0x414d00
push esi
call fcn.0040651a
add esp, 0xc
lea eax, [ebp - 0x3c0]
call fcn.00402353
cmp dword [ebp - 0x3a8], ebx
ja 0x401737
push esi
call fcn.00406818
pop ecx
lea esi, [ebp - 0x3c0]
call fcn.004022e1
push ebx
push 1
lea ecx, [ebp - 0x23c]
call fcn.0040242a
lea esi, [ebp - 0x3a4]
call fcn.004022e1
call fcn.00407693
ret