Function at 0x14000d060
Capabilities:
Read file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x58
mov rdi, rdx
mov rsi, rcx
mov rax, qword [0x140045010]
xor rax, rsp
mov qword [rsp + 0x50], rax
cmp dword [rcx + 0x810], 0
je 0x14000d16c
mov rcx, rdi
call fcn.140021140
mov rcx, rdi
mov rdx, rax
call fcn.140001540
movzx eax, al
lea rbx, [rsi + rax*8]
add rbx, 8
mov rbx, qword [rbx]
lea rcx, [rbx + 0x14]
mov rdx, rdi
call fcn.140020f50
test eax, eax
jne 0x14000d0b0
mov ebp, dword [rbx + 0xc]
test ebp, ebp
je 0x14000d3b2
mov r14d, dword [rbx + 8]
mov ecx, 0x10
call fcn.140020e74
test rax, rax
je 0x14000d397
mov qword [rax], 0
mov dword [rax + 8], r14d
mov dword [rax + 0xc], ebp
mov rdx, qword [rsi + 0x808]
test rdx, rdx
je 0x14000d3d3
lea r8d, [r14 + rbp]
dec r8d
mov rdi, rdx
mov ebp, dword [rdx + 8]
mov ecx, dword [rdx + 0xc]
lea esi, [rcx + rbp]
dec esi
cmp ebp, r14d
ja 0x14000d126
cmp esi, r14d
jae 0x14000d38f
cmp esi, r14d
setae r10b
cmp r8d, ebp
setb r11b
cmp r8d, esi
seta r9b
cmp ebp, r14d
setb cl
cmp esi, r8d
setbe dl
test r10b, dl
jne 0x14000d38f
and cl, r9b
or r11b, cl
je 0x14000d38f
mov rdx, qword [rdi]
test rdx, rdx
jne 0x14000d10a
mov qword [rdi], rax
jmp 0x14000d3b2
mov rcx, qword [rsi]
xor edx, edx
xor r8d, r8d
call fcn.14001b4e8
mov r9, qword [rsi]
lea rcx, [rsp + 0x4c]
mov edx, 4
mov r8d, 1
call fcn.1400206ec
cmp rax, 1
jne 0x14000d3b0
cmp dword [rsp + 0x4c], 0x3152414d
jne 0x14000d3b0
mov r9, qword [rsi]
lea rcx, [rsp + 0x48]
mov edx, 4
mov r8d, 1
call fcn.1400206ec
cmp rax, 1
jne 0x14000d3b0
mov ecx, dword [rsp + 0x48]
call qword [sym.imp.WSOCK32.dll_ntohl]
mov dword [rsp + 0x48], eax
mov rcx, qword [rsi]
mov edx, eax
xor r8d, r8d
call fcn.14001b4e8
test eax, eax
jne 0x14000d3b0
mov r9, qword [rsi]
lea rcx, [rsp + 0x44]
mov edx, 4
mov r8d, 1
call fcn.1400206ec
cmp rax, 1
jne 0x14000d3b0
mov ecx, dword [rsp + 0x44]
call qword [sym.imp.WSOCK32.dll_ntohl]
mov dword [rsp + 0x44], eax
mov ebp, eax
mov rcx, rbp
call fcn.140020e74
test rax, rax
je 0x14000d3b0
mov r13, rax
mov r9, qword [rsi]
mov r8d, 1
mov rcx, rax
mov rdx, rbp
call fcn.1400206ec
cmp rax, 1
jne 0x14000d3dc
mov r12, r13
add r12, rbp
mov qword [rsp + 0x28], r13
test ebp, ebp
je 0x14000d3eb
lea rax, [r12 - 1]
mov qword [rsp + 0x38], rax
mov rbx, qword [sym.imp.WSOCK32.dll_ntohl]
mov r13, qword [rsp + 0x28]
mov rax, r12
sub rax, r13
cmp rax, 0xe
jl 0x14000d3eb
mov ecx, dword [r13]
mov ebp, dword [r13 + 4]
mov r15d, dword [r13 + 8]
lea r14, [r13 + 0xc]
call rbx
mov dword [rsp + 0x24], eax
mov ecx, ebp
call rbx
mov ebp, eax
mov ecx, r15d
call rbx
cmp byte [r13 + 0xc], 0
mov qword [rsp + 0x30], r14
mov rcx, r14
je 0x14000d2d9
add r13, 0xd
cmp r12, r13
je 0x14000d3e6
lea rcx, [r13 + 1]
cmp byte [r13], 0
mov r13, rcx
jne 0x14000d2bf
dec rcx
cmp rcx, r12
je 0x14000d409
mov r15, rcx
sub r15, qword [rsp + 0x30]
test r15d, r15d
js 0x14000d409
mov ebx, eax
mov r14d, ebp
mov r13, rcx
inc r13
mov ecx, r15d
add rcx, 0x18
call fcn.140020e74
test rax, rax
je 0x14000d3eb
mov rbp, rax
mov qword [rax], 0
mov eax, dword [rsp + 0x24]
mov dword [rbp + 8], eax
mov dword [rbp + 0xc], r14d
mov dword [rbp + 0x10], ebx
mov rcx, rbp
add rcx, 0x14
inc r15d
mov r14, qword [rsp + 0x30]
mov rdx, r14
mov r8, r15
call fcn.140027350
mov rcx, r14
call fcn.140021140
mov rcx, r14
mov rdx, rax
call fcn.140001540
movzx eax, al
mov rcx, qword [rsi + rax*8 + 8]
test rcx, rcx
je 0x14000d372
mov rax, rcx
mov rcx, qword [rcx]
test rcx, rcx
jne 0x14000d365
jmp 0x14000d37a
lea rax, [rsi + rax*8]
add rax, 8
mov rbx, qword [sym.imp.WSOCK32.dll_ntohl]
mov qword [rax], rbp
cmp r13, r12
jb 0x14000d27b
jmp 0x14000d3eb
mov rcx, rax
call fcn.14002099c
mov ecx, 2
call fcn.1400135c8
lea rdx, str.ERROR:_file_content_collision_in_mar_find_item___n
mov rcx, rax
call fcn.140001260
xor ebx, ebx
mov rcx, qword [rsp + 0x50]
xor rcx, rsp
call fcn.140023680
mov rax, rbx
add rsp, 0x58
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
mov qword [rsi + 0x808], rax
jmp 0x14000d3b2
mov rcx, r13
call fcn.14002099c
jmp 0x14000d3b0
mov r13, qword [rsp + 0x38]
mov rcx, qword [rsp + 0x28]
call fcn.14002099c
cmp r13, r12
jne 0x14000d3b0
mov dword [rsi + 0x810], 1
jmp 0x14000d092
mov r13, rcx
jmp 0x14000d3eb