Function at 0x5007e0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x26c
mov eax, dword [0x641a90]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
lea eax, [ebp - 0x264]
push esi
mov esi, dword [ebp + 0xc]
push dword [ebx]
push 1
push 2
push eax
call fcn.00595b79
add esp, 0x10
test eax, eax
jne 0x500829
pop esi
mov eax, 4
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005920c1
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x264]
mov ecx, 0x4d4d
cmp ax, cx
je 0x500858
mov ecx, 0x4949
cmp ax, cx
je 0x500858
pop esi
mov eax, 2
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005920c1
mov esp, ebp
pop ebp
ret
push dword [ebx]
lea eax, [ebp - 0x262]
push 1
push 2
push eax
call fcn.00595b79
add esp, 0x10
test eax, eax
je 0x500814
mov ax, word [ebp - 0x262]
mov ecx, 0x2a00
cmp ax, cx
je 0x500888
cmp ax, 0x2a
jne 0x500843
push dword [ebx]
lea eax, [ebp - 0x260]
push 1
push 4
push eax
call fcn.00595b79
add esp, 0x10
test eax, eax
je 0x500843
push 0xec
lea eax, [ebp - 0xf0]
push 0
push eax
call fcn.00595760
lea eax, [ebp - 0xf0]
push eax
push dword [ebp - 0x264]
call fcn.00504110
add esp, 0x14
test ax, ax
je 0x500843
lea eax, [ebp - 0x258]
push edi
push eax
call fcn.00457d90
xor eax, eax
mov dword [ebp - 0x240], 0x10001
mov word [ebp - 0x254], ax
add esp, 4
mov eax, 2
mov dword [ebp - 0xe8], 0x10001
mov word [ebp - 0xa0], ax
mov edi, 1
xor eax, eax
mov dword [ebp - 0xe0], edi
mov word [ebp - 0x58], ax
mov dword [ebp - 0xc4], eax
mov dword [ebp - 0xc8], eax
mov word [ebp - 0x80], ax
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x234], eax
mov dword [ebp - 0x230], eax
lea eax, [ebp - 0x258]
push eax
push esi
lea eax, [ebp - 0xf0]
mov dword [ebp - 0xd4], 0
push eax
push dword [ebp - 0x260]
mov dword [ebp - 0x64], 0
mov dword [ebp - 0x78], 0
mov dword [ebp - 0xac], 0x10001
mov dword [ebp - 0xa4], 0
mov dword [ebp - 0xa8], 0x10001
mov dword [ebp - 0x74], 0x3e991687
mov dword [ebp - 0x70], 0x3f1645a2
mov dword [ebp - 0x6c], 0x3de978d5
mov dword [ebp - 0x68], 0
mov dword [ebp - 0x60], 0
mov dword [ebp - 0xcc], 0
mov dword [ebp - 0xe4], 0x10000
mov dword [ebp - 0x94], edi
mov dword [ebp - 0x98], 0xffffffff
mov dword [ebp - 0x7e], 0x10001
mov dword [ebp - 0x5c], 0xffffffff
mov dword [ebp - 0x90], 0xffffffff
call dword [ebp - 0xb0]
add esp, 4
push eax
push ebx
call fcn.00502bd0
add esp, 0x14
test al, al
je 0x5010e4
mov ax, word [ebp - 0xac]
mov ecx, 0x8005
mov edx, 0x80b2
cmp ax, di
je 0x500a6d
cmp ax, 2
je 0x500a6d
cmp ax, 3
je 0x500a6d
cmp ax, 4
je 0x500a6d
cmp ax, cx
je 0x500a6d
cmp ax, 7
je 0x500a6d
cmp ax, 5
je 0x500a6d
mov ecx, 0x8775
cmp ax, cx
je 0x500a6d
mov ecx, 0x8774
cmp ax, cx
je 0x500a6d
cmp ax, dx
je 0x500a6d
cmp ax, 8
je 0x500a6d
mov ecx, 0x8029
cmp ax, cx
je 0x500a6d
cmp ax, 6
je 0x500a77
jmp 0x500a7f
cmp ax, 6
jne 0x500b0a
mov ecx, dword [ebp - 0x5c]
cmp ecx, 0xffffffff
jne 0x500ad8
cmp dword [ebp - 0x10], 0
je 0x500a9b
pop edi
pop esi
mov eax, 2
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005920c1
mov esp, ebp
pop ebp
ret
movdqu xmm0, xmmword [str.TIFF_:_Bad_data_compression_algorithm__]
pop edi
mov eax, 9
movdqu xmmword [esi + 0x44], xmm0
movdqu xmm0, xmmword [0x5eddf8]
movdqu xmmword [esi + 0x54], xmm0
movq xmm0, qword [0x5ede08]
movq qword [esi + 0x64], xmm0
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005920c1
mov esp, ebp
pop ebp
ret
cmp ax, 6
jne 0x500b0a
push 0
push ecx
push dword [ebx]
call fcn.00595cb4
push 0
push str.TIFF__jpeg_
push esi
push ebx
call fcn.0047a8d0
add esp, 0x1c
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005920c1
mov esp, ebp
pop ebp
ret
mov ax, word [ebp - 0xa8]
mov ecx, 0x804d
lea edx, [ecx - 1]
test ax, ax
je 0x500b89
cmp ax, 1
je 0x500b89
cmp ax, 2
je 0x500b89
cmp ax, 3
je 0x500b89
cmp ax, 5
je 0x500b89
cmp ax, 8
je 0x500b89
cmp ax, 6
je 0x500b89
cmp ax, cx
je 0x500b89
cmp ax, dx
je 0x500b89
movdqu xmm0, xmmword [str.TIFF_:_Bad_photometric_interpretation__]
pop edi
mov eax, 9
movdqu xmmword [esi + 0x44], xmm0
movdqu xmm0, xmmword [0x5ede2c]
movdqu xmmword [esi + 0x54], xmm0
movq xmm0, qword [0x5ede3c]
movq qword [esi + 0x64], xmm0
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005920c1
mov esp, ebp
pop ebp
ret
call fcn.0045bc00
test al, al
jne 0x500be6
cmp word [ebp - 0xac], 5
jne 0x500be6
movdqu xmm0, xmmword [str.TIFF_:_Bad_compression__LZW___]
pop edi
movdqu xmmword [esi + 0x44], xmm0
movq xmm0, qword [0x5ede54]
movq qword [esi + 0x54], xmm0
mov eax, dword [0x5ede5c]
mov dword [esi + 0x5c], eax
mov ax, word [0x5ede60]
mov word [esi + 0x60], ax
mov al, byte [0x5ede62]
mov byte [esi + 0x62], al
mov eax, 9
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005920c1
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x64]
test eax, eax
je 0x500c33
push 0
push eax
push dword [ebx]
call fcn.00595cb4
mov edi, dword [ebp - 0x68]
push edi
call fcn.00593e38
add esp, 0x10
mov dword [ebp - 0x60], eax
test eax, eax
jne 0x500c20
pop edi
pop esi
mov eax, 1
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005920c1
mov esp, ebp
pop ebp
ret
push dword [ebx]
push 1
push edi
push eax
call fcn.00595b79
add esp, 0x10
mov edi, 1
lea eax, [ebp - 0xf0]
push eax
push ebx
call fcn.00501140
mov eax, dword [ebp - 0x78]
add esp, 8
test eax, eax
je 0x500c5e
push dword [ebp - 0xb0]
lea ecx, [ebp - 0x74]
push ecx
push eax
push ebx
call fcn.00500750
add esp, 0x10
mov cx, word [ebp - 0xa8]
mov edx, 6
movzx eax, cx
mov dword [ebp - 0x26c], 7
mov dword [ebp - 0x25c], 8
mov dword [ebp - 0x268], 3
cmp eax, 8
jg 0x500cc4
je 0x500cb1
sub eax, 5
je 0x500c9f
dec eax
jne 0x500cce
lea eax, [edx - 2]
jmp 0x500ce0
or dword [ebp - 0x258], 0x8000
mov eax, dword [ebp - 0x268]
jmp 0x500ce0
or dword [ebp - 0x258], 0x80000
mov word [ebp - 0x216], dx
jmp 0x500ce7
sub eax, 0x804c
je 0x500cda
dec eax
je 0x500cd2
xor eax, eax
jmp 0x500ce0
mov eax, dword [ebp - 0x26c]
jmp 0x500ce0
mov eax, dword [ebp - 0x25c]
mov word [ebp - 0x216], ax
cmp dword [ebp - 0xc8], 0
mov eax, dword [str.TIFF]
mov dword [ebp - 0x172], eax
mov al, byte [0x5c06e0]
mov byte [ebp - 0x16e], al
je 0x500d3c
cmp dword [ebp - 0xc4], 0
je 0x500d3c
lea ecx, [ebp - 0x172]
dec ecx
mov al, byte [ecx + 1]
inc ecx
test al, al
jne 0x500d16
mov eax, dword [str.__Tiled_]
mov dword [ecx], eax
mov eax, dword [0x5ede68]
mov dword [ecx + 4], eax
mov al, byte [0x5ede6c]
mov byte [ecx + 8], al
mov cx, word [ebp - 0xa8]
mov dx, word [ebp - 0xac]
movzx eax, dx
cmp eax, 0x8005
jg 0x500e03
je 0x500dfa
sub eax, 2
cmp eax, 6
ja case.default.0x500d63
jmp dword [eax*4 + 0x501120]
mov eax, 2
jmp 0x500e73
mov eax, 6
jmp 0x500e73
test byte [ebp - 0xa4], 1
je 0x500d99
mov eax, dword [ebp - 0x25c]
mov word [ebp - 0x218], ax
jmp 0x500e80
mov eax, dword [ebp - 0x26c]
jmp 0x500e73
mov eax, 9
jmp 0x500e73
movq xmm0, qword [str.Jpeg_Old_Style]
mov eax, 0xff
mov word [ebp - 0x218], ax
mov eax, dword [0x5ede78]
mov dword [ebp - 0x20a], eax
mov ax, word [0x5ede7c]
mov word [ebp - 0x206], ax
mov al, byte [0x5ede7e]
movq qword [ebp - 0x212], xmm0
mov byte [ebp - 0x204], al
jmp case.default.0x500d63
mov eax, dword [ebp - 0x268]
jmp 0x500e73
mov word [ebp - 0x218], di
jmp case.default.0x500d63
sub eax, 0x80b2
je case.0x500d63.8
sub eax, 0x6c2
je 0x500e3d
dec eax
jne case.default.0x500d63
movq xmm0, qword [str.SGILog24]
mov eax, 0xff
mov word [ebp - 0x218], ax
mov al, byte [0x5ede88]
movq qword [ebp - 0x212], xmm0
mov byte [ebp - 0x20a], al
jmp case.default.0x500d63
mov eax, 0xff
mov word [ebp - 0x218], ax
mov eax, dword [str.SGILog]
mov dword [ebp - 0x212], eax
mov ax, word [0x5ede90]
mov word [ebp - 0x20e], ax
mov al, byte [0x5ede92]
mov byte [ebp - 0x20c], al
jmp case.default.0x500d63
mov eax, 4
mov word [ebp - 0x218], ax
mov eax, dword [ebp - 0x25c]
mov edi, 0x804c
cmp cx, di
mov edi, dword [ebp - 0xf0]
jne 0x500eab
mov word [ebp - 0x23e], ax
mov eax, 1
mov word [ebp - 0x240], ax
mov dword [ebp - 0x238], edi
jmp 0x500ec8
mov eax, 0x804d
cmp cx, ax
jne 0x500ec8
lea eax, [edi + edi*2]
mov dword [ebp - 0x240], 0x180001
mov dword [ebp - 0x238], eax
cmp dword [ebp - 0xc4], 0
mov eax, dword [ebp - 0xec]
mov dword [ebp - 0x248], edi
mov dword [ebp - 0x244], eax
je 0x500ef1
mov ecx, dword [ebp - 0xc4]
mov dword [ebp - 0x250], ecx
jmp 0x500f2b
cmp cx, 6
je 0x500f19
cmp dx, 5
je 0x500f19
cmp dx, 8
je 0x500f19
mov ecx, 0x80b2
cmp dx, cx
je 0x500f19
mov dword [ebp - 0x250], 1
jmp 0x500f2b
mov eax, dword [ebp - 0x9c]
mov dword [ebp - 0x250], eax
mov eax, dword [ebp - 0xec]
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x500f56
lea edi, [ebp - 0x172]
sub edi, ecx
lea ebx, [ebx]
mov al, byte [ecx]
mov byte [edi + ecx], al
inc ecx
test al, al
jne 0x500f40
mov eax, dword [ebp - 0x244]
mov edi, dword [ebp - 0x248]
cmp word [ebp - 0xe8], 0x10
jl 0x500fe6
mov cx, word [ebp - 0xa8]
cmp cx, 2
je 0x500f7c
cmp cx, 1
je 0x500f7c
test cx, cx
jne 0x500fe6
cmp dx, 5
je 0x500fa2
mov ecx, 0x80b2
cmp dx, cx
je 0x500fa2
cmp dx, 8
je 0x500fa2
mov ecx, 0x8005
cmp dx, cx
je 0x500fa2
cmp dx, 1
jne 0x500fe6
mov dword [ebp - 0x228], eax
mov ax, word [ebp - 0xe6]
mov dword [ebp - 0x22c], edi
cmp ax, 4
jle 0x500fc7
mov dword [ebp - 0x21c], 4
jmp 0x500fce
cwde
mov dword [ebp - 0x21c], eax
mov eax, dword [ebp - 0x238]
add eax, eax
mov dword [ebp - 0x220], 0x10
mov dword [ebp - 0x224], eax
lea eax, [ebp - 0x258]
push eax
push esi
call fcn.00456000
movzx edi, ax
add esp, 8
test di, di
jne 0x5010e9
xor eax, eax
cmp dword [ebp - 0x258], 4
push esi
sete al
movzx eax, ax
push eax
lea eax, [ebp - 0xf0]
push eax
push dword [ebp - 0x24c]
push ebx
call fcn.00501860
movzx edi, ax
add esp, 0x14
cmp di, 9
jne 0x501059
movdqu xmm0, xmmword [str.TIFF_:_Bad_LZW_codes__]
movdqu xmmword [esi + 0x44], xmm0
mov eax, dword [0x5edea4]
mov dword [esi + 0x54], eax
mov ax, word [0x5edea8]
mov word [esi + 0x58], ax
mov al, byte [0x5edeaa]
mov byte [esi + 0x5a], al
mov ax, word [ebp - 0xac]
cmp ax, 2
je 0x5010c5
cmp ax, 3
je 0x5010c5
cmp ax, 4
je 0x5010c5
cmp dword [ebp - 0xd4], 0
mov cx, word [ebp - 0xa8]
je 0x5010aa
cmp word [ebp - 0x23e], 8
jg 0x5010aa
cmp cx, 3
jne 0x5010aa
push dword [ebp - 0xcc]
push 0x10
push 0x110
push esi
call fcn.00453f80
add esp, 0x10
jmp 0x5010e9
xor eax, eax
test cx, cx
push 0
sete al
push 0
movzx eax, ax
push eax
push esi
call fcn.00453f80
add esp, 0x10
jmp 0x5010e9
xor eax, eax
cmp word [ebp - 0xa8], ax
push 0
setne al
push 0
movzx eax, ax
push eax
push esi
call fcn.00453f80
add esp, 0x10
jmp 0x5010e9
mov edi, 4
mov eax, dword [ebp - 0xcc]
test eax, eax
je 0x5010fc
push eax
call fcn.00592c4b
add esp, 4
mov eax, dword [ebp - 0x60]
test eax, eax
je 0x50110c
push eax
call fcn.00592c4b
add esp, 4
mov ecx, dword [ebp - 4]
mov ax, di
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.005920c1
mov esp, ebp
pop ebp
ret