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

Disassembly:
push rbp
push rbx
push rsi
push rdi
push r12
push r13
push r14
mov rbp, rsp
sub rsp, 0x50
xor ebx, ebx
mov qword [rsp + 0x90], r15
mov dword [rdx], ebx
lea r13, [0x140000000]
movzx r12d, r8b
mov r14, rdx
mov rsi, rcx
nop
mov rcx, qword [rsi + 0x70]
lea r9, [rbp - 0x20]
mov r8d, 4
mov dword [rbp - 0x20], ebx
lea rdx, [rbp + 0x58]
mov qword [rsp + 0x20], rbx
call qword [sym.imp.KERNEL32.dll_ReadFile]
mov rcx, qword [rsi + 0x70]
lea r8, [rbp - 0x20]
mov r9d, 1
mov qword [rbp - 0x20], rbx
mov rdx, rbx
call qword [sym.imp.KERNEL32.dll_SetFilePointerEx]
mov rcx, qword [rsi + 0x70]
lea rdx, [rbp - 0x18]
test eax, eax
mov rdi, 0xffffffffffffffff
cmovne rdi, qword [rbp - 0x20]
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
mov rcx, rbx
cmovne rcx, qword [rbp - 0x18]
cmp rdi, rcx
jge case.0x14007d8d8.0
movzx eax, byte [rbp + 0x5a]
movzx edi, byte [rbp + 0x5b]
shl edi, 8
add edi, eax
movzx eax, byte [rbp + 0x59]
shl edi, 8
add edi, eax
movzx eax, byte [rbp + 0x58]
cmp eax, 9
ja case.0x14007d8d8.3
mov ecx, dword [r13 + rax*4 + 0x7db38]
add rcx, r13
jmp rcx
test r12b, r12b
je case.0x14007d8d8.3
mov ecx, edi
call fcn.1400b609c
mov r15, rax
test rax, rax
je 0x14007d9ed
mov rcx, qword [rsi + 0x70]
lea r9, [rbp - 0x20]
mov r8d, edi
mov dword [rbp - 0x20], ebx
mov rdx, rax
mov qword [rsp + 0x20], rbx
call qword [sym.imp.KERNEL32.dll_ReadFile]
lea rcx, [rsi + 0x58]
mov r9d, edi
mov r8, r15
mov edx, recv
call fcn.140025fb0
mov rcx, r15
call fcn.1400b60a4
jmp 0x14007d9ed
mov rcx, qword [rsi + 0x70]
lea r9, [rbp - 0x20]
mov r8d, 4
mov dword [rbp - 0x20], ebx
lea rdx, [rbp + 0x48]
mov qword [rsp + 0x20], rbx
call qword [sym.imp.KERNEL32.dll_ReadFile]
movzx ecx, byte [rbp + 0x4a]
cmp cl, 3
ja 0x14007db0b
test r12b, r12b
je 0x14007d9d0
cmp byte [rbp + 0x4b], 1
mov eax, ebx
sete al
inc eax
cmp ecx, dword [rsi + 0x2c8]
jne 0x14007d981
mov r8d, dword [rsi + 0x20]
cmp eax, r8d
je 0x14007d9b6
inc dword [rsi + 0x2cc]
lea rdx, [rsi + 0x2ac]
mov dword [rsi + 0x2c8], ecx
mov dword [rsi + 0x20], eax
call fcn.14007edf0
mov r9d, 0xffffffff
lea rcx, [rsi + 0x58]
mov r8, rax
lea edx, [r9 + 3]
call fcn.140025fb0
mov r8d, dword [rsi + 0x20]
movzx ecx, word [rbp + 0x48]
mov eax, 0xf0bdc000
cdq
sub ecx, 0x10000
idiv ecx
xor edx, edx
div r8d
mov dword [rsi + 0x28], eax
mov edx, edi
sub rdx, 4
jmp 0x14007d9da
mov edx, edi
mov rcx, qword [rsi + 0x70]
mov r9d, 1
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_SetFilePointerEx]
cmp dword [r14], ebx
je 0x14007d840
jmp case.0x14007d8d8.0
mov rcx, qword [rsi + 0x70]
lea r9, [rbp - 0x20]
mov r8d, 2
mov dword [rbp - 0x20], ebx
lea rdx, [rbp + 0x48]
mov qword [rsp + 0x20], rbx
call qword [sym.imp.KERNEL32.dll_ReadFile]
movzx eax, byte [rbp + 0x49]
cmp al, 3
ja 0x14007db0b
test r12b, r12b
je 0x14007da84
mov ecx, eax
cmp eax, dword [rsi + 0x2c8]
je 0x14007da64
inc dword [rsi + 0x2cc]
lea rdx, [rsi + 0x2ac]
mov dword [rsi + 0x2c8], eax
call fcn.14007edf0
mov r9d, 0xffffffff
lea rcx, [rsi + 0x58]
mov r8, rax
lea edx, [r9 + 3]
call fcn.140025fb0
movzx eax, word [rbp + 0x48]
test al, al
je 0x14007da84
movzx ecx, al
mov r8d, 0x100
mov eax, 0xf4240
sub r8d, ecx
cdq
idiv r8d
mov dword [rsi + 0x28], eax
add edi, 0xfffffffe
jmp case.0x14007d8d8.2
mov rcx, qword [rsi + 0x70]
lea r9, [rbp + 0x48]
mov r8d, recv
mov dword [rbp + 0x48], ebx
lea rdx, [rbp - 0x18]
mov qword [rsp + 0x20], rbx
call qword [sym.imp.KERNEL32.dll_ReadFile]
test r12b, r12b
je 0x14007db19
movzx ecx, word [rbp - 0x12]
movzx edx, byte [rbp - 0x13]
cmp ecx, dword [rsi + 0x2c8]
jne 0x14007dac6
cmp edx, dword [rsi + 0x20]
je 0x14007db12
inc dword [rsi + 0x2cc]
mov dword [rsi + 0x20], edx
lea rdx, [rsi + 0x2ac]
mov dword [rsi + 0x2c8], ecx
call fcn.14007edf0
mov r9d, 0xffffffff
lea rcx, [rsi + 0x58]
mov r8, rax
lea edx, [r9 + 3]
call fcn.140025fb0
mov edx, 2
lea rcx, [rsi + 0x58]
call fcn.140025da0
cmp word [rax], 0x3f
jne 0x14007db12
mov eax, 0x8004020b
jmp 0x14007db21
movzx eax, word [rbp - 0x18]
mov dword [rsi + 0x28], eax
add edi, 0xfffffff4
mov dword [r14], edi
xor eax, eax
mov r15, qword [rsp + 0x90]
add rsp, 0x50
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret