Function at 0x49a5c0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
mov eax, 0x1258
call fcn.004f5a60
mov eax, dword [ebp + 0x14]
push ebx
push esi
xor esi, esi
test eax, eax
push edi
jne 0x49a5f0
mov ecx, dword [0x6c7fc4]
test ecx, ecx
jne 0x49a5f0
mov dword [0x6c7fc4], 1
cmp byte [eax], 0
je 0x49a620
mov eax, dword [ebp + 0x28]
test eax, eax
je 0x49a5ff
mov byte [eax], 1
mov eax, dword [ebp + 0x24]
test eax, eax
je 0x49acd1
mov dword [eax], 0
mov dword [eax + 4], 0x40590000
mov al, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 8]
test eax, eax
je 0x49a635
mov ebx, dword [eax + 0x14]
mov esi, dword [eax + 0x2b8]
mov dword [ebp + 0x10], ebx
jmp 0x49a638
mov ebx, dword [ebp + 0x10]
mov eax, dword [ebp + 0x20]
test eax, eax
je 0x49a648
cmp byte [eax], 0
je 0x49a705
xor eax, eax
push eax
mov dword [0x6c7fe0], eax
mov dword [0x6c7fdc], eax
mov dword [0x6c7fd8], eax
mov dword [0x6c7fd0], eax
mov dword [0x6c7fd4], eax
mov dword [0x6c7fc8], eax
mov dword [0x6c7fcc], eax
mov byte [0x6c7fe4], al
call fcn.0049a550
mov ecx, 0x5a
xor eax, eax
mov edi, 0x6c7e58
add esp, 4
rep stosd dword es:[edi], eax
mov al, byte [ebp + 0x1c]
test al, al
je 0x49a69a
mov dword [0x6c7fbc], 9
mov eax, dword [ebp + 8]
test eax, eax
je 0x49a77a
mov eax, dword [ebp + 0xc]
lea ecx, [eax + eax*8]
lea edx, [eax + ecx*2]
lea eax, [eax + edx*4]
shl eax, 5
add esi, eax
mov ecx, dword [esi + 0x54]
mov edx, dword [esi + 0x50]
push ecx
push edx
push ebx
call fcn.004b6ad0
add esp, 0xc
test eax, eax
jne 0x49a6d4
xor al, al
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [esi + 0x40]
mov byte [0x6c7fe4], 1
lea eax, [ecx + ecx*2]
shl eax, 4
add eax, ecx
lea eax, [eax + eax*2]
shl eax, 4
cdq
mov esi, eax
mov dword [0x6c7fcc], edx
mov dword [0x6c7fc8], esi
mov eax, dword [ebp + 0x20]
test eax, eax
je 0x49a711
mov byte [eax], 0
mov edx, dword [0x6c7fcc]
mov esi, dword [0x6c7fc8]
cmp dword [0x6c7fd4], edx
jg 0x49ab49
jl 0x49a72b
cmp dword [0x6c7fd0], esi
jae 0x49ab4f
mov ebx, dword [0x6c7fd4]
mov ecx, 0x244
xor eax, eax
lea edi, [esp + 0x21]
mov byte [esp + 0x20], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov al, byte [0x6c7fe4]
mov dword [esp + 0xc], 0
test al, al
jne 0x49a7f7
sub esi, dword [0x6c7fd0]
sbb edx, ebx
mov dword [esp + 0x1c], edx
js 0x49a7ca
jg 0x49a773
cmp esi, 0x914
jbe 0x49a7ca
mov ebx, 0x914
jmp 0x49a7cc
push 0
push 0
push ebx
call fcn.004b6ad0
add esp, 0xc
test eax, eax
jne 0x49a794
xor al, al
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push ebx
call fcn.004b6b20
add esp, 4
mov esi, eax
test edx, edx
mov dword [0x6c7fc8], esi
mov dword [0x6c7fcc], edx
jg 0x49a6fb
jl 0x49a7c1
cmp esi, 0x914
jae 0x49a6fb
xor al, al
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ebx, esi
mov edx, dword [ebp + 0x10]
lea eax, [esp + 0xc]
push 0
push eax
lea ecx, [esp + 0x28]
push ebx
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x49ac3b
cmp dword [esp + 0xc], ebx
jne 0x49ac3b
jmp 0x49a85d
mov ecx, 0x24b
xor eax, eax
lea edi, [esp + 0x935]
mov byte [esp + 0x934], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov edx, dword [ebp + 0x10]
push 0
stosb byte es:[edi], al
lea eax, [esp + 0x10]
lea ecx, [esp + 0x938]
push eax
push 0x930
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x49ac3b
cmp dword [esp + 0xc], 0x930
jne 0x49ac3b
mov ecx, 0x245
lea esi, [esp + 0x94c]
lea edi, [esp + 0x20]
mov ebx, 0x914
rep movsd dword es:[edi], dword [esi]
mov eax, dword [0x6c7fd0]
mov ecx, dword [0x6c7fd4]
or eax, ecx
jne 0x49a8e3
mov al, byte [0x6c7fe4]
test al, al
jne 0x49a8e3
lea edx, [esp + 0x20]
mov ecx, str.RIFF
mov eax, dword [edx]
mov edx, dword [ecx]
cmp eax, edx
jne 0x49a8e3
mov ecx, 2
mov edi, str.CDXAfmt
lea esi, [esp + 0x28]
xor edx, edx
repe cmpsd dword [esi], dword es:[edi]
jne 0x49a8e3
lea ecx, [esp + 0x44]
mov eax, str.data
mov edx, dword [ecx]
mov ecx, dword [eax]
cmp edx, ecx
jne 0x49a8e3
mov eax, dword [ebp + 0x10]
push 0
push 0x2c
push eax
mov byte [0x6c7fe4], 1
mov dword [0x6c7fd0], 0x2c
mov dword [0x6c7fd4], 0
call fcn.004b6ad0
add esp, 0xc
test eax, eax
je 0x49ac3b
jmp 0x49aaa6
push 0x6c7e58
push 1
lea ecx, [esp + 0x28]
push ebx
push ecx
call fcn.0049a060
mov edi, eax
xor ecx, ecx
add esp, 0x10
cmp edi, ecx
je 0x49aba7
mov al, byte [0x6c7fe4]
test al, al
je 0x49a96a
mov al, byte [0x6c7e64]
test al, al
je 0x49a94d
cmp dword [0x6c7ea0], 1
jne 0x49a930
mov eax, dword [ebp + 0x14]
mov dword [0x6c7ea0], ecx
inc dword [eax + 0x138]
jmp 0x49a96a
mov eax, dword [ebp + 0x14]
mov edx, dword [eax + 0x13c]
inc edx
mov dword [eax + 0x13c], edx
mov eax, dword [0x6c7ea0]
dec eax
mov dword [0x6c7ea0], eax
jmp 0x49a96a
mov eax, dword [ebp + 0x14]
mov esi, dword [0x6c7ea0]
mov edx, dword [eax + 0x13c]
add esi, edx
mov dword [0x6c7ea0], esi
mov dword [eax + 0x13c], ecx
mov eax, dword [0x6c7e6c]
cmp eax, 4
ja case.default.0x49a978
jmp dword [eax*4 + 0x49acdc]
mov al, byte [ebp + 0x18]
test al, al
jne case.0x49a978.0
push 0x10
call fcn.004b6a10
mov esi, eax
add esp, 4
test esi, esi
je 0x49abe7
mov eax, dword [0x6c7fd8]
mov dword [esi], eax
mov ecx, dword [0x6c7e70]
mov edx, dword [0x6c7e74]
mov dword [esi + 8], ecx
mov dword [esi + 0xc], edx
mov eax, dword [0x6c7e78]
lea ecx, [eax*8]
sub ecx, eax
mov ecx, dword [ecx*8 + 0x6c7edc]
test ecx, ecx
jne 0x49aa1c
push 0x10
call fcn.005129c8
add esp, 4
test eax, eax
je 0x49a9e7
mov ecx, eax
call fcn.004b6fe0
jmp 0x49a9e9
xor eax, eax
mov ecx, dword [0x6c7e78]
lea edx, [ecx*8]
sub edx, ecx
mov dword [edx*8 + 0x6c7edc], eax
mov eax, dword [0x6c7e78]
lea ecx, [eax*8]
sub ecx, eax
mov ecx, dword [ecx*8 + 0x6c7edc]
test ecx, ecx
je 0x49abe7
push esi
call fcn.004b7050
mov al, byte [0x6c7fe4]
mov edx, dword [0x6c7fd0]
test al, al
je 0x49aa39
add edx, 0x930
jmp 0x49aa3b
add edx, edi
mov ecx, dword [0x6c7fd4]
mov dword [0x6c7fd0], edx
mov edx, dword [0x6c7fd8]
adc ecx, 0
inc edx
cmp edi, ebx
mov dword [0x6c7fd4], ecx
mov dword [0x6c7fd8], edx
je 0x49aaa6
test al, al
jne 0x49aaa6
mov ecx, dword [0x6c7fdc]
mov eax, dword [0x6c7fe0]
mov edx, 0x914
sub edx, edi
add ecx, edx
mov edx, dword [ebp + 0x10]
inc eax
mov dword [0x6c7fdc], ecx
mov ecx, dword [0x6c7fd0]
mov dword [0x6c7fe0], eax
mov eax, dword [0x6c7fd4]
push eax
push ecx
push edx
call fcn.004b6ad0
add esp, 0xc
test eax, eax
je 0x49ac3b
mov esi, dword [ebp + 0x24]
test esi, esi
je 0x49aae6
mov eax, dword [0x6c7fd4]
mov ecx, dword [0x6c7fd0]
push 0
push 0x64
push eax
push ecx
call fcn.004f5ce0
mov ecx, dword [0x6c7fcc]
push ecx
mov ecx, dword [0x6c7fc8]
push ecx
push edx
push eax
call fcn.004f5c30
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], edx
fild qword [esp + 0x10]
fstp qword [esi]
mov ecx, dword [ebp + 0x28]
test ecx, ecx
je 0x49ab16
mov edx, dword [0x6c7fd0]
mov eax, dword [0x6c7fc8]
cmp edx, eax
jne 0x49ab12
mov eax, dword [0x6c7fd4]
mov edx, dword [0x6c7fcc]
cmp eax, edx
jne 0x49ab12
mov eax, 1
jmp 0x49ab14
xor eax, eax
mov byte [ecx], al
mov eax, dword [ebp + 0x20]
test eax, eax
jne 0x49abfa
mov edx, dword [0x6c7fcc]
mov ebx, dword [0x6c7fd4]
mov esi, dword [0x6c7fc8]
cmp ebx, edx
jl 0x49a731
jg 0x49ab49
cmp dword [0x6c7fd0], esi
jb 0x49a731
cmp dword [0x6c7fd0], esi
jne 0x49ab59
cmp dword [0x6c7fd4], edx
je 0x49ab6c
mov eax, dword [0x6c7fc4]
test eax, eax
jne 0x49ab6c
mov dword [0x6c7fc4], 1
mov ebx, dword [ebp + 0x14]
mov ecx, 0x48
mov esi, 0x6c7ea0
push 1
lea edi, [ebx + 0x18]
rep movsd dword es:[edi], dword [esi]
call fcn.0049a550
mov ecx, dword [ebp + 8]
add esp, 4
test ecx, ecx
mov byte [ebx], 1
mov eax, 3
je 0x49ac44
mov dword [ebx + 4], 1
jmp 0x49ac5a
mov esi, dword [0x6c7fc8]
mov ebx, dword [0x6c7fd0]
mov edx, dword [0x6c7fcc]
mov edi, dword [0x6c7fd4]
mov eax, esi
mov ecx, edx
sub eax, ebx
sbb ecx, edi
mov dword [esp + 0x1c], ecx
js 0x49ab49
jg 0x49abde
cmp eax, 0x914
jbe 0x49ab49
xor al, al
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov dword [0x6c7fc4], 0x99
xor al, al
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov edx, dword [0x6c7fd0]
mov eax, dword [0x6c7fc8]
cmp edx, eax
jne 0x49acd1
mov eax, dword [0x6c7fd4]
mov ecx, dword [0x6c7fcc]
cmp eax, ecx
je 0x49ab6c
mov al, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp dword [0x6c7fc4], ecx
jne 0x49ac3b
mov dword [0x6c7fc4], 2
xor al, al
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov cl, byte [0x6c7fe4]
test cl, cl
je 0x49ac53
mov dword [ebx + 4], eax
jmp 0x49ac5a
mov dword [ebx + 4], 2
mov ebx, dword [ebp + 0x14]
mov dword [esp + 0xc], eax
fld qword [ebx + 0x120]
fsub qword [ebx + 0x118]
add ebx, 0x54
fstp qword [ebx + 0xd4]
mov ecx, dword [ebx]
test ecx, ecx
je 0x49aca5
call fcn.004b70d0
mov edi, eax
xor esi, esi
test edi, edi
jle 0x49aca5
mov ecx, dword [ebx]
push esi
call fcn.004b7090
mov ecx, dword [ebp + 0x14]
inc esi
fld qword [eax + 8]
fsub qword [ecx + 0x118]
cmp esi, edi
fstp qword [eax + 8]
jl 0x49ac89
mov eax, dword [esp + 0xc]
add ebx, 0x38
dec eax
mov dword [esp + 0xc], eax
jne 0x49ac76
mov eax, dword [ebp + 0x24]
test eax, eax
je 0x49acc7
mov dword [eax], 0
mov dword [eax + 4], 0x40590000
mov eax, dword [ebp + 0x28]
test eax, eax
je 0x49acd1
mov byte [eax], 1
pop edi
pop esi
mov al, 1
pop ebx
mov esp, ebp
pop ebp
ret