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

Disassembly:
sub esp, 0x11c
push ebx
push ebp
push esi
push edi
mov edi, 0x684c14
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x28]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov byte [esp + 0x28], 0
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
mov ebp, dword [esp + 0x130]
and ecx, 3
lea edx, [esp + 0x28]
rep movsb byte es:[edi], byte [esi]
mov edi, ebp
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push eax
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
push 0x80
push 3
mov ecx, ebx
push eax
push eax
and ecx, 3
lea eax, [esp + 0x3c]
push closesocket
rep movsb byte es:[edi], byte [esi]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x40c57b
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push ebp
lea esi, [eax - 2]
push 0x33b
push 0x4255c8
push esi
call fcn.00415350
mov edi, eax
add esp, 0x10
test edi, edi
jne 0x40c49c
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x11c
ret
mov edx, dword [esp + 0x134]
mov ebp, dword [sym.imp.KERNEL32.dll_ReadFile]
lea ecx, [esp + 0x20]
push 0
push ecx
push 2
push edx
push ebx
call ebp
lea eax, [esp + 0x20]
push 0
push eax
push esi
push edi
push ebx
call ebp
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [esp + 0x134]
mov ebp, dword [esp + 0x130]
xor ecx, ecx
push ebp
mov cx, word [edx]
push 0x340
shl ecx, 2
push 0x4255c8
push ecx
call fcn.00415350
add esp, 0x10
mov dword [esp + 0x14], eax
test eax, eax
jne 0x40c503
push ebp
push 0x341
jmp 0x40c56d
mov edx, dword [esp + 0x134]
xor eax, eax
xor esi, esi
xor ecx, ecx
mov ax, word [edx]
test eax, eax
jbe 0x40c542
mov ebp, eax
mov dx, word [ecx + edi]
mov ax, word [edi + ecx + 2]
and eax, 0xffff
and edx, 0xffff
imul eax, edx
dec ebp
lea ecx, [ecx + eax + 4]
lea esi, [esi + eax*2 + 4]
jne 0x40c519
mov ebp, dword [esp + 0x130]
push ebp
push 0x34a
push 0x4255c8
push esi
call fcn.00415350
xor edx, edx
add esp, 0x10
cmp eax, edx
mov dword [esp + 0x24], eax
jne 0x40c588
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebp
push 0x34b
push 0x4255c8
push edi
call fcn.00415390
add esp, 0x10
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x11c
ret
mov ecx, dword [esp + 0x134]
xor esi, esi
mov dword [esp + 0x18], edx
cmp word [ecx], dx
jbe 0x40c668
mov ecx, dword [esp + 0x14]
mov dword [esp + 0x10], ecx
mov ecx, dword [esp + 0x10]
lea ebp, [eax + esi]
add edx, 4
add esi, 4
mov dword [ecx], ebp
mov cx, word [edx + edi - 4]
mov bx, word [edi + edx - 2]
mov word [ebp], cx
mov word [eax + esi - 2], bx
and ebx, 0xffff
and ecx, 0xffff
imul ebx, ecx
test ebx, ebx
jbe 0x40c638
mov dword [esp + 0x1c], ebx
movzx cx, byte [edx + edi]
mov eax, dword [0x6955f4]
mov ebp, dword [0x425690]
lea ecx, [ecx + ecx*2]
xor ebx, ebx
and ecx, 0xffff
add esi, 2
add ecx, eax
xor eax, eax
mov al, byte [ecx + 2]
mov bl, byte [ecx + 1]
mov bp, word [ebp + eax*4]
mov eax, dword [0x42568c]
or bp, word [eax + ebx*4]
xor eax, eax
mov al, byte [ecx]
mov ecx, dword [0x425688]
or bp, word [ecx + eax*4]
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x1c]
inc edx
mov word [eax + esi - 2], bp
dec ecx
mov dword [esp + 0x1c], ecx
jne 0x40c5df
mov ebx, dword [esp + 0x10]
mov ebp, dword [esp + 0x134]
mov ecx, dword [esp + 0x18]
add ebx, 4
mov dword [esp + 0x10], ebx
xor ebx, ebx
mov bx, word [ebp]
inc ecx
cmp ecx, ebx
mov dword [esp + 0x18], ecx
jb 0x40c5a6
mov ebp, dword [esp + 0x130]
push ebp
push 0x35e
push 0x4255c8
push edi
call fcn.00415390
mov eax, dword [esp + 0x24]
add esp, 0x10
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x11c
ret