Function at 0x580280
Capabilities:
Read file on windows

Disassembly:
sub esp, 8
push ebx
push ebp
mov ebp, dword [esp + 0x18]
push esi
push edi
push 0x10000
call fcn.0045d550
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x5805c0
push 0x60
push 0
push ebp
call fcn.0060c930
mov eax, dword [esp + 0x28]
mov edi, dword [eax]
add esp, 0xc
cmp dword [edi + 0x14], 0
mov dword [ebp + 0x18], SysReAllocString
je 0x5802ce
mov eax, 2
call fcn.00410220
jmp 0x5802e3
mov edi, dword [edi + 4]
test edi, edi
je 0x5802e3
push edi
push 1
push 2
push ebx
call fcn.0060860a
add esp, 0x10
cmp byte [ebx + 1], 0xd8
je 0x580300
push ebx
call fcn.0045da90
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret 0xc
mov ecx, dword [esp + 0x1c]
mov esi, dword [ecx]
mov eax, dword [esi + 0x14]
test eax, eax
je 0x580341
mov eax, dword [esi + 0x1c]
mov edi, 4
cmp eax, edi
jb 0x580323
mov ecx, dword [esi + 0x18]
lea edx, [ecx + 4]
cmp edx, eax
jbe 0x58032c
mov ecx, dword [esi + 0x18]
sub eax, ecx
mov edi, eax
je 0x580356
mov eax, dword [esi + 0x14]
push edi
add ecx, eax
push ecx
push ebx
call fcn.0060d1b0
add esp, 0xc
add dword [esi + 0x18], edi
jmp 0x580356
mov esi, dword [esi + 4]
test esi, esi
je 0x580356
push esi
push 2
push 2
push ebx
call fcn.0060860a
add esp, 0x10
xor edx, edx
mov dh, byte [ebx + 2]
xor eax, eax
mov ah, byte [ebx]
mov dl, byte [ebx + 3]
mov al, byte [ebx + 1]
sub edx, 2
mov dword [esp + 0x20], edx
cmp eax, 0xff00
mov dword [esp + 0x10], eax
jle 0x5802e9
mov eax, dword [esp + 0x1c]
mov esi, dword [eax]
cmp dword [esi + 0x14], 0
je 0x5803bb
mov eax, dword [esi + 0x1c]
cmp edx, eax
mov edi, edx
ja 0x58039b
mov ecx, dword [esi + 0x18]
add edx, ecx
cmp edx, eax
mov edx, edi
jbe 0x5803a2
mov ecx, dword [esi + 0x18]
sub eax, ecx
mov edi, eax
test edi, edi
je 0x5803d3
mov eax, dword [esi + 0x14]
push edi
add ecx, eax
push ecx
push ebx
call fcn.0060d1b0
add esp, 0xc
add dword [esi + 0x18], edi
jmp 0x5803cf
mov esi, dword [esi + 4]
test esi, esi
je 0x5803d3
push esi
push edx
push 1
push ebx
call fcn.0060860a
add esp, 0x10
mov edx, dword [esp + 0x20]
mov eax, dword [esp + 0x10]
add eax, 0xffff0040
cmp eax, 0x1d
ja case.0x5803ec.65473
movzx eax, byte [eax + 0x5805ec]
jmp dword [eax*4 + 0x5805d4]
movzx eax, byte [ebx + 7]
mov ecx, eax
shr ecx, 4
imul ecx, eax
sub ecx, 1
and ecx, 3
mov dword [ebp + 0x10], ecx
movzx eax, byte [ebx]
xor ecx, ecx
mov ch, byte [ebx + 1]
mov dword [ebp], eax
xor eax, eax
mov ah, byte [ebx + 3]
mov cl, byte [ebx + 2]
mov al, byte [ebx + 4]
mov dword [ebp + 4], ecx
movzx ecx, byte [ebx + 5]
add ecx, dword [ebp + 0x10]
cmp edx, 9
mov dword [ebp + 8], eax
mov dword [ebp + 0xc], ecx
jne case.0x5803ec.65473
mov eax, dword [esp + 0x1c]
cmp dword [eax + 0x3c4], 0
jne case.0x5803ec.65473
mov ecx, dword [eax]
cmp dword [ecx + 0x14], 0
je 0x580478
mov eax, dword [ecx + 0x1c]
lea esi, [edx - 8]
cmp eax, esi
jb 0x580464
mov edx, dword [ecx + 0x18]
lea edi, [edx + 1]
cmp edi, eax
jbe 0x580471
mov edx, dword [ecx + 0x18]
sub eax, edx
mov esi, eax
je case.0x5803ec.65473
add edx, esi
mov dword [ecx + 0x18], edx
jmp case.0x5803ec.65473
mov ecx, dword [ecx + 4]
test ecx, ecx
je case.0x5803ec.65473
push ecx
call fcn.0060963d
add esp, 4
jmp case.0x5803ec.65473
cmp dword [esp + 0x24], 0
jne case.0x5803ec.65473
add edx, ebx
cmp ebx, edx
mov eax, ebx
mov dword [esp + 0x14], edx
jae case.0x5803ec.65473
movzx edi, byte [eax]
add eax, 1
cmp edi, 4
mov dword [esp + 0x20], eax
jge case.0x5803ec.65473
mov edx, dword [esp + 0x1c]
push edx
lea esi, [esp + 0x24]
call fcn.0057f750
mov dword [ebp + edi*4 + 0x34], eax
mov dword [ebp + edi*4 + 0x4c], eax
mov eax, dword [esp + 0x20]
cmp eax, dword [esp + 0x14]
jb 0x58049d
jmp case.0x5803ec.65473
movzx eax, byte [ebx]
movzx edx, byte [ebx + eax*2 + 3]
movzx ecx, byte [ebx + eax*2 + 1]
lea eax, [ebx + eax*2]
and edx, 0xf
sub dword [ebp], edx
mov dword [ebp + 0x14], ecx
jmp case.0x5803ec.65473
xor eax, eax
mov ah, byte [ebx]
mov al, byte [ebx + 1]
mov dword [ebp + 0x18], eax
cmp dword [esp + 0x10], 0xffda
jne 0x580300
cmp dword [esp + 0x24], 0
jne 0x580596
lea ecx, [ebp + 0x38]
mov eax, ecx
mov edx, 5
cmp dword [eax], 0
jne 0x580520
mov esi, dword [eax - 4]
mov dword [eax], esi
add eax, 4
sub edx, 1
jne 0x580516
cmp dword [ebp + 0x10], edx
je 0x580558
lea eax, [ebp + 0x3c]
mov edx, 4
mov esi, dword [ecx]
mov dword [eax], esi
add eax, 4
sub edx, 1
jne 0x580535
xor eax, eax
cmp dword [ebp + 0x10], eax
jle 0x580558
mov edx, dword [ebp + 0x34]
mov dword [ecx], edx
add eax, 1
add ecx, 4
cmp eax, dword [ebp + 0x10]
jl 0x580548
mov eax, dword [ebp + 0xc]
imul eax, dword [ebp + 8]
lea edi, [eax*4]
push edi
call fcn.0045d550
mov esi, eax
add esp, 4
test esi, esi
je 0x580581
push edi
push 0
push esi
call fcn.0060c930
add esp, 0xc
test esi, esi
mov dword [ebp + 0x5c], esi
je 0x5805ae
mov eax, dword [esp + 0x1c]
mov dword [eax + 0x3bc], 1
push ebx
call fcn.0045da90
add esp, 4
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 8
ret 0xc
mov ecx, dword [esp + 0x1c]
push 1
add ecx, 0x968ec
push ecx
call fcn.0061b7d8
mov edx, dword [esp + 0x1c]
push 1
add edx, 0x968ec
push edx
call fcn.0061b7d8
mov edi, edi
or byte [eax + ebx*2], al
add bl, dh
add ebx, dword [eax]
mov al, byte [eax + ebx*2]
add dh, cl
add al, 0x58
add cl, ch
add al, 0x58
add bl, dh
add al, 0x58
add byte [eax], al
add eax, 0x5020105
add eax, 84215045
add eax, 84215045
add eax, 84215045
add eax, 84215045
add eax, dword [-859044859]
int3