Function at 0x411560
Capabilities:
Delete file
Get common file path
Get file size
Read file on windows
Set current directory
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x459ebe
mov eax, dword fs:[0]
push eax
sub esp, 0x1b0
mov eax, dword [0x477c1c]
xor eax, esp
mov dword [esp + 0x1ac], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x477c1c]
xor eax, esp
push eax
lea eax, [esp + 0x1c4]
mov dword fs:[0], eax
mov esi, ecx
mov dword [esp + 0x24], esi
mov dword [esp + 0x1cc], 1
xor ebx, ebx
push 0x103
lea eax, [esp + 0xc1]
push ebx
push eax
mov dword [esp + 0x38], ebx
mov dword [esp + 0x34], ebx
mov byte [esp + 0xc8], bl
call fcn.00440d10
add esp, 0xc
lea ecx, [esp + 0xbc]
push ecx
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
mov eax, dword [esp + 0x1d8]
mov ebp, 0x10
cmp dword [esp + 0x1ec], ebp
jae 0x411602
lea eax, [esp + 0x1d8]
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
mov eax, dword [esp + 0x1d8]
cmp dword [esp + 0x1ec], ebp
jae 0x411620
lea eax, [esp + 0x1d8]
push eax
mov ecx, esi
call fcn.00412800
push 0x45ecf4
lea edx, [esp + 0x1d8]
mov dword [esp + 0x50], eax
push edx
lea eax, [esp + 0x38]
push eax
call fcn.00409410
mov byte [esp + 0x1d8], 2
lea ecx, [esp + 0x1fc]
push ecx
push eax
lea edx, [esp + 0x70]
push edx
call fcn.004094f0
mov byte [esp + 0x1e4], 3
push str..src
push eax
lea eax, [esp + 0xa4]
push eax
call fcn.00409410
add esp, 0x24
mov byte [esp + 0x1cc], 5
cmp dword [esp + 0x74], ebp
jb 0x411697
mov ecx, dword [esp + 0x60]
push ecx
call fcn.00421b49
add esp, 4
mov edi, 0xf
mov dword [esp + 0x74], edi
mov dword [esp + 0x70], ebx
mov byte [esp + 0x60], bl
mov byte [esp + 0x1cc], 6
cmp dword [esp + 0x48], ebp
jb 0x4116c3
mov edx, dword [esp + 0x34]
push edx
call fcn.00421b49
add esp, 4
push 0x45ecf4
lea eax, [esp + 0x1d8]
push eax
lea ecx, [esp + 0x64]
push ecx
mov dword [esp + 0x54], edi
mov dword [esp + 0x50], ebx
mov byte [esp + 0x40], bl
call fcn.00409410
mov byte [esp + 0x1d8], 7
lea edx, [esp + 0x1fc]
push edx
push eax
lea eax, [esp + 0x44]
push eax
call fcn.004094f0
mov byte [esp + 0x1e4], 8
push str..hdr
push eax
lea ecx, [esp + 0xc0]
push ecx
call fcn.00409410
add esp, 0x24
mov byte [esp + 0x1cc], 0xa
cmp dword [esp + 0x48], ebp
jb 0x41173a
mov edx, dword [esp + 0x34]
push edx
call fcn.00421b49
add esp, 4
mov dword [esp + 0x48], edi
mov dword [esp + 0x44], ebx
mov byte [esp + 0x34], bl
mov byte [esp + 0x1cc], 0xb
cmp dword [esp + 0x74], ebp
jb 0x411761
mov eax, dword [esp + 0x60]
push eax
call fcn.00421b49
add esp, 4
sub esp, 0x1c
mov ecx, esp
mov dword [esp + 0x30], esp
push 0xffffffffffffffff
push ebx
lea edx, [esp + 0x214]
mov dword [ecx + 0x18], edi
mov dword [ecx + 0x14], ebx
push edx
mov dword [esp + 0x9c], edi
mov dword [esp + 0x98], ebx
mov byte [esp + 0x88], bl
mov byte [ecx + 4], bl
call fcn.00401cc0
mov byte [esp + 0x1e8], 0xc
mov byte [esp + 0x1e8], 0xb
mov ecx, esi
call fcn.004111d0
mov ecx, dword [esi + 0xe8]
sub ecx, dword [esi + 0xe4]
mov eax, 0x92492493
imul ecx
add edx, ecx
sar edx, 4
mov eax, edx
shr eax, 0x1f
add eax, edx
jne 0x4118a0
mov byte [esp + 0x1cc], 6
cmp dword [esp + 0xb8], ebp
jb 0x4117f5
mov ecx, dword [esp + 0xa4]
push ecx
call fcn.00421b49
add esp, 4
mov dword [esp + 0xb8], edi
mov dword [esp + 0xb4], ebx
mov byte [esp + 0xa4], bl
mov byte [esp + 0x1cc], 1
cmp dword [esp + 0x9c], ebp
jb 0x41182b
mov edx, dword [esp + 0x88]
push edx
call fcn.00421b49
add esp, 4
mov dword [esp + 0x9c], edi
mov dword [esp + 0x98], ebx
mov byte [esp + 0x88], bl
mov byte [esp + 0x1cc], bl
cmp dword [esp + 0x1ec], ebp
jb 0x411860
mov eax, dword [esp + 0x1d8]
push eax
call fcn.00421b49
add esp, 4
mov dword [esp + 0x1ec], edi
mov dword [esp + 0x1e8], ebx
mov byte [esp + 0x1d8], bl
mov dword [esp + 0x1cc], 0xffffffff
cmp dword [esp + 0x208], ebp
jb 0x411899
mov ecx, dword [esp + 0x1f4]
push ecx
call fcn.00421b49
add esp, 4
xor al, al
jmp 0x411c5d
mov ebp, dword [esi + 0xe4]
cmp ebp, dword [esi + 0xe8]
jbe 0x4118b3
call fcn.004408d8
mov eax, dword [esi + 0xe8]
mov edi, dword [esi + 0xd8]
mov dword [esp + 0x18], edi
mov dword [esp + 0x1c], ebp
mov dword [esp + 0x50], eax
cmp dword [esi + 0xe4], eax
jbe 0x4118d8
call fcn.004408d8
cmp dword [esp + 0x9c], 0x10
mov edx, dword [esi + 0xd8]
mov eax, dword [esp + 0x88]
mov dword [esp + 0x54], edx
jae 0x4118fa
lea eax, [esp + 0x88]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
cmp dword [esp + 0x9c], 0x10
mov eax, dword [esp + 0x88]
jae 0x411919
lea eax, [esp + 0x88]
push ebx
push 0x80
push 2
push ebx
push ebx
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [esp + 0x20], eax
cmp eax, 0xffffffff
je 0x411b52
lea esp, [esp]
cmp edi, ebx
je 0x41194a
cmp edi, dword [esp + 0x54]
je 0x41194f
call fcn.004408d8
cmp ebp, dword [esp + 0x50]
je 0x411b0e
mov dword [esp + 0x74], 0xf
mov dword [esp + 0x70], ebx
mov byte [esp + 0x60], bl
mov byte [esp + 0x1cc], 0xe
cmp edi, ebx
jne 0x411b03
call fcn.004408d8
xor eax, eax
cmp ebp, dword [eax + 0x10]
jb 0x41198a
call fcn.004408d8
push 0xffffffffffffffff
push ebx
push ebp
lea ecx, [esp + 0x68]
call fcn.00401cc0
cmp dword [esp + 0x74], 0x10
mov eax, dword [esp + 0x4c]
mov dword [esp + 0x78], eax
mov eax, dword [esp + 0x60]
jae 0x4119ae
lea eax, [esp + 0x60]
push ebx
push 0x80
push 3
push ebx
push 1
push SysReAllocString
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebp, eax
cmp ebp, 0xffffffff
je 0x411ac4
push ebx
push ebp
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
lea ecx, [esi + 1]
push ecx
call fcn.00442266
add esp, 4
push ebx
lea edx, [esp + 0x30]
push edx
push esi
mov edi, eax
push edi
push ebp
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x20]
push 2
push ebx
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov edx, dword [esp + 0x20]
push ebx
lea ecx, [esp + 0x30]
push ecx
push esi
push edi
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
push edi
call fcn.00442189
mov eax, dword [esp + 0x2c]
mov dword [esp + 0x80], eax
add eax, esi
add esp, 4
cmp dword [esp + 0x74], 0x10
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x60]
mov dword [esp + 0x80], esi
jae 0x411a49
lea eax, [esp + 0x60]
mov esi, dword [esp + 0x24]
push eax
mov ecx, esi
call fcn.00412800
mov dword [esp + 0x14], eax
lea eax, [esp + 0x14]
push eax
lea ecx, [esi + 0x28]
call fcn.0040ff60
push 0xffffffffffffffff
push ebx
lea ecx, [esp + 0x64]
mov esi, eax
push ecx
mov ecx, esi
call fcn.00401cc0
mov edx, dword [esp + 0x78]
push 1
push ebx
mov dword [esi + 0x1c], edx
mov eax, dword [esp + 0x84]
push ebx
mov dword [esi + 0x20], eax
mov ecx, dword [esp + 0x8c]
push ebx
lea edx, [esp + 0x40]
push edx
mov dword [esi + 0x24], ecx
call dword [sym.imp.USER32.dll_PeekMessageA]
cmp eax, ebx
je 0x411abc
lea eax, [esp + 0x30]
push eax
call dword [sym.imp.USER32.dll_TranslateMessage]
lea ecx, [esp + 0x30]
push ecx
call dword [sym.imp.USER32.dll_DispatchMessageA]
mov esi, dword [esp + 0x24]
mov edi, dword [esp + 0x18]
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov byte [esp + 0x1cc], 0xb
lea ecx, [esp + 0x5c]
call fcn.0040e480
cmp edi, ebx
jne 0x411b0a
call fcn.004408d8
xor eax, eax
mov edx, dword [esp + 0x1c]
cmp edx, dword [eax + 0x10]
jb 0x411af5
call fcn.004408d8
add dword [esp + 0x1c], 0x1c
mov ebp, dword [esp + 0x1c]
jmp 0x411940
mov eax, dword [edi]
jmp 0x411980
mov eax, dword [edi]
jmp 0x411ae7
sub esp, 0x1c
mov ecx, esp
mov dword [esp + 0x30], esp
push 0xffffffffffffffff
push ebx
lea eax, [esp + 0xc4]
mov edi, 0xf
mov dword [ecx + 0x18], edi
mov dword [ecx + 0x14], ebx
push eax
mov byte [ecx + 4], bl
call fcn.00401cc0
mov byte [esp + 0x1e8], 0xf
mov byte [esp + 0x1e8], 0xb
mov ecx, esi
call fcn.0040e710
mov eax, dword [esp + 0x20]
jmp 0x411b57
mov edi, 0xf
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [esp + 0xbc]
push ecx
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
mov edx, dword [esi + 0x40]
mov eax, dword [edx + 4]
add esi, 0x28
push eax
mov ecx, esi
call fcn.0040ef10
mov eax, dword [esi + 0x18]
mov dword [eax + 4], eax
mov eax, dword [esi + 0x18]
mov dword [esi + 0x1c], ebx
mov dword [eax], eax
mov esi, dword [esi + 0x18]
mov dword [esi + 8], esi
mov byte [esp + 0x1cc], 6
mov esi, 0x10
cmp dword [esp + 0xb8], esi
jb 0x411bb7
mov ecx, dword [esp + 0xa4]
push ecx
call fcn.00421b49
add esp, 4
mov dword [esp + 0xb8], edi
mov dword [esp + 0xb4], ebx
mov byte [esp + 0xa4], bl
mov byte [esp + 0x1cc], 1
cmp dword [esp + 0x9c], esi
jb 0x411bed
mov edx, dword [esp + 0x88]
push edx
call fcn.00421b49
add esp, 4
mov dword [esp + 0x9c], edi
mov dword [esp + 0x98], ebx
mov byte [esp + 0x88], bl
mov byte [esp + 0x1cc], bl
cmp dword [esp + 0x1ec], esi
jb 0x411c22
mov eax, dword [esp + 0x1d8]
push eax
call fcn.00421b49
add esp, 4
mov dword [esp + 0x1ec], edi
mov dword [esp + 0x1e8], ebx
mov byte [esp + 0x1d8], bl
mov dword [esp + 0x1cc], 0xffffffff
cmp dword [esp + 0x208], esi
jb 0x411c5b
mov ecx, dword [esp + 0x1f4]
push ecx
call fcn.00421b49
add esp, 4
mov al, 1
mov byte [esp + 0x1f4], bl
mov dword [esp + 0x204], ebx
mov dword [esp + 0x208], edi
mov ecx, dword [esp + 0x1c4]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x1ac]
xor ecx, esp
call fcn.0044014d
add esp, 0x1bc
ret 0x38