Function at 0x10013690
Capabilities:
Read file on windows
Resolve function by parsing pe exports

Disassembly:
mov eax, 0x205c
call fcn.10001480
push ebx
push ebp
mov ebp, ecx
mov dword [esp + 0x78], 0x1fe0
lea eax, [esp + 0x7c]
mov dword [esp + 0x1c], ebp
mov dword [esp + 0x74], eax
lea ecx, [esp + 0x24]
push esi
mov eax, dword [ebp + 0x12cc]
push edi
mov dword [esp + 0x78], 0x10056344
mov dword [esp + 0x2c], 0x1005bdb0
lea eax, [eax*2 + 0x16]
mov dword [esp + 0x30], 0
push eax
mov dword [esp + 0x38], 0
mov word [esp + 0x3c], 0x1ff
call fcn.100049c0
mov edi, dword [esp + 0x2c]
test eax, eax
je 0x10013748
mov eax, dword [ebp + 0x12cc]
xor edx, edx
mov ecx, dword [ebp + 0x12c8]
add eax, eax
push eax
push ecx
lea esi, [edi + eax]
mov word [esi], dx
push edi
call sub.msvcrt.dll_memcpy
add esp, 0xc
xor eax, eax
mov word [esi + 0x14], ax
mov eax, dword [str.idmfc.dat]
mov dword [esi], eax
mov eax, dword [0x1005611c]
mov dword [esi + 4], eax
mov eax, dword [0x10056120]
mov dword [esi + 8], eax
mov eax, dword [0x10056124]
mov dword [esi + 0xc], eax
mov eax, dword [0x10056128]
mov dword [esi + 0x10], eax
mov eax, dword [ebp + 0x1308]
lea esi, [ebp + 0x1228]
or eax, dword [ebp + 0x130c]
mov dword [esp + 0x18], esi
je 0x10013764
mov bl, 1
jmp 0x10013766
xor bl, bl
push 0x100520cc
push edi
mov dword [esp + 0x28], 0xffffffff
call dword [sym.imp.msvcrt.dll__wfopen]
mov edi, eax
add esp, 8
mov dword [esp + 0x3c], edi
test edi, edi
je 0x10013b12
lea eax, [esp + 0x40]
push eax
push edi
call dword [sym.imp.msvcrt.dll__fileno]
add esp, 4
push eax
call dword [sym.imp.msvcrt.dll__fstat64]
add esp, 8
test eax, eax
js 0x10013b12
mov eax, dword [ebp + 0x1308]
cmp eax, dword [esp + 0x68]
jne 0x100137c8
mov eax, dword [ebp + 0x130c]
cmp eax, dword [esp + 0x6c]
je 0x10013b4a
cmp dword [esp + 0x5c], 0
jg 0x10013b16
mov eax, dword [esp + 0x58]
jl 0x100137e4
cmp eax, 0x2800
ja 0x10013b16
lea esi, [eax + 1]
mov eax, dword [esp + 0x80]
cmp esi, eax
jbe 0x1001381d
mov eax, dword [esp + 0x78]
lea ecx, [esp + 0x78]
push 0
call dword [eax + 4]
push esi
call dword [sym.imp.msvcrt.dll_malloc]
mov ecx, eax
add esp, 4
xor eax, eax
mov dword [esp + 0x7c], ecx
test ecx, ecx
cmovne eax, esi
mov dword [esp + 0x80], eax
mov ecx, dword [esp + 0x7c]
test ecx, ecx
je 0x10013901
push edi
dec eax
push eax
push 1
push ecx
call dword [sym.imp.msvcrt.dll_fread]
mov esi, eax
add esp, 0x10
mov dword [esp + 0x28], esi
cmp esi, 0xa
jl 0x10013901
mov ecx, dword [esp + 0x7c]
mov byte [esp + 0x17], 0
mov byte [ecx + esi], 0
mov ecx, 1
mov word [ebp + 0x1310], cx
mov ebp, dword [sym.imp.msvcrt.dll_strncmp]
mov edi, dword [esp + 0x7c]
mov ebx, esi
push 3
push 0x100550e0
push edi
call ebp
add esp, 0xc
test eax, eax
jne 0x10013880
lea ebx, [esi - 3]
test eax, eax
lea esi, [edi + 3]
cmovne esi, edi
xor ecx, ecx
test ebx, ebx
jle 0x100138b1
mov edi, edi
movzx eax, byte [esi + ecx]
mov al, byte [eax*2 + 0x10052120]
shr al, 1
test al, 1
je 0x100138a6
inc ecx
cmp ecx, ebx
jl 0x10013890
cmp ecx, 3
jl 0x100138b1
cmp byte [esi + ecx], 0x3d
je 0x100138ea
cmp byte [esp + 0x17], 0
jne 0x10013901
mov ecx, dword [esp + 0x24]
add ecx, 0x88
call fcn.10003350
mov edx, dword [esp + 0x7c]
mov esi, dword [esp + 0x28]
push edx
push esi
mov byte [ecx + 0x10a4], 0
call fcn.100032e0
add esp, 8
mov byte [esp + 0x17], 1
jmp 0x10013866
mov eax, esi
lea ecx, [esi + ebx]
cmp eax, ecx
jae 0x10013901
cmp byte [eax], 0xa
lea edi, [eax + 1]
je 0x1001390a
mov eax, edi
cmp eax, ecx
jb 0x100138f3
mov esi, dword [esp + 0x18]
jmp 0x10013b16
mov ebp, dword [sym.imp.msvcrt.dll_sscanf]
mov eax, esi
sub eax, edi
add ebx, eax
mov ecx, dword [esp + 0x24]
lea eax, [esp + 0x1c]
push eax
lea eax, [ecx + 0x1310]
push eax
push str._FORMAT_hu_n
push esi
call ebp
add esp, 0x10
cmp eax, 1
je 0x10013962
lea eax, [esp + 0x1c]
push eax
lea eax, [esp + 0x24]
push eax
push str._LINES_u_n
push esi
call ebp
add esp, 0x10
cmp eax, 1
je 0x10013962
cmp esi, edi
jae 0x1001395e
cmp byte [esi], 0x3b
je 0x10013966
inc esi
cmp esi, edi
jb 0x10013954
xor esi, esi
jmp 0x10013966
add esi, dword [esp + 0x1c]
test esi, esi
je 0x1001398e
cmp byte [esi], 0x3b
jne 0x10013972
inc esi
jmp 0x10013916
movzx eax, byte [esi]
inc esi
movzx eax, byte [eax*2 + 0x10052120]
and al, 1
jne 0x10013972
test esi, esi
je 0x1001398e
cmp esi, edi
jb 0x10013901
cmp dword [esp + 0x20], 0
jl 0x10013901
mov edx, dword [esp + 0x18]
mov eax, dword [edx]
mov dword [edx + 4], 0
mov byte [eax], 0
mov eax, dword [esp + 0x28]
inc eax
cmp dword [edx + 8], eax
jae 0x100139bf
push eax
mov ecx, edx
call fcn.100035c0
mov edx, dword [esp + 0x18]
xor cl, cl
xor ebp, ebp
mov byte [esp + 0x17], cl
test ebx, ebx
js 0x10013901
nop
test cl, cl
je 0x100139fd
cmp ebx, 1
jbe 0x10013b00
cmp byte [edi], 0x2a
jne 0x10013b00
cmp byte [edi + 1], 0x2f
jne 0x10013b00
xor cl, cl
inc edi
mov byte [esp + 0x17], cl
dec ebx
jmp 0x10013b00
test ebp, ebp
jne 0x10013a21
test ebx, ebx
je 0x10013b00
movzx eax, byte [edi]
test byte [eax*2 + 0x10052120], 1
jne 0x10013b00
mov ebp, edi
jmp 0x10013b00
test ebx, ebx
je 0x10013a33
mov al, byte [edi]
cmp al, 0xd
je 0x10013a33
cmp al, 0xa
jne 0x10013b00
movzx eax, byte [edi - 1]
lea ecx, [edi - 1]
mov dword [esp + 0x1c], 0
mov esi, edi
test byte [eax*2 + 0x10052120], 1
je 0x10013a63
mov edi, edi
mov esi, ecx
movzx eax, byte [esi - 1]
lea ecx, [esi - 1]
test byte [eax*2 + 0x10052120], 1
jne 0x10013a50
cmp byte [ebp], 0x2f
jne 0x10013a83
mov al, byte [ebp + 1]
cmp al, 0x2a
jne 0x10013a7b
mov cl, 1
mov byte [esp + 0x17], cl
jmp 0x10013afc
cmp al, 0x2f
je 0x10013af8
mov eax, dword [edx + 4]
test eax, eax
je 0x10013ab8
add eax, 2
cmp dword [edx + 8], eax
jae 0x10013aa2
push eax
mov ecx, edx
call fcn.100035c0
mov edx, dword [esp + 0x18]
test eax, eax
je 0x10013ab8
mov eax, dword [edx + 4]
mov ecx, dword [edx]
mov byte [ecx + eax], 0x7c
mov ecx, dword [edx + 4]
mov eax, dword [edx]
inc ecx
mov dword [edx + 4], ecx
mov byte [ecx + eax], 0
sub esi, ebp
test esi, esi
jle 0x10013af4
mov eax, dword [edx + 4]
inc eax
add eax, esi
cmp dword [edx + 8], eax
jae 0x10013ad9
push eax
mov ecx, edx
call fcn.100035c0
test eax, eax
je 0x10013af4
mov edx, dword [esp + 0x18]
mov eax, dword [edx + 4]
mov ecx, dword [edx]
add ecx, eax
add eax, esi
push esi
push ebp
mov dword [edx + 4], eax
push ecx
mov byte [ecx + esi], 0
call sub.msvcrt.dll_memcpy
add esp, 0xc
dec dword [esp + 0x20]
mov cl, byte [esp + 0x17]
mov ebp, dword [esp + 0x1c]
mov edx, dword [esp + 0x18]
inc edi
sub ebx, 1
jns 0x100139d0
mov esi, edx
jmp 0x10013b16
test bl, bl
je 0x10013b46
cmp dword [esp + 0x20], 0
je 0x10013b2a
mov ecx, esi
call fcn.10003f70
xor eax, eax
xor ecx, ecx
jmp 0x10013b32
mov eax, dword [esp + 0x68]
mov ecx, dword [esp + 0x6c]
mov edx, dword [esp + 0x24]
mov edi, dword [esp + 0x3c]
mov dword [edx + 0x1308], eax
mov dword [edx + 0x130c], ecx
test edi, edi
je 0x10013b54
push edi
call dword [sym.imp.msvcrt.dll_fclose]
add esp, 4
mov eax, dword [esp + 0x2c]
mov esi, dword [sym.imp.msvcrt.dll_free]
cmp eax, 0x1005bdb0
je 0x10013b6e
add eax, 0xfffffffc
push eax
call esi
add esp, 4
mov ecx, dword [esp + 0x7c]
lea edx, [esp + 0x84]
xor eax, eax
mov dword [esp + 0x78], 0x100550d0
cmp ecx, edx
cmove ecx, eax
mov dword [esp + 0x7c], ecx
test ecx, ecx
je 0x10013b96
push ecx
call esi
add esp, 4
pop edi
pop esi
pop ebp
mov al, 1
pop ebx
add esp, 0x205c
ret