Function at 0x404381
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x38
mov eax, dword [0x4282e0]
xor eax, esp
mov dword [esp + 0x34], eax
mov eax, dword [esp + 0x40]
push ebx
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x48]
push 0x30032
mov dword [esp + 8], eax
call fcn.00409a80
mov ebx, eax
pop ecx
test ebx, ebx
jne 0x4043b9
or eax, 0xffffffff
jmp 0x40469f
push edi
push ebx
push dword [esp + 0x48]
call fcn.00403e67
pop ecx
pop ecx
mov ecx, eax
mov dword [esp + 0xc], eax
and ecx, edx
mov dword [esp + 0x10], edx
or edi, 0xffffffff
cmp ecx, edi
jne 0x4043e5
push ebx
call fcn.00409a48
pop ecx
jmp 0x40469c
push esi
mov eax, 0x400
push eax
push ebx
push dword [esp + 0x50]
call fcn.0041702b
mov esi, eax
add esp, 0xc
test esi, esi
jns 0x40440b
push ebx
call fcn.00409a48
pop ecx
jmp 0x40469b
movzx ecx, byte [ebx + 3]
movzx eax, byte [ebx + 2]
shl ecx, 8
or ecx, eax
movzx eax, byte [ebx + 1]
shl ecx, 8
push ebp
or ecx, eax
mov ebp, ebx
movzx eax, byte [ebx]
jmp 0x40452e
cmp esi, 0x2e
jge 0x40445b
push esi
push ebp
push ebx
call fcn.0040c910
mov ebp, eax
lea ecx, [esi + ebx]
mov eax, 0x400
push eax
push ecx
push dword [esp + 0x60]
call fcn.0041702b
add esp, 0x18
test eax, eax
jle 0x404693
add esi, eax
movzx edx, byte [ebp + 0x21]
movzx eax, byte [ebp + 0x20]
movzx ecx, byte [ebp + 0x1f]
shl edx, 8
or edx, eax
shl ecx, 8
movzx eax, byte [ebp + 0x1e]
or ecx, eax
movzx eax, byte [ebp + 0x1c]
add edx, ecx
movzx ecx, byte [ebp + 0x1d]
shl ecx, 8
or eax, ecx
add eax, 0x2e
add eax, edx
mov dword [esp + 0x20], eax
add eax, 4
cmp esi, eax
jge 0x4044d3
cmp ebp, ebx
je 0x4044a5
push esi
push ebp
push ebx
call fcn.0040c910
add esp, 0xc
mov ebp, eax
mov eax, dword [esp + 0x20]
mov ecx, 0x400
sub eax, esi
add eax, 4
cmp eax, ecx
cmovl eax, ecx
push eax
lea eax, [esi + ebx]
push eax
push dword [esp + 0x54]
call fcn.0041702b
add esp, 0xc
test eax, eax
jle 0x404693
add esi, eax
push dword [esp + 0x10]
call fcn.00409940
movzx edx, byte [ebp + 0x1d]
pop ecx
movzx ecx, byte [ebp + 0x1c]
shl edx, 8
or edx, ecx
cmp edx, eax
jne 0x40450c
push dword [esp + 0x10]
call fcn.00409940
push eax
push dword [esp + 0x18]
lea eax, [ebp + 0x2e]
push eax
call fcn.0040b192
add esp, 0x10
test eax, eax
je 0x404544
add ebp, dword [esp + 0x20]
sub esi, dword [esp + 0x20]
movzx ecx, byte [ebp + 3]
movzx eax, byte [ebp + 2]
shl ecx, 8
or ecx, eax
movzx eax, byte [ebp + 1]
shl ecx, 8
or ecx, eax
movzx eax, byte [ebp]
shl ecx, 8
or ecx, eax
cmp ecx, 0x2014b50
je 0x40442c
jmp 0x404693
movzx ecx, byte [ebp + 0x2d]
movzx eax, byte [ebp + 0x2c]
shl ecx, 8
or ecx, eax
movzx eax, byte [ebp + 0x2b]
shl ecx, 8
or ecx, eax
movzx eax, byte [ebp + 0x2a]
shl ecx, 8
or ecx, eax
xor eax, eax
add ecx, dword [esp + 0x14]
push 0
adc eax, dword [esp + 0x1c]
push eax
push ecx
push dword [esp + 0x58]
call fcn.0040d0d0
add esp, 0x10
test edx, edx
jg 0x40458f
jl 0x404693
test eax, eax
jb 0x404693
push 0x1e
lea eax, [esp + 0x28]
push eax
push dword [esp + 0x54]
call fcn.0041702b
add esp, 0xc
test eax, eax
js 0x404693
movzx ecx, byte [esp + 0x27]
movzx eax, byte [esp + 0x26]
shl ecx, 8
or ecx, eax
movzx eax, byte [esp + 0x25]
shl ecx, 8
or ecx, eax
movzx eax, byte [esp + 0x24]
shl ecx, 8
or ecx, eax
cmp ecx, 0x4034b50
jne 0x404693
movzx ecx, byte [ebp + 0x1b]
xor esi, esi
movzx eax, byte [ebp + 0x1a]
mov edx, dword [esp + 0x1c]
shl ecx, 8
or ecx, eax
movzx eax, byte [ebp + 0x19]
shl ecx, 8
or ecx, eax
movzx eax, byte [ebp + 0x18]
shl ecx, 8
or ecx, eax
mov dword [edx], ecx
movzx ecx, byte [ebp + 0x17]
movzx eax, byte [ebp + 0x16]
shl ecx, 8
or ecx, eax
movzx eax, byte [ebp + 0x15]
shl ecx, 8
or ecx, eax
movzx eax, byte [ebp + 0x14]
shl ecx, 8
or ecx, eax
mov dword [edx + 4], ecx
movzx edi, byte [ebp + 0x2d]
movzx eax, byte [ebp + 0x2c]
movzx ecx, byte [esp + 0x3e]
shl edi, 8
or edi, eax
movzx eax, byte [ebp + 0x2b]
shl edi, 8
or edi, eax
movzx eax, byte [ebp + 0x2a]
shl edi, 8
or edi, eax
movzx eax, byte [esp + 0x3f]
shl eax, 8
or eax, ecx
movzx ecx, byte [esp + 0x40]
cdq
add edi, eax
movzx eax, byte [esp + 0x41]
adc esi, edx
shl eax, 8
or eax, ecx
cdq
add edi, eax
adc esi, edx
add edi, dword [esp + 0x14]
mov edx, dword [esp + 0x1c]
adc esi, dword [esp + 0x18]
add edi, 0x1e
adc esi, 0
mov dword [edx + 8], edi
mov dword [edx + 0xc], esi
movzx ecx, byte [ebp + 0xb]
movzx eax, byte [ebp + 0xa]
shl ecx, 8
or ecx, eax
xor edi, edi
mov dword [edx + 0x10], ecx
push ebx
call fcn.00409a48
pop ecx
pop ebp
pop esi
mov eax, edi
pop edi
mov ecx, dword [esp + 0x38]
pop ebx
xor ecx, esp
call fcn.0040b10c
add esp, 0x38
ret