Function at 0x1004fb60
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x50
push ebx
mov ebx, ecx
mov dword [ebp - 0x30], edx
push esi
push edi
mov dword [ebp - 0x1c], ebx
mov eax, dword [ebx + 0x10]
lea edi, [ebx + 0x14]
test eax, eax
je 0x1004fb90
push eax
call fcn.100cd848
mov ecx, eax
add esp, 4
xor eax, eax
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004fba1
mov eax, dword [edi]
cmp eax, dword [ebx + 0x18]
jae 0x1004fb9f
movzx ecx, byte [eax]
inc eax
mov dword [edi], eax
jmp 0x1004fba1
xor ecx, ecx
mov eax, ebx
mov edx, 0x18
lea esi, [edx + eax]
movzx eax, cl
mov dword [ebp - 0x18], eax
mov eax, dword [ebx + 0x10]
mov dword [ebp - 0x14], esi
test eax, eax
je 0x1004fbd3
push eax
call fcn.100cd848
mov ecx, eax
add esp, 4
xor eax, eax
cmp ecx, 0xffffffff
cmove ecx, eax
mov dword [ebp - 0xc], ecx
jmp 0x1004fbeb
mov eax, dword [edi]
cmp eax, dword [esi]
jae 0x1004fbe4
movzx ecx, byte [eax]
inc eax
mov dword [ebp - 0xc], ecx
mov dword [edi], eax
jmp 0x1004fbeb
mov dword [ebp - 0xc], 0
mov eax, dword [ebx + 0x10]
test eax, eax
je 0x1004fc07
push eax
call fcn.100cd848
mov ecx, eax
add esp, 4
xor eax, eax
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004fc17
mov eax, dword [edi]
cmp eax, dword [esi]
jae 0x1004fc15
movzx ecx, byte [eax]
inc eax
mov dword [edi], eax
jmp 0x1004fc17
xor ecx, ecx
movzx eax, cl
mov ecx, ebx
mov dword [ebp - 0x3c], eax
call fcn.10049fd0
mov ecx, ebx
mov dword [ebp - 8], eax
call fcn.10049fd0
mov ecx, dword [ebx + 0x10]
mov dword [ebp - 0x44], eax
test ecx, ecx
je 0x1004fc4d
push ecx
call fcn.100cd848
mov ecx, eax
add esp, 4
xor eax, eax
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004fc5d
mov eax, dword [edi]
cmp eax, dword [esi]
jae 0x1004fc5b
movzx ecx, byte [eax]
inc eax
mov dword [edi], eax
jmp 0x1004fc5d
xor ecx, ecx
movzx eax, cl
mov ecx, ebx
mov dword [ebp - 0x38], eax
call fcn.10049fd0
mov ecx, ebx
call fcn.10049fd0
mov ecx, ebx
call fcn.10049fd0
mov ecx, ebx
mov dword [ebp - 0x20], eax
call fcn.10049fd0
mov ecx, dword [ebx + 0x10]
mov dword [ebp - 0x24], eax
test ecx, ecx
je 0x1004fca1
push ecx
call fcn.100cd848
mov ecx, eax
add esp, 4
xor eax, eax
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004fcb1
mov eax, dword [edi]
cmp eax, dword [esi]
jae 0x1004fcaf
movzx ecx, byte [eax]
inc eax
mov dword [edi], eax
jmp 0x1004fcb1
xor ecx, ecx
mov eax, dword [ebx + 0x10]
movzx esi, cl
test eax, eax
je 0x1004fcd0
push eax
call fcn.100cd848
mov ecx, eax
add esp, 4
xor eax, eax
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004fce3
mov ecx, dword [ebp - 0x14]
mov eax, dword [edi]
cmp eax, dword [ecx]
jae 0x1004fce1
movzx ecx, byte [eax]
inc eax
mov dword [edi], eax
jmp 0x1004fce3
xor ecx, ecx
mov edx, dword [ebp - 0x3c]
cmp edx, 8
movzx eax, cl
mov dword [ebp - 0x34], 0
mov byte [ebp - 1], 0
lea ecx, [edx - 8]
mov byte [ebp - 2], 0
cmovb ecx, edx
mov byte [ebp - 3], 0
shr eax, 5
mov edx, 1
and eax, 1
mov byte [ebp - 4], 0
sub edx, eax
mov dword [ebp - 0x2c], 0
cmp dword [ebp - 0x20], 1
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x48], 1
mov dword [ebp - 0x50], edx
jl 0x10050086
mov edx, dword [ebp - 0x24]
cmp edx, 1
jl 0x10050086
lea eax, [ecx - 1]
cmp eax, 2
ja 0x10050086
cmp esi, 8
je 0x1004fd68
cmp esi, 0x10
je 0x1004fd68
cmp esi, 0x18
je 0x1004fd68
cmp esi, 0x20
jne 0x10050086
mov eax, dword [ebp - 0x30]
cmp byte [ebp - 0xc], 0
mov ecx, dword [ebp - 0x38]
cmove ecx, esi
mov esi, dword [ebp - 0x20]
mov dword [eax], esi
mov eax, dword [ebp + 8]
mov dword [ebp - 0x10], ecx
mov dword [eax], edx
mov eax, ecx
shr eax, 3
xor ecx, ecx
mov dword [ebp - 0x4c], eax
mov dword [0], eax
mov eax, edx
imul eax, esi
mov edx, 4
mov dword [ebp - 0x30], eax
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.100d397d
mov ecx, dword [ebx + 0x10]
add esp, 4
mov edx, dword [ebp - 0x18]
mov esi, eax
mov dword [ebp - 0x28], esi
test ecx, ecx
je 0x1004fdcd
push 1
push edx
push ecx
call fcn.100ce839
add esp, 0xc
jmp 0x1004fdcf
add dword [edi], edx
cmp byte [ebp - 0xc], 0
je 0x1004fe3e
mov eax, dword [ebx + 0x10]
mov ecx, dword [ebp - 8]
test eax, eax
je 0x1004fded
push 1
push ecx
push eax
call fcn.100ce839
add esp, 0xc
jmp 0x1004fdef
add dword [edi], ecx
mov eax, dword [ebp - 0x38]
imul eax, dword [ebp - 0x44]
cdq
and edx, 7
lea esi, [edx + eax]
sar esi, 3
push esi
mov dword [ebp - 0x38], esi
call fcn.100d397d
mov ecx, dword [ebx + 0x10]
add esp, 4
mov dword [ebp - 0x34], eax
test ecx, ecx
je 0x1004fe25
push ecx
push esi
push 1
push eax
call fcn.100ce3e9
add esp, 0x10
jmp 0x1004fe3b
push dword [ebp - 0x38]
mov esi, dword [edi]
push esi
push eax
call fcn.100c58f0
mov eax, dword [ebp - 0x38]
add esp, 0xc
add eax, esi
mov dword [edi], eax
mov esi, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x30]
test ecx, ecx
jle 0x10050006
add esi, 2
xor eax, eax
mov dword [ebp - 0x18], esi
mov dl, al
mov dh, al
cmp dword [ebp - 0x3c], 8
jb 0x1004feb2
test eax, eax
jne 0x1004fea2
mov eax, dword [ebx + 0x10]
test eax, eax
je 0x1004fe7b
push eax
call fcn.100cd848
mov ecx, eax
add esp, 4
xor eax, eax
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004fe8e
mov ecx, dword [ebp - 0x14]
mov eax, dword [edi]
cmp eax, dword [ecx]
jae 0x1004fe8c
movzx ecx, byte [eax]
inc eax
mov dword [edi], eax
jmp 0x1004fe8e
xor ecx, ecx
movzx ecx, cl
mov eax, ecx
and eax, 0x7f
inc eax
shr ecx, 7
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x40], ecx
jmp 0x1004feb2
cmp dword [ebp - 0x40], 0
je 0x1004feb2
cmp dword [ebp - 0x48], 0
je 0x1004ffdc
cmp byte [ebp - 0xc], 0
je 0x1004ff1b
mov eax, dword [ebx + 0x10]
test eax, eax
je 0x1004fed4
push eax
call fcn.100cd848
mov ecx, eax
add esp, 4
xor eax, eax
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004fee7
mov ecx, dword [ebp - 0x14]
mov eax, dword [edi]
cmp eax, dword [ecx]
jae 0x1004fee5
movzx ecx, byte [eax]
inc eax
mov dword [edi], eax
jmp 0x1004fee7
xor ecx, ecx
mov esi, dword [ebp - 0x4c]
movzx eax, cl
xor ecx, ecx
cmp eax, dword [ebp - 0x44]
cmovge eax, ecx
imul esi, eax
mov eax, dword [ebp - 0x10]
test eax, eax
je 0x1004ff66
add esi, dword [ebp - 0x34]
lea edx, [ebp - 8]
mov ebx, eax
mov al, byte [esi]
lea esi, [esi + 1]
mov byte [edx], al
add ecx, 8
inc edx
cmp ecx, ebx
jl 0x1004ff07
mov eax, dword [ebp - 0x10]
jmp 0x1004ff66
mov eax, dword [ebp - 0x10]
test eax, eax
je 0x1004ff69
xor esi, esi
lea ebx, [ebp - 8]
mov eax, dword [ebp - 0x1c]
mov eax, dword [eax + 0x10]
test eax, eax
je 0x1004ff46
push eax
call fcn.100cd848
mov ecx, eax
add esp, 4
xor eax, eax
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004ff59
mov ecx, dword [ebp - 0x14]
mov eax, dword [edi]
cmp eax, dword [ecx]
jae 0x1004ff57
movzx ecx, byte [eax]
inc eax
mov dword [edi], eax
jmp 0x1004ff59
xor ecx, ecx
mov eax, dword [ebp - 0x10]
add esi, 8
mov byte [ebx], cl
inc ebx
cmp esi, eax
jl 0x1004ff27
mov esi, dword [ebp - 0x18]
add eax, 0xfffffff8
cmp eax, 0x18
ja case.0x1004ff78.9
movzx eax, byte [eax + 0x100500a4]
jmp dword [eax*4 + 0x10050090]
mov dl, byte [ebp - 8]
mov byte [ebp - 1], dl
mov byte [ebp - 2], dl
mov byte [ebp - 4], 0xff
mov byte [ebp - 3], dl
jmp case.0x1004ff78.9
mov eax, dword [ebp - 8]
mov dl, al
mov byte [ebp - 1], dl
mov byte [ebp - 2], dl
mov byte [ebp - 4], ah
mov byte [ebp - 3], dl
jmp case.0x1004ff78.9
mov dl, byte [ebp - 6]
mov eax, dword [ebp - 8]
mov byte [ebp - 1], dl
mov byte [ebp - 3], al
mov byte [ebp - 4], 0xff
jmp 0x1004ffc8
mov al, byte [ebp - 6]
mov byte [ebp - 1], al
mov eax, dword [ebp - 8]
mov byte [ebp - 3], al
mov al, byte [ebp - 5]
mov byte [ebp - 4], al
mov byte [ebp - 2], ah
mov eax, dword [ebp - 0x2c]
xor ecx, ecx
mov dl, byte [ebp - 1]
mov dh, byte [ebp - 2]
mov dword [ebp - 0x48], ecx
mov ecx, dword [ebp - 0x30]
mov bl, byte [ebp - 3]
dec eax
mov byte [esi], bl
mov bl, byte [ebp - 4]
mov byte [esi + 1], bl
mov ebx, dword [ebp - 0x1c]
mov byte [esi - 2], dl
mov byte [esi - 1], dh
add esi, 4
sub ecx, 1
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x18], esi
mov dword [ebp - 0x30], ecx
jne 0x1004fe55
cmp dword [ebp - 0x50], 0
je 0x1005006c
mov edx, dword [ebp - 0x20]
xor ecx, ecx
mov esi, dword [ebp - 0x24]
xor eax, eax
xor ebx, ebx
mov dword [ebp - 0x48], ecx
shl edx, 2
mov dword [ebp - 0x50], edx
mov edi, edx
test edi, edi
jle 0x1005005f
mov ecx, dword [ebp - 0x28]
not eax
add eax, dword [ebp - 0x24]
imul eax, dword [ebp - 0x20]
lea esi, [ebx + ecx]
lea eax, [ebx + eax*4]
add eax, ecx
nop dword [eax + eax]
mov cl, byte [eax]
lea esi, [esi + 1]
mov dl, byte [esi - 1]
lea eax, [eax + 1]
mov byte [esi - 1], cl
dec edi
mov byte [eax - 1], dl
test edi, edi
jg 0x10050040
mov ecx, dword [ebp - 0x48]
mov edx, dword [ebp - 0x50]
mov esi, dword [ebp - 0x24]
inc ecx
add ebx, edx
mov dword [ebp - 0x48], ecx
lea eax, [ecx + ecx]
cmp eax, esi
jl 0x10050021
mov eax, dword [ebp - 0x34]
test eax, eax
je 0x1005007c
push eax
call fcn.100ce041
add esp, 4
mov eax, dword [ebp - 0x28]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret