Function at 0x49f7e0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3c
push esi
mov esi, dword [ebp + 8]
cmp dword [esi + 0x984], 0
push edi
jne 0x49f80c
mov eax, dword [esi + 0x998]
sub eax, 3
neg eax
sbb eax, eax
and eax, 0xf
add eax, 0x11
movzx eax, ax
jmp 0x49f822
xor ecx, ecx
cmp dword [esi + 0x998], 3
setne cl
lea ecx, [ecx*8 + 9]
movzx eax, cx
push ebx
mov edi, edx
push 0
lea edx, [ebp - 0xc]
push edx
mov edx, dword [edi + 0x67]
movzx eax, ax
push eax
add edi, 0x67
lea ecx, [ebp - 0x3a]
push ecx
push edx
mov dword [ebp - 0x14], edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [ebp - 0xc]
sub dword [edi + 8], eax
mov edx, dword [esi + 0x984]
movzx eax, byte [ebp - 0x3a]
movzx ecx, byte [ebp - 0x39]
test edx, edx
sete bl
add bl, 8
shl eax, 8
or eax, ecx
movsx edi, bl
mov ecx, 0x10
sub ecx, edi
sar eax, cl
mov ecx, 1
mov dword [ebp - 0xc], ecx
mov ecx, edi
mov edi, dword [ebp - 0xc]
shl edi, cl
sub edi, 1
and eax, edi
mov dword [ebp - 0x10], eax
movsx ax, bl
xor ebx, ebx
cmp dword [esi + 0x998], 3
mov edi, edx
setne bl
add ebx, 1
neg edi
sbb edi, edi
add edi, 2
test edx, edx
mov dword [ebp - 8], ebx
mov dword [ebp - 0xc], edi
je 0x49f8b1
mov cl, bl
jmp 0x49f8bb
cmp ebx, 1
sete cl
lea ecx, [ecx + ecx + 3]
movsx dx, cl
add ax, dx
test ebx, ebx
mov word [ebp - 0x3c], ax
jle 0x49f8f8
lea edx, [esi + 0x814]
mov ecx, ebx
mov dword [edx + 4], 0
mov dword [edx], 0
mov dword [edx - 4], 0
mov dword [edx - 8], 0
add edx, 0xc0
sub ecx, 1
jne 0x49f8d2
cmp edi, 2
jne 0x49f9c7
test ebx, ebx
jle 0x49f9c7
add esi, 0x874
mov edi, ebx
movzx edx, ax
mov bl, dl
shr edx, 3
movzx edx, byte [ebp + edx - 0x3a]
and bl, 7
mov ecx, 7
sub cl, bl
shr edx, cl
add ax, 1
mov word [ebp - 0x3c], ax
mov ecx, 7
and edx, 1
mov dword [esi - 8], edx
movzx edx, ax
mov bl, dl
shr edx, 3
movzx edx, byte [ebp + edx - 0x3a]
and bl, 7
sub cl, bl
shr edx, cl
add ax, 1
mov word [ebp - 0x3c], ax
mov ecx, 7
and edx, 1
mov dword [esi - 4], edx
movzx edx, ax
mov bl, dl
shr edx, 3
movzx edx, byte [ebp + edx - 0x3a]
and bl, 7
sub cl, bl
shr edx, cl
add ax, 1
mov word [ebp - 0x3c], ax
mov ecx, 7
and edx, 1
mov dword [esi], edx
movzx edx, ax
mov bl, dl
shr edx, 3
movzx edx, byte [ebp + edx - 0x3a]
and bl, 7
sub cl, bl
shr edx, cl
add ax, 1
add esi, 0xc0
mov word [ebp - 0x3c], ax
and edx, 1
sub edi, 1
mov dword [esi - 0xbc], edx
jne 0x49f911
mov esi, dword [ebp + 8]
mov ebx, dword [ebp - 8]
mov edi, dword [ebp - 0xc]
test edi, edi
mov dword [ebp - 4], 0
jle 0x49fa2b
lea eax, [esi + 0x804]
mov dword [ebp - 8], eax
jmp 0x49f9e0
test ebx, ebx
mov dword [ebp + 8], 0
jle 0x49fa1a
mov edi, dword [ebp - 8]
mov edi, edi
mov ecx, dword [ebp + 8]
mov edx, dword [ebp - 4]
push esi
lea eax, [ebp - 0x3c]
mov dword [edi + 4], ecx
mov dword [edi], edx
call fcn.0049fad0
mov eax, dword [ebp + 8]
add eax, 1
add edi, 0xc0
cmp eax, ebx
mov dword [ebp + 8], eax
jl 0x49f9f0
mov edi, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
add dword [ebp - 8], 0x60
add eax, 1
cmp eax, edi
mov dword [ebp - 4], eax
jl 0x49f9e0
mov edi, dword [esi + 0x9b8]
cmp word [edi], 0
jne 0x49fa39
mov edi, esi
mov ecx, dword [esi + 0x984]
mov edx, dword [esi + 0x990]
mov ebx, dword [edx*4 + 0x5412a0]
mov eax, ecx
neg eax
sbb eax, eax
and eax, 0xffffffb8
add eax, 0x90
imul eax, dword [esi + 0x98c]
sar ebx, cl
cdq
idiv ebx
pop ebx
add ax, word [esi + 0x994]
sub ax, 4
cmp dword [esi + 0x988], 0
movzx eax, ax
jne 0x49fa81
sub eax, 2
test ecx, ecx
jne 0x49fa9d
mov ecx, dword [esi + 0x998]
sub ecx, 3
neg ecx
sbb ecx, ecx
and ecx, 0xf
add ecx, 0x11
movzx ecx, cx
jmp 0x49fab3
xor edx, edx
cmp dword [esi + 0x998], 3
setne dl
lea edx, [edx*8 + 9]
movzx ecx, dx
mov edx, dword [ebp - 0x10]
sub eax, ecx
push eax
mov ecx, edi
mov edi, dword [ebp - 0x14]
push esi
call fcn.0048a900
pop edi
pop esi
mov esp, ebp
pop ebp
ret 4