Function at 0x18004d6c0
Capabilities:
Read file on windows

Disassembly:
push rbp
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbx
sub rsp, 0xf8
lea rbp, [rsp + 0x80]
movaps xmmword [rbp + 0x60], xmm6
mov rsi, rdx
mov r15, rcx
mov r12, qword [rdx]
mov r14, qword [rdx + 0x10]
mov ebx, 0x2000
mov qword [rbp + 8], r8
test r8b, 1
je 0x18004d738
cmp r9, 0xfffffffffffffbff
ja 0x18004d728
lea rbx, [r9 + 0x400]
mov rax, rbx
and rax, 0x1fff
je 0x18004d72d
mov ecx, 0x2000
sub rcx, rax
add rbx, rcx
setb al
test al, 1
je 0x18004d72d
mov ebx, 0x2000
mov r13, r12
mov rdi, r14
test r9, r9
jne 0x18004d76b
mov rax, r12
sub rax, r14
cmp rax, 0x20
jae 0x18004d765
mov rcx, r15
mov rdx, rsi
call fcn.18004da60
mov rdi, rdx
test rax, rax
je 0x18004d997
mov eax, 1
jmp 0x18004d9d1
mov r13, r12
mov rdi, r14
mov qword [rbp + 0x10], r12
mov qword [rbp + 0x40], r14
mov qword [rbp + 0x18], r15
mov r15, qword [r15]
mov qword [rbp + 0x50], 0
xorps xmm6, xmm6
xor r12d, r12d
cmp rdi, r13
je 0x18004d7ad
jmp 0x18004d7d7
mov qword [rbp + 0x50], 0
mov r12, rcx
sub r12, rax
test byte [rbp + 8], 1
je 0x18004d8f4
cmp rdi, r13
jne 0x18004d7d7
cmp r13, qword [rbp + 0x10]
jne 0x18004d7d7
mov rcx, qword [rbp + 0x18]
mov rdx, rsi
call fcn.18004da60
mov rdi, rdx
test rax, rax
jne 0x18004d75b
test rdi, rdi
je 0x18004d9ac
mov r13, qword [rsi]
mov rdi, qword [rsi + 0x10]
cmp rdi, r13
jne 0x18004d810
cmp rdi, 0xffffffffffffffdf
ja 0x18004d986
lea r13, [rdi + 0x20]
lea rax, [rdi + rdi]
cmp rax, r13
cmova r13, rax
test r13, r13
js 0x18004d986
test rdi, rdi
jne 0x18004d937
xor eax, eax
jmp 0x18004d948
mov r13, qword [rsi]
mov rax, qword [rsi + 8]
mov r14, r13
sub r14, rdi
cmp r14, rbx
jb 0x18004d825
mov r14, rbx
movups xmm0, xmmword [0x18008c0b8]
movaps xmmword [rbp + 0x20], xmm0
mov edx, 0xffffffff
mov rcx, r14
cmp r14, rdx
jb 0x18004d842
mov ecx, 0xffffffff
add rax, rdi
movups xmmword [rsp + 0x38], xmm6
mov qword [rsp + 0x28], rax
lea rax, [rbp + 0x20]
mov qword [rsp + 0x20], rax
mov dword [rsp + 0x30], ecx
mov rcx, r15
xor edx, edx
xor r8d, r8d
xor r9d, r9d
call qword [sym.imp.ntdll.dll_NtReadFile]
cmp eax, 0x103
jne 0x18004d885
mov rcx, r15
mov edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [rbp + 0x20]
cmp eax, 0xc0000011
jne 0x18004d8a0
xor eax, eax
add rdi, rax
mov qword [rsi + 0x10], rdi
test rax, rax
jne 0x18004d8c7
jmp 0x18004d9cb
cmp eax, 0x103
je 0x18004da02
test eax, eax
js 0x18004d9b2
mov rax, qword [rbp + 0x28]
add rdi, rax
mov qword [rsi + 0x10], rdi
test rax, rax
je 0x18004d9cb
cmp r12, rax
mov rcx, r12
cmovbe rcx, rax
cmp rax, r14
jae 0x18004d790
mov rdx, qword [rbp + 0x50]
inc edx
mov qword [rbp + 0x50], rdx
mov r12, rcx
sub r12, rax
test byte [rbp + 8], 1
jne 0x18004d7a8
mov rdx, 0xffffffffffffffff
mov r8, 0xffffffffffffffff
cmp dword [rbp + 0x50], 2
jge 0x18004d90b
mov r8, rbx
cmp rcx, r14
cmovne rbx, r8
test rbx, rbx
js 0x18004d91b
lea rdx, [rbx + rbx]
cmp r14, rbx
cmovb rdx, rbx
cmp rax, r14
cmove rbx, rdx
cmp rdi, r13
je 0x18004d7ad
jmp 0x18004d7d7
mov rax, qword [rsi + 8]
mov qword [rbp - 0x30], rax
mov qword [rbp - 0x20], rdi
mov eax, 1
mov qword [rbp - 0x28], rax
mov edx, 1
lea rcx, [rbp + 0x20]
mov r8, r13
lea r9, [rbp - 0x30]
call fcn.18006dbd0
cmp dword [rbp + 0x20], 1
je 0x18004d986
mov rax, qword [rbp + 0x28]
mov qword [rsi + 8], rax
mov qword [rsi], r13
mov r14, r13
sub r14, rdi
cmp r14, rbx
jae 0x18004d822
jmp 0x18004d825
mov eax, 1
movabs rdi, 0x2600000003
jmp 0x18004d9d1
test rdi, rdi
je 0x18004d9a8
mov r13, qword [rsi]
mov rdi, qword [rsi + 0x10]
jmp 0x18004d76b
xor edi, edi
jmp 0x18004d9cf
mov rdi, qword [rsi + 0x10]
jmp 0x18004d9cb
mov ecx, eax
call qword [sym.imp.ntdll.dll_RtlNtStatusToDosError]
mov ebx, eax
mov ecx, eax
call case.0x18004f525.136
cmp al, 0xb
jne 0x18004d9ec
mov qword [rsi + 0x10], rdi
sub rdi, qword [rbp + 0x40]
xor eax, eax
mov rdx, rdi
movaps xmm6, xmmword [rbp + 0x60]
add rsp, 0xf8
pop rbx
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
pop rbp
ret
shl rbx, 0x20
or rbx, 2
mov qword [rsi + 0x10], rdi
mov eax, 1
mov rdi, rbx
jmp 0x18004d9d1
mov dword [rbp + 0x48], 0
mov byte [rbp + 0x4c], 0
lea rax, str.fatal_runtime_error:_I_O_error:_operation_failed_to_complete_synchronously_n
mov qword [rbp - 0x30], rax
mov qword [rbp - 0x28], 1
lea rax, [rbp + 0x58]
mov qword [rbp - 0x20], rax
xorps xmm0, xmm0
movups xmmword [rbp - 0x18], xmm0
lea rcx, [rbp + 0x48]
lea rdx, [rbp - 0x30]
call fcn.18004e110
mov qword [rbp], rax
mov rcx, rbp
call fcn.180048000
mov ecx, 7
int 0x29
ud2