Function at 0x140001dc0
Capabilities:
Read file on windows

Disassembly:
push r14
push r13
push r12
push rsi
push rbx
add rsp, 0xffffffffffffff80
lea rdx, [0x14002312c]
mov rsi, rcx
call fcn.140004a20
mov r12, rax
test rax, rax
je 0x140002020
mov rax, qword [0x1400292a0]
lea r14, [rsp + 0x20]
mov rcx, r12
xor r13d, r13d
mov r8d, 8
mov rdx, r14
mov rax, qword [rax]
mov qword [rsp + 0x20], rax
shr rax, 0x18
add eax, 0xc
mov byte [rsp + 0x23], al
call fcn.140008b70
mov rbx, rax
test rax, rax
jne 0x140001e40
mov rcx, r12
call sub.msvcrt.dll_fclose
mov rax, r13
sub rsp, 0xffffffffffffff80
pop rbx
pop rsi
pop r12
pop r13
pop r14
ret
xor r8d, r8d
mov edx, eax
mov rcx, r12
call fcn.140019ac0
test eax, eax
js 0x140002038
mov r9, r12
mov r8d, 1
mov edx, 0x58
mov rcx, r14
call sub.msvcrt.dll_fread
test rax, rax
je 0x140002060
mov edx, 0x1070
mov ecx, 1
call sub.msvcrt.dll_calloc
mov r13, rax
test rax, rax
je 0x140002091
mov r9, rsi
lea r8, [0x140023129]
mov edx, 0x1000
mov rcx, rax
call fcn.140001970
mov eax, dword [rsp + 0x28]
lea r9, [rsp + 0x38]
lea rcx, [r13 + 0x102c]
lea r8, [0x140023129]
mov edx, 0x40
bswap eax
mov dword [rsp + 0x28], eax
mov eax, dword [rsp + 0x2c]
bswap eax
mov dword [rsp + 0x2c], eax
mov eax, dword [rsp + 0x30]
bswap eax
mov dword [rsp + 0x30], eax
mov eax, dword [rsp + 0x34]
bswap eax
mov dword [r13 + 0x1028], eax
mov dword [rsp + 0x34], eax
call fcn.140001970
mov eax, dword [rsp + 0x28]
xor r8d, r8d
mov rcx, r12
sub rbx, rax
lea rdx, [rbx + 0x58]
mov qword [r13 + 0x1000], rdx
add edx, dword [rsp + 0x2c]
call fcn.140019ac0
mov r14d, dword [rsp + 0x30]
mov rcx, r14
call sub.msvcrt.dll_malloc
mov qword [r13 + 0x1008], rax
mov rcx, rax
test rax, rax
je 0x1400020b1
mov r9, r12
mov r8d, 1
mov rdx, r14
call sub.msvcrt.dll_fread
test rax, rax
je 0x140002000
mov eax, dword [rsp + 0x30]
add rax, qword [r13 + 0x1008]
mov rcx, r12
mov qword [r13 + 0x1010], rax
call sub.msvcrt.dll_ferror
test eax, eax
jne 0x140002080
mov rax, qword [r13 + 0x1008]
mov r9, qword [r13 + 0x1010]
cmp rax, r9
jae 0x140001e22
movzx r10d, byte [r13 + 0x1018]
lea r8, [0x1400233e8]
nop dword [rax]
mov ecx, dword [rax + 4]
movzx r11d, byte [rax + 0x11]
mov edx, dword [rax]
bswap ecx
mov dword [rax + 4], ecx
mov ecx, dword [rax + 8]
bswap edx
mov dword [rax], edx
bswap ecx
mov dword [rax + 8], ecx
mov ecx, dword [rax + 0xc]
bswap ecx
mov dword [rax + 0xc], ecx
lea ecx, [r11 - 0x5a]
cmp cl, 0x1e
ja case.0x140001fce.1
movzx ecx, cl
movsxd rcx, dword [r8 + rcx*4]
add rcx, r8
jmp rcx
mov r10d, 1
cmp r11b, 0x6c
jne 0x140001fe3
mov qword [r13 + 0x1020], rax
mov edx, edx
add rax, rdx
cmp r9, rax
ja 0x140001f98
mov byte [r13 + 0x1018], r10b
jmp 0x140001e22
call qword [sym.imp.msvcrt.dll__errno]
lea r8, str.Could_not_read_full_TOC__n
lea rcx, str.fread
mov edx, dword [rax]
call fcn.140002cd0
jmp 0x140001e22
xor r13d, r13d
mov rax, r13
sub rsp, 0xffffffffffffff80
pop rbx
pop rsi
pop r12
pop r13
pop r14
ret
call qword [sym.imp.msvcrt.dll__errno]
lea r8, str.Failed_to_seek_to_cookie_position__n
lea rcx, str.fseek
mov edx, dword [rax]
call fcn.140002cd0
jmp 0x140001e22
call qword [sym.imp.msvcrt.dll__errno]
lea r8, str.Failed_to_read_cookie__n
lea rcx, str.fread
mov edx, dword [rax]
call fcn.140002cd0
jmp 0x140001e22
lea rcx, str.Error_on_file._n
call fcn.140002bc0
jmp 0x140001e22
call qword [sym.imp.msvcrt.dll__errno]
lea r8, str.Could_not_allocate_memory_for_archive_structure__n
lea rcx, [0x14002338a]
mov edx, dword [rax]
call fcn.140002cd0
jmp 0x140001e22
call qword [sym.imp.msvcrt.dll__errno]
lea r8, str.Could_not_allocate_buffer_for_TOC__n
lea rcx, str.malloc
mov edx, dword [rax]
call fcn.140002cd0
jmp 0x140001e22