Function at 0x140010010
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 0x10], rdx
push rbx
push rbp
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x40
mov r14, r9
lea rdi, [0x140049c00]
mov ebp, r8d
mov r13d, 1
mov r9d, r13d
xor r8d, r8d
xor edx, edx
mov r15, rcx
mov r12, rdi
call qword [sym.imp.api_ms_win_core_file_l1_1_0.dll_SetFilePointer]
nop dword [rax + rax]
mov dword [rsp + 0x30], eax
cmp ebp, 0x1fff
jb 0x140010062
mov ebp, 0x1fff
lea rcx, [0x140058470]
mov qword [rsp + 0x80], rsi
call qword [sym.imp.api_ms_win_core_synch_l1_1_0.dll_AcquireSRWLockShared]
nop dword [rax + rax]
mov r9, r14
mov qword [rsp + 0x20], 0
mov r8d, ebp
mov rdx, rdi
mov rcx, r15
call qword [sym.imp.api_ms_win_core_file_l1_1_0.dll_ReadFile]
nop dword [rax + rax]
lea rcx, [0x140058470]
mov ebx, eax
call qword [sym.imp.api_ms_win_core_synch_l1_1_0.dll_ReleaseSRWLockShared]
nop dword [rax + rax]
test ebx, ebx
je 0x1400101a9
mov esi, dword [r14]
test esi, esi
je 0x1400101a9
mov r10d, dword [0x140041928]
mov ecx, esi
mov edx, dword [rsp + 0x30]
mov dword [rsp + 0x90], esi
cmp r10d, 0xfde9
je 0x14001d66e
test esi, esi
jle 0x14001015b
lea r8, [0x140058150]
cmp ecx, 3
jl 0x140010106
movzx eax, byte [rdi]
cmp al, 0xa
je 0x14001d6d1
cmp al, 0xd
je 0x14001012b
movzx eax, byte [rdi]
cmp byte [rax + r8], 0
jne 0x14001d6e0
inc rdi
mov eax, 0xffffffff
add ecx, eax
mov dword [rsp + 0x90], ecx
test ecx, ecx
jg 0x1400100f2
jmp 0x14001015b
cmp byte [rdi + 1], 0xa
jne 0x140010106
mov esi, edi
mov byte [rdi + 2], 0
sub esi, r12d
xor r9d, r9d
add esi, 2
xor r8d, r8d
add edx, esi
mov rcx, r15
call qword [sym.imp.api_ms_win_core_file_l1_1_0.dll_SetFilePointer]
nop dword [rax + rax]
mov r10d, dword [0x140041928]
mov ecx, r10d
call fcn.140010460
test eax, eax
je 0x1400101ad
mov rax, qword [rsp + 0x88]
mov r9d, esi
mov dword [rsp + 0x28], ebp
mov r8, r12
mov edx, r13d
mov qword [rsp + 0x20], rax
call qword [sym.imp.api_ms_win_core_string_l1_1_0.dll_MultiByteToWideChar]
nop dword [rax + rax]
mov dword [r14], eax
mov rsi, qword [rsp + 0x80]
add rsp, 0x40
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rbp
pop rbx
ret
xor eax, eax
jmp 0x140010190
xor r13d, r13d
jmp 0x140010167
test edx, edx
jne 0x1400100e7
cmp ebp, 3
jbe 0x1400100e7
movzx edx, word [0x140049c00]
movzx eax, word [0x1400359cc]
sub edx, eax
jne 0x14001d6a1
movzx edx, byte [0x140049c02]
movzx eax, byte [0x1400359ce]
sub edx, eax
test edx, edx
jne 0x14001d6c8
add esi, 0xfffffffd
lea rdi, [0x140049c03]
mov r12, rdi
mov dword [r14], esi
mov dword [rsp + 0x90], esi
mov ecx, esi
mov edx, 3
jmp 0x1400100e7
mov edx, dword [rsp + 0x30]
jmp 0x1400100e7
cmp byte [rdi + 1], 0xd
je 0x140010131
jmp 0x140010102
cmp ecx, r13d
je 0x14001d6f3
add rdi, 2
mov eax, 0xfffffffe
jmp 0x14001011c
lea rcx, [0x140058470]
call qword [sym.imp.api_ms_win_core_synch_l1_1_0.dll_AcquireSRWLockShared]
nop dword [rax + rax]
lea rdx, [rdi + 1]
mov qword [rsp + 0x20], 0
lea r9, [rsp + 0x90]
mov r8d, r13d
mov rcx, r15
call qword [sym.imp.api_ms_win_core_file_l1_1_0.dll_ReadFile]
nop dword [rax + rax]
lea rcx, [0x140058470]
mov ebx, eax
call qword [sym.imp.api_ms_win_core_synch_l1_1_0.dll_ReleaseSRWLockShared]
nop dword [rax + rax]
test ebx, ebx
je 0x14001d757
cmp dword [rsp + 0x90], 0
je 0x14001d757
inc esi
jmp 0x140010154
mov dword [r14], 0
jmp 0x1400101a9