Function at 0x101db270
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x58
mov eax, dword [0x106499c8]
xor eax, esp
mov dword [esp + 0x54], eax
mov eax, dword [esp + 0x6c]
mov edx, dword [esp + 0x60]
mov ecx, dword [esp + 0x64]
push ebx
mov ebx, dword [esp + 0x74]
push ebp
mov ebp, dword [esp + 0x70]
push esi
mov esi, dword [esp + 0x68]
push edi
test eax, eax
mov edi, 0x2e
mov dword [esp + 0x14], 0x1e
cmovne edi, dword [esp + 0x14]
mov dword [esp + 0x28], edx
mov dword [esp + 0x20], ecx
mov dword [esp + 0x24], eax
mov dword [esp + 0x2c], edi
test ebp, ebp
je 0x101db2f2
cmp dword [ebp + 4], 0
ja 0x101db2f2
jb 0x101db2cf
cmp dword [ebp], edi
jae 0x101db2f2
push 0
push 0x13
push ebx
call fcn.101dcb20
add esp, 0xc
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
mov ecx, dword [esp + 0x54]
xor ecx, esp
call fcn.10311bec
add esp, 0x58
ret
test ecx, ecx
je 0x101db2fa
mov edi, dword [ecx]
jmp 0x101db341
push edx
push edi
lea eax, [esp + 0x3c]
push 1
push eax
call dword [sym.imp.MSVCR110.dll_fread]
add esp, 0x10
cmp eax, edi
jae 0x101db339
call dword [sym.imp.MSVCR110.dll__errno]
push dword [eax]
push 5
push ebx
call fcn.101dcb20
add esp, 0xc
or eax, 0xffffffff
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x54]
xor ecx, esp
call fcn.10311bec
add esp, 0x58
ret
mov eax, dword [esp + 0x24]
lea edi, [esp + 0x34]
test eax, eax
mov ecx, 0x104f4234
mov edx, 0x104f423c
mov dword [esp + 0x10], edi
mov eax, dword [edi]
cmove ecx, edx
cmp eax, dword [ecx]
jne 0x101db2cf
add edi, 4
push esi
mov dword [esp + 0x14], edi
call fcn.101db190
add esp, 4
cmp dword [esp + 0x24], 0
mov edx, 0x100
jne 0x101db394
movzx ecx, byte [edi + 1]
movzx eax, byte [edi]
imul cx, dx
add cx, ax
add edi, 2
movzx eax, cx
mov dword [esp + 0x10], edi
jmp 0x101db396
xor eax, eax
mov word [esi + 0xc], ax
movzx ecx, byte [edi + 1]
movzx eax, byte [edi]
imul cx, dx
add cx, ax
movzx eax, cx
mov word [esi + 0xe], ax
add edi, 2
mov dword [esp + 0x10], edi
movzx ecx, byte [edi + 1]
movzx eax, byte [edi]
imul cx, dx
add cx, ax
movzx eax, cx
mov word [esi + 0x10], ax
add edi, 2
mov dword [esp + 0x10], edi
movzx ecx, byte [edi + 1]
movzx eax, byte [edi]
imul cx, dx
add cx, ax
movzx eax, cx
add edi, 2
mov dword [esp + 0x10], edi
mov dword [esi + 0x14], eax
movzx ecx, byte [edi + 1]
movzx eax, byte [edi]
imul cx, dx
add cx, ax
add edi, 2
movzx edx, cx
mov dword [esp + 0x10], edi
movzx ecx, byte [edi + 1]
mov eax, 0x100
imul cx, ax
movzx eax, byte [edi]
add cx, ax
movzx eax, cx
push eax
add edi, 2
push edx
mov dword [esp + 0x18], edi
call fcn.101dc6c0
mov edx, dword [esp + 0x18]
mov dword [esi + 0x18], eax
movzx ecx, byte [edx + 3]
movzx eax, byte [edx + 2]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 1]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx]
shl ecx, 8
add ecx, eax
mov dword [esi + 0x1c], ecx
add edx, 4
mov dword [esp + 0x18], edx
movzx ecx, byte [edx + 3]
movzx eax, byte [edx + 2]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 1]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx]
shl ecx, 8
add ecx, eax
mov dword [esi + 0x20], ecx
add edx, 4
mov dword [esp + 0x18], edx
mov dword [esi + 0x24], 0
movzx ecx, byte [edx + 3]
movzx eax, byte [edx + 2]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 1]
shl ecx, 8
add ecx, eax
add esp, 8
shl ecx, 8
movzx eax, byte [edx]
add ecx, eax
add edx, 4
mov dword [esi + 0x28], ecx
mov dword [esp + 0x10], edx
mov dword [esi + 0x2c], 0
movzx ecx, byte [edx + 1]
movzx eax, byte [edx]
mov edi, 0x100
imul cx, di
add cx, ax
add edx, 2
movzx eax, cx
mov dword [esp + 0x10], edx
movzx ecx, byte [edx + 1]
imul cx, di
mov edi, dword [esp + 0x24]
mov dword [esp + 0x30], eax
movzx eax, byte [edx]
add cx, ax
movzx eax, cx
add edx, 2
mov dword [esp + 0x18], eax
mov dword [esp + 0x10], edx
test edi, edi
je 0x101db51b
xor ecx, ecx
xor edx, edx
mov dword [esp + 0x1c], ecx
mov dword [esi + 0x3c], ecx
mov word [esi + 0x40], dx
mov dword [esi + 0x44], ecx
mov dword [esi + 0x48], ecx
mov dword [esi + 0x4c], ecx
jmp 0x101db5dc
movzx ecx, byte [edx + 1]
mov eax, 0x100
imul cx, ax
movzx eax, byte [edx]
add cx, ax
movzx eax, cx
mov dword [esp + 0x1c], eax
add edx, 2
mov dword [esp + 0x10], edx
movzx ecx, byte [edx + 1]
mov eax, 0x100
imul cx, ax
movzx eax, byte [edx]
add cx, ax
movzx eax, cx
mov dword [esi + 0x3c], eax
add edx, 2
mov dword [esp + 0x10], edx
movzx ecx, byte [edx + 1]
mov eax, 0x100
imul cx, ax
movzx eax, byte [edx]
add cx, ax
movzx eax, cx
add edx, 2
mov dword [esp + 0x10], edx
mov word [esi + 0x40], ax
movzx ecx, byte [edx + 3]
movzx eax, byte [edx + 2]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 1]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx]
shl ecx, 8
add ecx, eax
mov dword [esi + 0x44], ecx
add edx, 4
mov dword [esp + 0x10], edx
movzx ecx, byte [edx + 3]
movzx eax, byte [edx + 2]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 1]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx]
shl ecx, 8
add ecx, eax
mov eax, dword [esp + 0x18]
add edx, 4
mov dword [esi + 0x48], ecx
mov ecx, dword [esp + 0x1c]
mov dword [esp + 0x10], edx
mov dword [esi + 0x4c], 0
mov edx, dword [esp + 0x30]
movzx eax, ax
mov dword [esp + 0x14], eax
movzx eax, dx
add eax, dword [esp + 0x14]
movzx ecx, cx
add ecx, eax
mov eax, dword [esp + 0x2c]
add eax, ecx
mov dword [esi + 0x30], 0
mov dword [esi + 0x34], 0
mov dword [esi + 0x38], 0
mov dword [esp + 0x2c], eax
test ebp, ebp
je 0x101db646
cmp dword [ebp + 4], 0
ja 0x101db646
jb 0x101db623
cmp dword [ebp], eax
jae 0x101db646
push 0
push 0x15
push ebx
call fcn.101dcb20
add esp, 0xc
or eax, 0xffffffff
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x54]
xor ecx, esp
call fcn.10311bec
add esp, 0x58
ret
test dx, dx
je 0x101db68f
push ebx
push 1
xor ecx, ecx
cmp dword [esp + 0x28], ecx
push edx
push dword [esp + 0x34]
lea eax, [esp + 0x20]
cmove eax, ecx
push eax
call fcn.101dc760
add esp, 0x14
mov dword [esi + 0x30], eax
test eax, eax
je 0x101db2dc
mov ecx, 0x800
test word [esi + 0x10], cx
je 0x101db68f
push 2
push eax
call fcn.101e2b30
add esp, 8
cmp eax, 5
je 0x101db623
cmp word [esp + 0x18], 0
je 0x101db726
push ebx
push 0
push dword [esp + 0x1c]
xor ecx, ecx
cmp dword [esp + 0x2c], ecx
push dword [esp + 0x34]
lea eax, [esp + 0x20]
cmove eax, ecx
push eax
call fcn.101dc3a0
mov ecx, eax
add esp, 0x14
mov dword [esp + 0x14], ecx
test ecx, ecx
je 0x101db2dc
mov edx, 0x100
push ebx
mov eax, 0x200
test edi, edi
cmovne eax, edx
push eax
push dword [esp + 0x20]
push ecx
call fcn.101dd1f0
add esp, 0x10
mov dword [esi + 0x34], eax
push dword [esp + 0x14]
test eax, eax
jne 0x101db712
call dword [sym.imp.MSVCR110.dll_free]
add esp, 4
or eax, 0xffffffff
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x54]
xor ecx, esp
call fcn.10311bec
add esp, 0x58
ret
call dword [sym.imp.MSVCR110.dll_free]
add esp, 4
test edi, edi
je 0x101db726
mov dword [esi + 4], 1
mov eax, dword [esp + 0x1c]
test ax, ax
je 0x101db777
push ebx
push 0
push eax
push dword [esp + 0x34]
xor ecx, ecx
cmp dword [esp + 0x30], ecx
lea eax, [esp + 0x20]
cmove eax, ecx
push eax
call fcn.101dc760
add esp, 0x14
mov dword [esi + 0x38], eax
test eax, eax
je 0x101db2dc
mov ecx, 0x800
test word [esi + 0x10], cx
je 0x101db777
push 2
push eax
call fcn.101e2b30
add esp, 8
cmp eax, 5
je 0x101db623
push dword [esi + 0x30]
push 0x7075
push esi
call fcn.101dc7b0
push dword [esi + 0x38]
mov dword [esi + 0x30], eax
push 0x6375
push esi
call fcn.101dc7b0
add esp, 0x18
cmp dword [esi + 0x28], 0xffffffff
mov dword [esi + 0x38], eax
jne 0x101db7a8
cmp dword [esi + 0x2c], 0
je 0x101db7c8
cmp dword [esi + 0x20], 0xffffffff
jne 0x101db7b4
cmp dword [esi + 0x24], 0
je 0x101db7c8
cmp dword [esi + 0x48], 0xffffffff
jne 0x101db8fd
cmp dword [esi + 0x4c], 0
jne 0x101db8fd
push ebx
mov ecx, 0x100
test edi, edi
mov eax, 0x200
cmovne eax, ecx
push eax
push 0
push 1
lea eax, [esp + 0x2c]
push eax
push dword [esi + 0x34]
call fcn.101dcfd0
mov edx, eax
add esp, 0x18
mov dword [esp + 0x18], edx
test edx, edx
je 0x101db2dc
test edi, edi
je 0x101db806
mov eax, 0x10
jmp 0x101db86a
cmp dword [esi + 0x28], 0xffffffff
jne 0x101db81a
cmp dword [esi + 0x2c], 0
mov dword [esp + 0x14], 1
je 0x101db822
mov dword [esp + 0x14], 0
cmp dword [esi + 0x20], 0xffffffff
jne 0x101db835
cmp dword [esi + 0x24], 0
jne 0x101db835
mov ecx, 1
jmp 0x101db837
xor ecx, ecx
cmp dword [esi + 0x48], 0xffffffff
jne 0x101db84a
cmp dword [esi + 0x4c], 0
jne 0x101db84a
mov eax, 1
jmp 0x101db84c
xor eax, eax
add ecx, dword [esp + 0x14]
add ecx, eax
xor eax, eax
add ecx, ecx
cmp dword [esi + 0x3c], 0xffff
sete al
add cx, ax
shl cx, 2
movzx eax, cx
cmp word [esp + 0x1c], ax
jne 0x101db623
cmp dword [esi + 0x28], 0xffffffff
jne 0x101db896
cmp dword [esi + 0x2c], 0
jne 0x101db896
lea eax, [esp + 0x18]
push eax
call fcn.101dc300
add esp, 4
mov dword [esi + 0x28], eax
mov dword [esi + 0x2c], edx
jmp 0x101db8a1
test edi, edi
je 0x101db8a1
add edx, 8
mov dword [esp + 0x18], edx
cmp dword [esi + 0x20], 0xffffffff
jne 0x101db8c0
cmp dword [esi + 0x24], 0
jne 0x101db8c0
lea eax, [esp + 0x18]
push eax
call fcn.101dc300
add esp, 4
mov dword [esi + 0x20], eax
mov dword [esi + 0x24], edx
test edi, edi
jne 0x101db933
cmp dword [esi + 0x48], 0xffffffff
jne 0x101db8e2
cmp dword [esi + 0x4c], edi
jne 0x101db8e2
lea eax, [esp + 0x18]
push eax
call fcn.101dc300
add esp, 4
mov dword [esi + 0x48], eax
mov dword [esi + 0x4c], edx
cmp dword [esi + 0x3c], 0xffff
jne 0x101db901
lea eax, [esp + 0x18]
push eax
call fcn.101dc2d0
add esp, 4
mov dword [esi + 0x3c], eax
jmp 0x101db901
test edi, edi
jne 0x101db933
cmp dword [esi + 0x4c], 0
ja 0x101db910
cmp dword [esi + 0x48], 0x7fffffff
jbe 0x101db933
push 0x1b
push 4
push ebx
call fcn.101dcb20
add esp, 0xc
or eax, 0xffffffff
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x54]
xor ecx, esp
call fcn.10311bec
add esp, 0x58
ret
push dword [esi + 0x34]
call fcn.101dd330
mov ecx, dword [esp + 0x24]
add esp, 4
mov dword [esi + 0x34], eax
test ecx, ecx
je 0x101db94f
mov eax, dword [esp + 0x10]
mov dword [ecx], eax
test ebp, ebp
je 0x101db95e
mov eax, dword [esp + 0x2c]
sub dword [ebp], eax
sbb dword [ebp + 4], 0
mov ecx, dword [esp + 0x64]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
xor eax, eax
call fcn.10311bec
add esp, 0x58
ret