Function at 0x1801595e0
Capabilities:
Check if file exists
Get file size
Read file on windows

Disassembly:
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x27]
sub rsp, 0xb0
mov qword [rbp - 0x39], 0xfffffffffffffffe
mov qword [rsp + 0x108], rbx
mov rax, qword [0x180248950]
xor rax, rsp
mov qword [rbp + 0x17], rax
mov rbx, r8
mov rdi, rdx
mov qword [rbp - 0x41], rcx
mov qword [rbp - 0x31], rbx
xor r14d, r14d
mov dword [rbp - 0x45], r14d
mov qword [rbp - 0x11], 0xf
mov qword [rbp - 0x19], r14
mov byte [rbp - 0x29], r14b
xor r8d, r8d
lea rdx, [0x1801f3e58]
lea rcx, [rbp - 0x29]
call fcn.18000c460
nop
cmp qword [rbx + 0x18], 0x10
jb 0x18015965b
mov rcx, qword [rbx]
jmp 0x18015965e
mov rcx, rbx
call qword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
je 0x1801597df
cmp qword [rbx + 0x18], 0x10
jb 0x180159678
mov rcx, qword [rbx]
jmp 0x18015967b
mov rcx, rbx
mov qword [rsp + 0x30], r14
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 4
xor r9d, r9d
mov edx, 0x80000000
lea r8d, [r9 + 1]
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rsi, rax
cmp rax, 0xffffffffffffffff
jne 0x1801596e6
mov qword [rdi + 0x18], 0xf
mov qword [rdi + 0x10], r14
mov byte [rdi], 0
xor r8d, r8d
lea rdx, [0x1801f3e58]
mov rcx, rdi
call fcn.18000c460
nop
cmp qword [rbp - 0x11], 0x10
jb 0x18015982a
mov rcx, qword [rbp - 0x29]
call fcn.1800b5354
jmp 0x18015982a
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov r15d, eax
lea rcx, [r15 + 1]
call fcn.1800b4760
mov r14, rax
test rax, rax
jne 0x180159762
mov qword [rdi + 0x18], 0xf
xor r12d, r12d
mov qword [rdi + 0x10], r12
mov byte [rdi], r12b
xor r8d, r8d
lea rdx, [0x1801f3e58]
mov rcx, rdi
call fcn.18000c460
nop
cmp qword [rbp - 0x11], 0x10
jb 0x18015973a
mov rcx, qword [rbp - 0x29]
call fcn.1800b5354
mov qword [rbp - 0x11], 0xf
mov qword [rbp - 0x19], r12
mov byte [rbp - 0x29], 0
cmp qword [rbx + 0x18], 0x10
jb 0x180159759
mov rcx, qword [rbx]
call fcn.1800b5354
mov qword [rbx + 0x10], r12
jmp 0x18015984d
lea r8, [r15 + 1]
xor edx, edx
mov rcx, rax
call fcn.1800be330
xor r12d, r12d
mov qword [rsp + 0x20], r12
lea r9, [rbp - 0x49]
mov r8d, r15d
mov rdx, r14
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_ReadFile]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r8, r15
mov rdx, r14
mov rcx, qword [rbp - 0x41]
call fcn.18015a580
lea rdx, [rbp - 9]
mov rcx, qword [rbp - 0x41]
call fcn.180159c10
nop
cmp qword [rbp + 7], r12
jbe 0x1801597cc
or r9, 0xffffffffffffffff
xor r8d, r8d
lea rdx, [rbp - 9]
lea rcx, [rbp - 0x29]
call fcn.18000c150
nop
cmp qword [rbp + 0xf], 0x10
jb 0x1801597dc
mov rcx, qword [rbp - 9]
call fcn.1800b5354
xor r14d, r14d
mov qword [rdi + 0x18], 0xf
mov qword [rdi + 0x10], r14
mov byte [rdi], 0
mov rcx, qword [rbp - 0x11]
cmp rcx, 0x10
jae 0x180159813
mov r8, qword [rbp - 0x19]
inc r8
je 0x18015981e
lea rdx, [rbp - 0x29]
mov rcx, rdi
call fcn.1800b54c0
mov rcx, qword [rbp - 0x11]
jmp 0x18015981e
mov rax, qword [rbp - 0x29]
mov qword [rdi], rax
mov qword [rbp - 0x29], r14
mov rax, qword [rbp - 0x19]
mov qword [rdi + 0x10], rax
mov qword [rdi + 0x18], rcx
mov byte [rbp - 0x29], 0
mov qword [rbp - 0x19], r14
mov qword [rbp - 0x11], 0xf
cmp qword [rbx + 0x18], 0x10
jb 0x180159849
mov rcx, qword [rbx]
call fcn.1800b5354
mov qword [rbx + 0x10], r14
mov qword [rbx + 0x18], 0xf
mov byte [rbx], 0
mov rax, rdi
mov rcx, qword [rbp + 0x17]
xor rcx, rsp
call fcn.1800b5370
mov rbx, qword [rsp + 0x108]
add rsp, 0xb0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret