Function at 0x410260
Capabilities:
Get file size
Read file on windows

Disassembly:
sub esp, 8
push ebx
push ebp
mov ebx, ecx
mov al, byte [ebx + 0x38]
test al, al
push esi
push edi
je 0x41037d
mov eax, dword [ebx + 0x34]
mov edi, 0x10
cmp eax, edi
jb 0x410285
mov ecx, dword [ebx + 0x20]
jmp 0x410288
lea ecx, [ebx + 0x20]
cmp dword [ebx + 0x18], edi
jb 0x410292
mov eax, dword [ebx + 4]
jmp 0x410295
lea eax, [ebx + 4]
mov esi, dword [esp + 0x24]
mov ebp, dword [esp + 0x1c]
push ecx
push eax
push esi
push 0x41fd68
push ebp
call fcn.00414a74
mov eax, esi
add esp, 0x14
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4102b3
mov ecx, dword [ebx + 0x30]
sub eax, edx
add ecx, dword [ebx + 0x14]
lea esi, [ecx + eax + 0x3c]
cmp dword [ebx + 0x34], edi
mov dword [esp + 0x14], esi
jb 0x4102d4
mov ebx, dword [ebx + 0x20]
jmp 0x4102d7
add ebx, 0x20
push 0
push 0x80
push 3
push 0
push 1
push SysReAllocString
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
test edi, edi
je 0x41047f
cmp edi, 0xffffffff
je 0x41047f
push 0
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
lea ebx, [esi + ebp]
mov ebp, dword [sym.imp.KERNEL32.dll_ReadFile]
xor esi, esi
push esi
lea edx, [esp + 0x28]
push edx
push 0x400
push ebx
push edi
mov dword [esp + 0x24], eax
mov dword [esp + 0x38], esi
call ebp
test eax, eax
je 0x410359
mov eax, dword [esp + 0x24]
test eax, eax
jbe 0x410359
cmp esi, dword [esp + 0x10]
ja 0x410359
push 0
add esi, eax
lea eax, [esp + 0x28]
push eax
push 0x400
lea ecx, [esi + ebx]
push ecx
push edi
call ebp
test eax, eax
jne 0x410332
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x1c]
add esi, edx
push edi
mov word [esi + eax], 0xa0d
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
lea eax, [esi + 2]
pop esi
pop ebp
pop ebx
add esp, 8
ret 0xc
mov eax, dword [ebx + 0x3c]
test eax, eax
je 0x41041b
mov eax, dword [ebx + 0x40]
test eax, eax
je 0x41041b
mov eax, dword [ebx + 0x34]
mov edi, 0x10
cmp eax, edi
jb 0x4103a4
mov ecx, dword [ebx + 0x20]
jmp 0x4103a7
lea ecx, [ebx + 0x20]
cmp dword [ebx + 0x18], edi
jb 0x4103b1
mov eax, dword [ebx + 4]
jmp 0x4103b4
lea eax, [ebx + 4]
mov esi, dword [esp + 0x24]
mov ebp, dword [esp + 0x1c]
push ecx
push eax
push esi
push 0x41fd68
push ebp
call fcn.00414a74
mov eax, esi
add esp, 0x14
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4103d2
mov esi, dword [ebx + 0x14]
mov ecx, dword [ebx + 0x30]
add ecx, esi
mov esi, dword [ebx + 0x3c]
sub eax, edx
lea eax, [ecx + eax + 0x3c]
mov ecx, dword [ebx + 0x40]
mov edx, ecx
shr ecx, 2
lea edi, [eax + ebp]
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edx, dword [ebx + 0x40]
lea ecx, [eax + ebp]
pop edi
pop esi
mov word [ecx + edx], 0xa0d
mov ecx, dword [ebx + 0x40]
pop ebp
lea eax, [eax + ecx + 2]
pop ebx
add esp, 8
ret 0xc
mov eax, dword [ebx + 0x34]
mov edi, 0x10
cmp eax, edi
jb 0x41042c
mov ecx, dword [ebx + 0x20]
jmp 0x41042f
lea ecx, [ebx + 0x20]
cmp dword [ebx + 0x18], edi
jb 0x410439
mov eax, dword [ebx + 4]
jmp 0x41043c
lea eax, [ebx + 4]
mov esi, dword [esp + 0x24]
mov edx, dword [esp + 0x1c]
push ecx
push eax
push esi
push 0x41fd2c
push edx
call fcn.00414a74
mov eax, esi
add esp, 0x14
lea edx, [eax + 1]
lea ebx, [ebx]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x410460
mov ecx, dword [ebx + 0x30]
pop edi
sub eax, edx
mov edx, dword [ebx + 0x14]
pop esi
add ecx, edx
pop ebp
lea eax, [ecx + eax + 0x31]
pop ebx
add esp, 8
ret 0xc
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 8
ret 0xc