Function at 0x140004044
Capabilities:
Read file on windows

Disassembly:
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x140
lea rbp, [rsp + 0x30]
mov qword [rbp + 0x160], rbx
mov rax, qword [0x1402bcf00]
xor rax, rbp
mov qword [rbp + 0x100], rax
xor r15d, r15d
mov qword [rbp + 0x10], rdx
mov r12, rdx
mov dword [rsp + 0x28], 0x1000
mov r8, rcx
mov qword [rbp], r15
lea rbx, [0x1402c1b20]
xor edx, edx
mov ecx, 0xfde9
mov qword [rsp + 0x20], rbx
or r9d, 0xffffffff
mov r13d, r15d
mov r14d, r15d
call qword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
lea r8, [0x140250bfc]
mov rdx, rbx
lea rcx, [rbp]
call fcn.1401c9210
mov rcx, qword [rbp]
test rcx, rcx
jne 0x1400040d4
lea eax, [rcx + 1]
jmp 0x14000441c
xor r8d, r8d
mov dword [rbp + 8], r15d
xor edx, edx
call fcn.1401c9b7c
mov r9, qword [rbp]
lea rdi, [0x1402c4b20]
mov esi, 1
mov rcx, rdi
mov edx, esi
lea r8d, [rsi + 1]
call fcn.1401caf74
movzx ecx, word [0x1402c4b20]
call qword [sym.imp.WS2_32.dll_ntohs]
mov ecx, 0x4d5a
cmp ax, cx
jne 0x14000424b
mov rcx, qword [rbp]
lea edx, [rsi + 0x3b]
xor r8d, r8d
call fcn.1401c9b7c
mov r9, qword [rbp]
lea r8d, [rsi + 3]
mov edx, esi
lea rcx, [rbp + 8]
call fcn.1401caf74
mov edx, dword [rbp + 8]
xor r8d, r8d
mov rcx, qword [rbp]
call fcn.1401c9b7c
mov r13d, dword [rbp + 8]
lea r8d, [rsi + 0x17]
mov r9, qword [rbp]
mov edx, esi
mov rcx, rdi
add r13d, 0x58
call fcn.1401caf74
cmp dword [0x1402c4b20], 0x4550
jne 0x140004411
movzx edx, word [0x1402c4b34]
lea rax, [rdx + 0x38]
lea rcx, [rax + 0xf]
cmp rcx, rax
ja 0x140004194
movabs rcx, 0xffffffffffffff0
and rcx, 0xfffffffffffffff0
mov rax, rcx
call fcn.1401c27d0
sub rsp, rcx
mov r9d, esi
mov r8d, 8
lea rcx, [rsp + 0x30]
call fcn.14008f710
mov rdx, rsi
mov rbx, rax
mov r8, qword [rax - 0x18]
lea rcx, [rax + 8]
mov qword [rax], rcx
mov rcx, rax
mov r9, qword [rbp]
call fcn.1401caf74
cmp qword [rbx - 0x18], 4
jbe 0x140004411
movzx eax, word [rbx]
cmp eax, 0x10b
je 0x14000421c
cmp eax, 0x20b
jne 0x140004411
cmp qword [rbx - 0x18], 0x94
jb 0x140004411
mov eax, dword [rbx + 0x90]
mov ebx, r15d
mov r14d, dword [rbp + 8]
test eax, eax
cmovne ebx, eax
add r14d, 0xa8
jmp 0x140004243
cmp qword [rbx - 0x18], 0x84
jb 0x140004411
mov eax, dword [rbx + 0x80]
mov ebx, r15d
mov r14d, dword [rbp + 8]
test eax, eax
cmovne ebx, eax
add r14d, 0x98
test ebx, ebx
jne 0x1400042eb
mov rcx, qword [rbp]
mov edx, 0xfffffff0
mov dword [rbp + 0xc], r15d
lea r8d, [rdx + 0x12]
call fcn.1401c9b7c
mov r9, qword [rbp]
mov r8d, reloc.WS2_32.dll_recv
mov rdx, rsi
mov rcx, rdi
call fcn.1401caf74
mov rax, qword [0x1402c4b20]
cmp rax, qword [0x1402bdb30]
jne 0x1400042e0
mov rax, qword [0x1402c4b28]
cmp rax, qword [0x1402bdb38]
jne 0x1400042e0
mov rcx, qword [rbp]
mov r8d, esi
mov edx, 0xffffffec
call fcn.1401c9b7c
mov r9, qword [rbp]
lea rcx, [rbp + 0xc]
mov r8d, 4
mov rdx, rsi
call fcn.1401caf74
mov ecx, dword [rbp + 0xc]
call qword [sym.imp.WS2_32.dll_ntohl]
mov rcx, qword [rbp]
mov dword [rbp + 0xc], eax
call fcn.1401c4e9c
mov ebx, eax
mov eax, 0xfffffffc
sub eax, dword [rbp + 0xc]
add ebx, eax
jmp 0x1400042eb
mov rcx, qword [rbp]
call fcn.1401c4e9c
mov ebx, eax
lea rcx, [rbp + 0x20]
call fcn.1400b50f0
mov rcx, qword [rbp]
xor r8d, r8d
xor edx, edx
mov edi, ebx
call fcn.1401c9b7c
test r13d, r13d
je 0x140004387
mov r9, qword [rbp]
lea r8d, [r13 + 4]
mov rdx, rsi
lea rcx, [0x1402c4b20]
call fcn.1401caf74
mov r15, rax
mov ecx, r13d
lea rax, [0x1402c4b20]
mov r8, r15
mov rdx, rax
and dword [rcx + rax], 0
lea rcx, [rbp + 0x20]
call fcn.1400b5180
test ebx, ebx
je 0x140004347
sub edi, r15d
mov r9, qword [rbp]
sub r14d, r13d
lea r13, [0x1402c4b20]
mov rdx, rsi
mov rcx, r13
lea r8d, [r14 + 4]
call fcn.1401caf74
xor r15d, r15d
lea rcx, [rbp + 0x20]
mov r8, rax
mov rdx, r13
mov r14, rax
mov qword [rax + r13 - 8], r15
call fcn.1400b5180
test ebx, ebx
je 0x14000438e
sub edi, r14d
jmp 0x14000438e
lea r13, [0x1402c4b20]
mov r9, qword [rbp]
mov eax, 0x1000
cmp edi, eax
mov r8d, edi
mov rdx, rsi
mov rcx, r13
cmova r8d, eax
test ebx, ebx
cmove r8d, eax
call fcn.1401caf74
mov r14, rax
test rax, rax
je 0x140004402
mov r12d, 0x1000
mov r8, r14
lea rcx, [rbp + 0x20]
mov rdx, r13
call fcn.1400b5180
test ebx, ebx
je 0x1400043d7
sub edi, r14d
je 0x1400043fe
mov r9, qword [rbp]
cmp edi, r12d
mov r8d, edi
mov rdx, rsi
cmova r8, r12
mov rcx, r13
test ebx, ebx
cmove r8, r12
call fcn.1401caf74
mov r14, rax
test rax, rax
jne 0x1400043bf
mov r12, qword [rbp + 0x10]
lea rdx, [rbp + 0x20]
mov rcx, r12
call fcn.1400b50d0
mov esi, r15d
mov rcx, qword [rbp]
call fcn.1401c97c0
mov eax, esi
mov rcx, qword [rbp + 0x100]
xor rcx, rbp
call fcn.1401c2260
mov rbx, qword [rbp + 0x160]
lea rsp, [rbp + 0x110]
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret