Function at 0x1006c8e0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x50
mov eax, dword [section..data]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
mov ecx, dword [ebp + 0x14]
push ebx
push esi
mov esi, dword [ebp + 0xc]
push edi
mov edi, dword [ebp + 0x10]
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x40], edi
mov dword [ebp - 0x44], ecx
mov ebx, dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov edi, edi
cmp byte [esi], 0
je 0x1006c932
cmp byte [esi + 1], 0
je 0x1006c92e
push 1
push 0
push 0
push dword [esi + 4]
call ebx
sub eax, dword [esi + 0xc]
mov ecx, dword [ebp - 0x44]
jmp 0x1006c935
xor eax, eax
jmp 0x1006c935
mov eax, dword [esi + 0x20]
inc eax
cmp eax, dword [esi + 0x10]
ja 0x1006cced
cmp dword [ecx], 0
jne 0x1006c9d9
cmp byte [esi], 0
je 0x1006c96a
cmp byte [esi + 1], 0
je 0x1006c966
push 1
push 0
push 0
push dword [esi + 4]
call ebx
sub eax, dword [esi + 0xc]
mov ecx, dword [ebp - 0x44]
jmp 0x1006c96d
xor eax, eax
jmp 0x1006c96d
mov eax, dword [esi + 0x20]
add eax, 4
cmp eax, dword [esi + 0x10]
ja 0x1006ccba
cmp byte [esi], 0
mov edi, 4
je 0x1006c9a1
push 0
lea eax, [ebp - 0xc]
push eax
push edi
push ecx
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x1006c99c
mov byte [esi + 8], 1
mov edi, dword [ebp - 0xc]
jmp 0x1006c9c7
mov ecx, dword [esi + 0x20]
mov edx, dword [esi + 0x1c]
lea eax, [ecx + 4]
cmp eax, edx
jbe 0x1006c9b2
mov edi, edx
sub edi, ecx
mov eax, dword [esi + 0x18]
push edi
add eax, ecx
push eax
push dword [ebp - 0x44]
call sub.MSVCR120.dll_memcpy
add esp, 0xc
add dword [esi + 0x20], edi
shr edi, 2
cmp edi, 1
jne 0x1006cc9f
mov edi, dword [ebp - 0x40]
mov ecx, dword [ebp - 0x44]
mov eax, dword [ecx]
cmp eax, 0x2014b50
jne 0x1006ccd2
cmp byte [esi], 0
je 0x1006ca05
cmp byte [esi + 1], 0
je 0x1006ca01
push 1
push 0
push 0
push dword [esi + 4]
call ebx
sub eax, dword [esi + 0xc]
jmp 0x1006ca08
xor eax, eax
jmp 0x1006ca08
mov eax, dword [esi + 0x20]
add eax, 0x2a
cmp eax, dword [esi + 0x10]
jbe 0x1006ca13
or dword [edi], 0x10
cmp byte [esi], 0
mov edi, 0x2a
je 0x1006ca3e
push 0
lea eax, [ebp - 8]
push eax
push edi
lea eax, [ebp - 0x3c]
push eax
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x1006ca39
mov byte [esi + 8], 1
mov edi, dword [ebp - 8]
jmp 0x1006ca6e
mov ebx, dword [esi + 0x20]
mov ecx, dword [esi + 0x1c]
lea eax, [ebx + 0x2a]
cmp eax, ecx
jbe 0x1006ca4f
mov edi, ecx
sub edi, ebx
mov eax, dword [esi + 0x18]
add eax, ebx
push edi
push eax
lea eax, [ebp - 0x3c]
push eax
call sub.MSVCR120.dll_memcpy
lea eax, [ebx + edi]
add esp, 0xc
mov ebx, dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov dword [esi + 0x20], eax
mov eax, 0x86186187
mul edi
sub edi, edx
shr edi, 1
add edi, edx
shr edi, 5
cmp edi, 1
jne 0x1006ccbd
mov cx, word [ebp - 0x24]
test cx, cx
je 0x1006cae1
cmp byte [esi], 0
movzx edi, cx
je 0x1006cab6
cmp byte [esi + 1], 0
je 0x1006cab2
push 1
push 0
push 0
push dword [esi + 4]
call ebx
sub eax, dword [esi + 0xc]
mov cx, word [ebp - 0x24]
jmp 0x1006cab9
xor eax, eax
jmp 0x1006cab9
mov eax, dword [esi + 0x20]
add eax, edi
cmp eax, dword [esi + 0x10]
ja 0x1006cc9f
cmp byte [esi], 0
movzx eax, cx
je 0x1006cade
cmp byte [esi + 1], 0
je 0x1006cae1
push 1
push 0
push eax
push dword [esi + 4]
call ebx
jmp 0x1006cae1
add dword [esi + 0x20], eax
mov cx, word [ebp - 0x22]
test cx, cx
je 0x1006cb3b
cmp byte [esi], 0
movzx edi, cx
je 0x1006cb10
cmp byte [esi + 1], 0
je 0x1006cb0c
push 1
push 0
push 0
push dword [esi + 4]
call ebx
sub eax, dword [esi + 0xc]
mov cx, word [ebp - 0x22]
jmp 0x1006cb13
xor eax, eax
jmp 0x1006cb13
mov eax, dword [esi + 0x20]
add eax, edi
cmp eax, dword [esi + 0x10]
ja 0x1006cc9f
cmp byte [esi], 0
movzx eax, cx
je 0x1006cb38
cmp byte [esi + 1], 0
je 0x1006cb3b
push 1
push 0
push eax
push dword [esi + 4]
call ebx
jmp 0x1006cb3b
add dword [esi + 0x20], eax
mov ecx, dword [ebp - 0x50]
lea eax, [ebp - 0x3c]
push eax
call fcn.1006bc00
mov cx, word [ebp - 0x20]
mov edi, eax
test cx, cx
je 0x1006cc2a
cmp byte [esi], 0
movzx ebx, cx
je 0x1006cb80
cmp byte [esi + 1], 0
je 0x1006cb7c
push 1
push 0
push 0
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
sub eax, dword [esi + 0xc]
mov cx, word [ebp - 0x20]
jmp 0x1006cb83
xor eax, eax
jmp 0x1006cb83
mov eax, dword [esi + 0x20]
add eax, ebx
cmp eax, dword [esi + 0x10]
jbe 0x1006cb9a
mov eax, dword [ebp - 0x40]
or dword [eax], 0x10
test edi, edi
je 0x1006ccbd
jmp 0x1006cba2
test edi, edi
je 0x1006cc5c
mov eax, dword [edi + 0x34]
test eax, eax
je 0x1006cbb3
push eax
call dword [sym.imp.MSVCR120.dll_void___cdecl_operator_delete___void__]
add esp, 4
movzx eax, word [edi + 0x1c]
push eax
call fcn.1009427d
mov dword [edi + 0x34], eax
add esp, 4
cmp byte [esi], 0
movzx ebx, word [ebp - 0x20]
mov dword [ebp - 0x4c], eax
mov ecx, ebx
mov dword [ebp - 0x48], ebx
je 0x1006cbf2
push 0
lea ecx, [ebp - 0x10]
push ecx
push ebx
push eax
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x1006cbed
mov byte [esi + 8], 1
mov eax, dword [ebp - 0x10]
jmp 0x1006cc1d
mov edx, dword [esi + 0x20]
lea eax, [edx + ebx]
cmp eax, dword [esi + 0x1c]
jbe 0x1006cc05
mov ecx, dword [esi + 0x1c]
sub ecx, edx
mov dword [ebp - 0x48], ecx
push ecx
mov ecx, dword [esi + 0x18]
add ecx, edx
push ecx
push dword [ebp - 0x4c]
call sub.MSVCR120.dll_memcpy
mov eax, dword [ebp - 0x48]
add esp, 0xc
add dword [esi + 0x20], eax
xor edx, edx
div ebx
cmp eax, 1
jne 0x1006ccbd
test edi, edi
je 0x1006cc4b
movzx eax, word [ebp - 0x1e]
mov word [edi + 0x1e], ax
movzx eax, word [ebp - 0x1c]
mov word [edi + 0x20], ax
mov eax, dword [ebp - 0x1a]
mov dword [edi + 0x22], eax
movzx eax, word [ebp - 0x3c]
mov word [edi], ax
mov ecx, dword [ebp - 0x44]
mov edi, dword [ebp - 0x40]
mov dword [ecx], 0
jmp 0x1006c908
cmp byte [esi], 0
movzx eax, cx
je 0x1006cc8b
cmp byte [esi + 1], 0
je 0x1006cc4b
mov ebx, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 1
push 0
push eax
push dword [esi + 4]
call ebx
mov ecx, dword [ebp - 0x44]
mov edi, dword [ebp - 0x40]
mov dword [ecx], 0
jmp 0x1006c910
mov ecx, dword [ebp - 0x44]
add dword [esi + 0x20], eax
mov edi, dword [ebp - 0x40]
mov dword [ecx], 0
jmp 0x1006c908
mov eax, dword [ebp - 0x40]
pop edi
pop esi
pop ebx
or dword [eax], 0x10
xor al, al
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.100944ae
mov esp, ebp
pop ebp
ret 0x10
or dword [edi], 0x10
pop edi
pop esi
xor al, al
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.100944ae
mov esp, ebp
pop ebp
ret 0x10
pop edi
cmp eax, 0x6054b50
pop esi
sete al
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.100944ae
mov esp, ebp
pop ebp
ret 0x10
mov ecx, dword [ebp - 4]
mov al, 1
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.100944ae
mov esp, ebp
pop ebp
ret 0x10