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

Disassembly:
mov rax, rsp
push rbp
push rdi
push r12
push r14
push r15
mov rbp, rsp
sub rsp, 0x70
mov qword [rbp - 0x10], 0xfffffffffffffffe
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov r14, rdx
mov rdi, rcx
and dword [rbp - 0x30], 0
call fcn.140010fb4
mov rcx, rax
test rax, rax
jne 0x14008f4e0
mov ecx, 0x80004005
call fcn.140010d40
int3
mov rax, qword [rax]
call qword [rax + Ordinal_26]
lea rbx, [rax + 0x18]
mov qword [rbp - 0x28], rbx
mov rcx, qword [rdi + 0x10]
cmp dword [rcx - 0x10], 0
jne 0x14008f512
lea rdx, [rbp - 0x28]
mov rcx, r14
call fcn.140010a98
nop
lea rdx, [rbx - 0x18]
or rsi, 0xffffffffffffffff
jmp 0x14008f8a5
and qword [rsp + 0x30], 0
and dword [rsp + 0x28], 0
mov dword [rsp + 0x20], 3
xor r9d, r9d
xor r8d, r8d
mov edx, 0x80000000
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov r15, rax
or rsi, 0xffffffffffffffff
cmp rax, rsi
jne 0x14008f558
lea rdx, [rbp - 0x28]
mov rcx, r14
call fcn.140010a98
nop
lea rdx, [rbx - 0x18]
jmp 0x14008f8a5
and dword [rbp + 0x40], 0
xor edx, edx
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
lea ecx, [rdi + 1]
call fcn.14004cf38
mov r12, rax
mov byte [rdi + rax], 0
and qword [rsp + 0x20], 0
lea r9, [rbp + 0x40]
mov r8d, edi
mov rdx, rax
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x14008f5a0
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x14008f542
lea rdx, [0x1400bcee3]
lea rcx, [rbp - 0x20]
call fcn.1400109fc
nop
mov r8, r12
lea rdx, [0x1400bd164]
lea rcx, [rbp - 0x20]
call fcn.14000da78
mov rcx, r12
call fcn.14004c984
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_CloseHandle]
call fcn.140010fb4
mov rcx, rax
test rax, rax
jne 0x14008f5ed
mov ecx, 0x80004005
call fcn.140010d40
int3
mov rax, qword [rax]
call qword [rax + Ordinal_26]
add rax, 0x18
mov qword [rbp + 0x48], rax
mov dl, 0x75
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, reloc.WS2_32.dll_WSAStartup
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, 0x65
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, WSAStartup
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, 0x5f
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, reloc.WS2_32.dll_WSASetLastError
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, WSAStartup
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, 0x65
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, 0x66
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, Ordinal_41
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, Ordinal_35
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, 0x62
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, WSAStartup
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, reloc.WS2_32.dll_WSAGetLastError
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, 0x77
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, reloc.WS2_32.dll_WSAStartup
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, 0x65
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, WSAStartup
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, reloc.WLDAP32.dll_Ordinal_46
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, reloc.WS2_32.dll_WSAStartup
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, reloc.WS2_32.dll_WSACleanup
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, 0x61
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, WSAStartup
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, reloc.WS2_32.dll_WSACleanup
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, 0x75
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, reloc.WS2_32.dll_WSASetLastError
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, reloc.WLDAP32.dll_Ordinal_46
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, 0x68
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, reloc.WS2_32.dll_WSAGetLastError
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, 0x6d
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, 0x65
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, reloc.WS2_32.dll_WSASetLastError
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, 0x61
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, 0x67
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, 0x65
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, Ordinal_35
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov dl, Ordinal_45
lea rcx, [rbp + 0x48]
call fcn.140010c8c
mov rbx, qword [rbp + 0x48]
test rbx, rbx
je 0x14008f837
mov rcx, qword [rbp - 0x20]
cmp dword [rcx - 0x10], 0
jl 0x14008f837
mov rdx, rbx
call fcn.140060390
mov rdi, rax
test rax, rax
je 0x14008f837
mov rdx, qword [rbp - 0x20]
sub edi, edx
cmp edi, esi
je 0x14008f837
test edi, edi
js 0x14008f7ec
cmp edi, dword [rdx - 0x10]
jg 0x14008f7ec
movsxd rcx, edi
add rcx, rdx
lea rdx, [0x1400bdcb0]
call fcn.140060390
test rax, rax
je 0x14008f7ec
sub eax, dword [rbp - 0x20]
jmp 0x14008f7ee
mov eax, esi
sub eax, edi
lea r9d, [rax - 0x29]
lea r8d, [rdi + 0x27]
lea rdx, [rbp - 0x18]
lea rcx, [rbp - 0x20]
call fcn.140008220
nop
mov rdx, rax
lea rcx, [rbp - 0x28]
call fcn.140008b54
nop
mov rdx, qword [rbp - 0x18]
add rdx, 0xffffffffffffffe8
mov eax, esi
lock xadd dword [rdx + 0x10], eax
add eax, esi
test eax, eax
jg 0x14008f831
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_htonl]
mov rbx, qword [rbp + 0x48]
jmp 0x14008f856
lea rcx, str.default
call fcn.140051300
mov r8d, eax
lea rdx, str.default
lea rcx, [rbp - 0x28]
call fcn.140010888
lea rdx, [rbp - 0x28]
mov rcx, r14
call fcn.140010a98
nop
lea rdx, [rbx - 0x18]
mov eax, esi
lock xadd dword [rdx + 0x10], eax
add eax, esi
test eax, eax
jg 0x14008f87e
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_htonl]
nop
mov rdx, qword [rbp - 0x20]
add rdx, 0xffffffffffffffe8
mov eax, esi
lock xadd dword [rdx + 0x10], eax
add eax, esi
test eax, eax
jg 0x14008f89d
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_htonl]
nop
mov rdx, qword [rbp - 0x28]
add rdx, 0xffffffffffffffe8
mov eax, esi
lock xadd dword [rdx + 0x10], eax
add eax, esi
test eax, eax
jg 0x14008f8bb
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_htonl]
mov rax, r14
lea r11, [rsp + 0x70]
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop r12
pop rdi
pop rbp
ret