Function at 0x100e2250
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x1c
push ebx
push ebp
push esi
mov esi, dword [esp + 0x30]
push edi
xor edi, edi
push 0x10230110
push esi
mov dword [esp + 0x28], edi
mov dword [esp + 0x2c], edi
mov dword [esp + 0x30], edi
mov dword [esp + 0x18], edi
xor ebp, ebp
call fcn.10106a11
mov ebx, eax
add esp, 8
mov dword [esp + 0x18], ebx
cmp ebx, edi
jne 0x100e2298
push esi
call fcn.1010e40d
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c
ret
push ebx
call fcn.10108311
add esp, 4
cmp eax, 0x50
jne 0x100e2504
push ebx
call fcn.10108311
add esp, 4
cmp eax, 0x35
jne 0x100e2504
lea esp, [esp]
cmp edi, 3
jge 0x100e2356
push ebx
call fcn.10108311
mov esi, eax
add esp, 4
cmp esi, 0xffffffff
je 0x100e234d
cmp esi, 0x23
jne 0x100e22e8
mov dword [esp + 0x10], 1
jmp 0x100e22c0
cmp esi, 0xa
jne 0x100e22f7
mov dword [esp + 0x10], 0
jmp 0x100e22fe
cmp dword [esp + 0x10], 0
jne 0x100e22c0
push esi
call fcn.101093a2
add esp, 4
test eax, eax
je 0x100e2312
mov ebp, 1
jmp 0x100e2316
test ebp, ebp
je 0x100e22c0
push esi
call fcn.101093a2
add esp, 4
test eax, eax
je 0x100e2334
mov eax, dword [esp + edi*4 + 0x20]
lea eax, [eax + eax*4]
lea ecx, [esi + eax*2 - 0x30]
mov dword [esp + edi*4 + 0x20], ecx
jmp 0x100e22c0
push esi
call fcn.101094a7
add esp, 4
test eax, eax
je 0x100e2500
xor ebp, ebp
inc edi
jmp 0x100e22c0
cmp edi, 3
jl 0x100e2500
mov esi, dword [esp + 0x30]
movzx eax, word [esi + 0x6602]
cmp dword [esp + 0x20], eax
jne 0x100e24f4
movzx edx, word [esi + 0x6600]
cmp dword [esp + 0x24], edx
jne 0x100e24f4
cmp dword [esp + 0x28], 0xffff
jne 0x100e24f4
push 2
push eax
call fcn.1010d964
mov edi, eax
push str.subtract__
push edi
push esi
mov dword [esp + 0x28], edi
call fcn.100d80b0
xor ebp, ebp
xor eax, eax
add esp, 0x14
mov dword [esp + 0x10], ebp
cmp ax, word [esi + 0x6600]
jae 0x100e24d3
lea esp, [esp]
movzx ecx, word [esi + 0x6602]
push ebx
push ecx
push 2
push edi
call fcn.101088d1
xor edx, edx
add esp, 0x10
xor ebx, ebx
cmp dx, word [esi + 0x6602]
jae 0x100e24bb
mov eax, ebp
and eax, 7
add eax, eax
mov dword [esp + 0x1c], eax
jmp 0x100e23f6
mov eax, dword [esp + 0x1c]
movzx ecx, word [esi + 0x6608]
sar ebp, cl
mov edi, ebx
and edi, 1
add edi, eax
movzx eax, word [esi + 0x660c]
imul ebp, eax
mov eax, dword [esi + 0x6580]
mov edx, ebx
sar edx, cl
add edi, edi
mov ecx, edi
shr eax, cl
add ebp, edx
mov edx, dword [esi + 0x6630]
and eax, 3
lea ecx, [eax + ebp*4]
mov eax, dword [esp + 0x14]
lea ebp, [edx + ecx*2]
movzx ecx, word [eax + ebx*2]
push ecx
call dword [sym.imp.WS2_32.dll_ntohs]
movzx edx, ax
movzx eax, word [ebp]
sub eax, edx
test eax, eax
jle 0x100e249d
movzx ecx, word [esi + 0x6608]
mov edx, dword [esp + 0x10]
movzx eax, word [esi + 0x660c]
sar edx, cl
imul edx, eax
mov eax, ebx
sar eax, cl
mov ecx, edi
add edx, eax
mov eax, dword [esi + 0x6580]
shr eax, cl
and eax, 3
lea ecx, [eax + edx*4]
mov edx, dword [esi + 0x6630]
mov eax, dword [esp + 0x14]
lea ebp, [edx + ecx*2]
movzx ecx, word [eax + ebx*2]
push ecx
call dword [sym.imp.WS2_32.dll_ntohs]
movzx edx, ax
movzx eax, word [ebp]
sub eax, edx
jmp 0x100e249f
xor eax, eax
mov word [ebp], ax
movzx eax, word [esi + 0x6602]
mov ebp, dword [esp + 0x10]
inc ebx
cmp ebx, eax
jl 0x100e23f2
mov edi, dword [esp + 0x14]
movzx ecx, word [esi + 0x6600]
mov ebx, dword [esp + 0x18]
inc ebp
cmp ebp, ecx
mov dword [esp + 0x10], ebp
jl 0x100e23c0
push ebx
call fcn.10106b5b
push edi
call fcn.10109eb5
add esp, 8
pop edi
mov dword [esi + 0x65c8], 0
pop esi
pop ebp
pop ebx
add esp, 0x1c
ret
mov edx, dword [esp + 0x34]
push edx
push str._s_has_the_wrong_dimensions__n
jmp 0x100e250a
mov esi, dword [esp + 0x34]
push esi
push str._s_is_not_a_valid_PGM_file__n
call fcn.10107014
add eax, 0x40
push eax
call fcn.10106bd7
push ebx
call fcn.10106b5b
add esp, 0x10
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c
ret