Function at 0x40e4e0
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 0x40e5fd
mov eax, dword [ebx + 0x34]
mov edi, 0x10
cmp eax, edi
jb 0x40e505
mov ecx, dword [ebx + 0x20]
jmp 0x40e508
lea ecx, [ebx + 0x20]
cmp dword [ebx + 0x18], edi
jb 0x40e512
mov eax, dword [ebx + 4]
jmp 0x40e515
lea eax, [ebx + 4]
mov esi, dword [esp + 0x24]
mov ebp, dword [esp + 0x1c]
push ecx
push eax
push esi
push str.___s_r_nContent_Disposition:_form_data__name__s___filename__s__r_n_r_n
push ebp
call fcn.00412cf4
mov eax, esi
add esp, 0x14
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x40e533
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 0x40e554
mov ebx, dword [ebx + 0x20]
jmp 0x40e557
add ebx, 0x20
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
test edi, edi
je 0x40e6ff
cmp edi, 0xffffffff
je 0x40e6ff
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 0x40e5d9
mov eax, dword [esp + 0x24]
test eax, eax
jbe 0x40e5d9
cmp esi, dword [esp + 0x10]
ja 0x40e5d9
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 0x40e5b2
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 0x40e69b
mov eax, dword [ebx + 0x40]
test eax, eax
je 0x40e69b
mov eax, dword [ebx + 0x34]
mov edi, 0x10
cmp eax, edi
jb 0x40e624
mov ecx, dword [ebx + 0x20]
jmp 0x40e627
lea ecx, [ebx + 0x20]
cmp dword [ebx + 0x18], edi
jb 0x40e631
mov eax, dword [ebx + 4]
jmp 0x40e634
lea eax, [ebx + 4]
mov esi, dword [esp + 0x24]
mov ebp, dword [esp + 0x1c]
push ecx
push eax
push esi
push str.___s_r_nContent_Disposition:_form_data__name__s___filename__s__r_n_r_n
push ebp
call fcn.00412cf4
mov eax, esi
add esp, 0x14
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x40e652
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 0x40e6ac
mov ecx, dword [ebx + 0x20]
jmp 0x40e6af
lea ecx, [ebx + 0x20]
cmp dword [ebx + 0x18], edi
jb 0x40e6b9
mov eax, dword [ebx + 4]
jmp 0x40e6bc
lea eax, [ebx + 4]
mov esi, dword [esp + 0x24]
mov edx, dword [esp + 0x1c]
push ecx
push eax
push esi
push str.___s_r_nContent_Disposition:_form_data__name__s__r_n_r_n_s_r_n
push edx
call fcn.00412cf4
mov eax, esi
add esp, 0x14
lea edx, [eax + 1]
lea ebx, [ebx]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x40e6e0
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