Function at 0x180053220
Capabilities:
Get file size
Read file on windows

Disassembly:
mov rax, rsp
push rbp
push r14
push r15
lea rbp, [rax - 0x5f]
sub rsp, 0xa0
mov qword [rbp - 0x29], 0xfffffffffffffffe
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
mov rax, qword [0x18028e088]
xor rax, rsp
mov qword [rbp + 0x37], rax
mov r14, r8
mov ebx, edx
mov rdi, rcx
xor r15d, r15d
mov qword [rbp - 9], r15
mov qword [rbp - 1], r15
mov qword [rbp - 9], r15
mov qword [rbp - 1], 7
mov word [rbp - 0x19], r15w
lea r8d, [r15 + 3]
lea rdx, [0x180221cc0]
lea rcx, [rbp - 0x19]
call fcn.1800089e0
nop
lea r9, [rbp - 0x19]
mov r8d, ebx
lea rdx, [rbp + 0x17]
mov rcx, rdi
call fcn.1800536b0
nop
mov rdx, qword [rbp - 1]
cmp rdx, 8
jb 0x1800532e2
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp - 0x19]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1800532dd
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x180053504
call fcn.1801ccd54
mov qword [rbp - 9], r15
mov qword [rbp - 1], 7
mov word [rbp - 0x19], r15w
cmp qword [rbp + 0x27], 0
jne 0x180053302
xor dil, dil
jmp 0x180053484
mov qword [rbp + 7], r15
mov ecx, 8
call fcn.1801cd4e0
mov qword [rbp + 0xf], rax
mov qword [rax], 0xffffffffffffffff
mov qword [rbp + 7], rax
lea rdx, [rbp + 0x17]
lea rcx, [rbp + 7]
call fcn.180098920
mov rbx, qword [rbp + 7]
test al, al
je 0x180053455
test rbx, rbx
je 0x180053455
mov rcx, qword [rbx]
cmp rcx, 0xffffffffffffffff
je 0x18005343b
lea rdx, [rbp + 0xf]
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
cmp eax, 0xffffffff
jne 0x18005336d
call qword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x18005343b
mov edi, dword [rbp + 0xf]
shl rdi, 0x20
add rdi, rsi
xor eax, eax
mov qword [rbp - 0x19], rax
mov qword [rbp - 0x11], rax
mov qword [rbp - 9], rax
mov qword [rbp - 0x19], r14
mov rsi, r15
mov qword [rbp - 0x11], r15
mov dword [rbp - 9], r15d
lea r14d, [rdi + 1]
cmp r14d, 1
jae 0x1800533a4
mov dword [rbp - 0x21], r15d
jmp 0x18005340b
lea ecx, [r14 + 1]
call fcn.1801cd51c
mov rsi, rax
mov qword [rbp - 0x11], rax
mov byte [rax], 0
mov dword [rbp - 9], r14d
mov dword [rbp - 0x21], r15d
cmp qword [rbx], 0xffffffffffffffff
je 0x1800533fe
mov qword [rsp + 0x20], r15
lea r9, [rbp - 0x21]
mov r8d, edi
mov rdx, rax
mov rcx, qword [rbx]
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1800533fe
mov eax, dword [rbp - 0x21]
cmp eax, edi
jne 0x1800533fe
mov byte [rax + rsi], 0
lea rcx, [rbp - 0x19]
call fcn.180053dc0
mov dil, 1
mov rsi, qword [rbp - 0x11]
jmp 0x180053428
lea rcx, [rbp - 0x19]
call fcn.180053dc0
mov rsi, qword [rbp - 0x11]
mov rcx, qword [rbx]
cmp rcx, 0xffffffffffffffff
je 0x180053425
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
je 0x180053425
mov qword [rbx], 0xffffffffffffffff
xor dil, dil
test rsi, rsi
je 0x180053458
mov rcx, rsi
call fcn.1801ccd54
mov qword [rbp - 0x11], r15
jmp 0x180053458
mov rcx, qword [rbx]
cmp rcx, 0xffffffffffffffff
je 0x180053455
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
je 0x180053455
mov qword [rbx], 0xffffffffffffffff
xor dil, dil
test rbx, rbx
je 0x180053484
mov rcx, qword [rbx]
lea rax, [rcx - 1]
cmp rax, 0xfffffffffffffffd
ja 0x180053473
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov qword [rbx], r15
mov edx, 8
mov rcx, rbx
call fcn.1801ccd54
mov qword [rbp + 7], r15
mov rdx, qword [rbp + 0x2f]
cmp rdx, 8
jb 0x1800534c0
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp + 0x17]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1800534bb
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1800534fe
call fcn.1801ccd54
mov qword [rbp + 0x27], r15
mov qword [rbp + 0x2f], 7
mov word [rbp + 0x17], r15w
movzx eax, dil
mov rcx, qword [rbp + 0x37]
xor rcx, rsp
call fcn.1801ccd30
lea r11, [rsp + 0xa0]
mov rbx, qword [r11 + 0x28]
mov rsi, qword [r11 + 0x30]
mov rdi, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop rbp
ret
call fcn.1801d1a6c
nop
call fcn.1801d1a6c
nop
int3