Function at 0x40be81
Capabilities:
Read file on windows

Disassembly:
push rbp
push rbx
sub rsp, 0x38
lea rbp, [rsp + 0x80]
mov qword [rbp - 0x30], rcx
mov qword [rbp - 0x28], rdx
mov dword [rbp - 0x20], r8d
mov qword [rbp - 0x18], r9
mov rax, qword [rbp - 0x18]
imul rax, qword [rbp - 0x10]
mov qword [rbp - 0x60], rax
cmp qword [rbp - 0x18], 0
je 0x40beba
cmp qword [rbp - 0x10], 0
jne 0x40bec4
mov eax, 0
jmp 0x40c0e3
mov rax, qword [rbp - 0x60]
cmp rax, qword [rbp - 0x10]
jae 0x40bf21
cmp qword [rbp - 8], 0
je 0x40bf17
mov rax, qword [rbp - 0x18]
mov rdx, rax
lea rcx, [0x00484733]
call fcn.0040bdf5
mov rbx, rax
mov rax, qword [rbp - 0x10]
mov rdx, rax
lea rcx, [0x00484733]
call fcn.0040bdf5
mov rdx, rax
mov rax, qword [rbp - 8]
mov r9, rax
mov r8, rbx
lea rcx, str.Size_overflow_prevents_reading__s_elements_of_size__s_for__s_n
call fcn.0045d76f
mov eax, 0
jmp 0x40c0e3
mov rax, qword [rbp - 0x28]
mov rax, qword [rax + 0x10]
cmp qword [rbp - 0x60], rax
ja 0x40bf50
mov edx, dword [0x004a8040]
mov eax, dword [rbp - 0x20]
add eax, edx
mov edx, eax
mov rax, qword [rbp - 0x60]
add rdx, rax
mov rax, qword [rbp - 0x28]
mov rax, qword [rax + 0x10]
cmp rdx, rax
jbe 0x40bf8a
cmp qword [rbp - 8], 0
je 0x40bf80
mov rax, qword [rbp - 0x60]
mov rdx, rax
lea rcx, [0x00484733]
call fcn.0040bdf5
mov rdx, rax
mov rax, qword [rbp - 8]
mov r8, rax
lea rcx, str.Reading__s_bytes_extends_past_end_of_file_for__s_n
call fcn.0045d76f
mov eax, 0
jmp 0x40c0e3
mov edx, dword [0x004a8040]
mov eax, dword [rbp - 0x20]
add eax, edx
mov edx, eax
mov rax, qword [rbp - 0x28]
mov rax, qword [rax + 8]
mov r8d, 0
mov rcx, rax
call sub.msvcrt.dll_fseek
test eax, eax
je 0x40bfe2
cmp qword [rbp - 8], 0
je 0x40bfd8
mov edx, dword [0x004a8040]
mov eax, dword [rbp - 0x20]
add eax, edx
mov rdx, qword [rbp - 8]
mov r8, rdx
mov edx, eax
lea rcx, str.Unable_to_seek_to_0x_lx_for__s_n
call fcn.0045d76f
mov eax, 0
jmp 0x40c0e3
mov rax, qword [rbp - 0x30]
mov qword [rbp - 0x58], rax
cmp qword [rbp - 0x58], 0
jne 0x40c06a
mov rax, 0xfffffffffffffffe
mov edx, 0
div qword [rbp - 0x18]
cmp qword [rbp - 0x10], rax
jae 0x40c01b
mov rax, qword [rbp - 0x60]
add rax, 1
mov rcx, rax
call sub.msvcrt.dll_malloc
mov qword [rbp - 0x58], rax
cmp qword [rbp - 0x58], 0
jne 0x40c05c
cmp qword [rbp - 8], 0
je 0x40c052
mov rax, qword [rbp - 0x60]
mov rdx, rax
lea rcx, [0x00484733]
call fcn.0040bdf5
mov rdx, rax
mov rax, qword [rbp - 8]
mov r8, rax
lea rcx, str.Out_of_memory_allocating__s_bytes_for__s_n
call fcn.0045d76f
mov eax, 0
jmp 0x40c0e3
mov rdx, qword [rbp - 0x58]
mov rax, qword [rbp - 0x60]
add rax, rdx
mov byte [rax], 0
mov rax, qword [rbp - 0x28]
mov r8, qword [rax + 8]
mov rcx, qword [rbp - 0x10]
mov rdx, qword [rbp - 0x18]
mov rax, qword [rbp - 0x58]
mov r9, r8
mov r8, rcx
mov rcx, rax
call sub.msvcrt.dll_fread
cmp qword [rbp - 0x10], rax
je 0x40c0df
cmp qword [rbp - 8], 0
je 0x40c0c2
mov rax, qword [rbp - 0x60]
mov rdx, rax
lea rcx, [0x00484733]
call fcn.0040bdf5
mov rdx, rax
mov rax, qword [rbp - 8]
mov r8, rax
lea rcx, str.Unable_to_read_in__s_bytes_of__s_n
call fcn.0045d76f
mov rax, qword [rbp - 0x58]
cmp rax, qword [rbp - 0x30]
je 0x40c0d8
mov rax, qword [rbp - 0x58]
mov rcx, rax
call sub.msvcrt.dll_free
mov eax, 0
jmp 0x40c0e3
mov rax, qword [rbp - 0x58]
add rsp, 0x38
pop rbx
pop rbp
ret