Function at 0x180015d30
Capabilities:
Send data
Send data on socket

Disassembly:
push rdi
mov eax, 0x1080
call fcn.180011720
sub rsp, rax
mov rax, qword [0x180068020]
xor rax, rsp
mov qword [rsp + 0x1050], rax
cmp qword [rcx], 0xffffffffffffffff
mov rdi, rcx
jne 0x180015d70
lea rdx, str.trying_to_write_but_not_connected
call fcn.180011ef0
mov eax, 0xffffffff
jmp 0x180016001
mov qword [rsp + 0x1098], rbx
mov rbx, qword [rcx + 0xb8]
mov qword [rsp + 0x10a0], rbp
mov qword [rsp + 0x10a8], rsi
mov qword [rsp + 0x1078], r12
mov qword [rsp + 0x1070], r13
mov qword [rsp + 0x1068], r14
mov qword [rsp + 0x1060], r15
test rbx, rbx
je 0x180015fc7
xor r12d, r12d
mov r13d, 0x202
mov rbp, qword [rbx + 0xa8]
mov r10d, 1
movzx r15d, word [rbx + 0xe]
mov r11d, r10d
mov esi, r12d
mov r14d, r12d
mov r9, rbx
nop
add r14d, r15d
mov r8d, r12d
cmp dword [r9 + 0xb8], r12d
jle 0x180015e3b
mov rax, r11
lea rdx, [rsp + 0x50]
shl rax, 4
lea rcx, [r9 + 0xc8]
add rdx, rax
nop word [rax + rax]
mov rax, qword [rcx - 8]
lea rcx, [rcx + 0x18]
mov qword [rdx + 8], rax
lea rdx, [rdx + 0x10]
mov eax, dword [rcx - 0x18]
inc r8d
mov dword [rdx - 0x10], eax
inc r10d
add esi, dword [rcx - 0x18]
inc r11
cmp r8d, dword [r9 + 0xb8]
jl 0x180015e10
mov r9, qword [r9 + 0x48]
test r9, r9
jne 0x180015de0
cmp word [rdi + 0x1988], r13w
jbe 0x180015e58
cmp r14d, dword [rdi + 0x70]
ja 0x180015fc7
mov dword [rsp + 0x50], 4
mov eax, esi
lea rdx, [rsp + 0x50]
bswap eax
mov dword [rsp + 0x40], eax
lea rax, [rsp + 0x40]
mov qword [rsp + 0x58], rax
cmp rbp, 4
jb 0x180015ea1
mov eax, 4
nop dword [rax]
nop word [rax + rax]
add rdx, 0x10
sub rbp, rax
dec r10d
mov eax, dword [rdx]
cmp rbp, rax
jae 0x180015e90
mov rcx, qword [rdi]
lea r9, [rsp + 0x44]
add qword [rdx + 8], rbp
mov r8d, r10d
sub dword [rdx], ebp
mov qword [rsp + 0x30], r12
mov qword [rsp + 0x28], r12
mov dword [rsp + 0x20], r12d
call qword [sym.imp.WS2_32.dll_WSASend]
test eax, eax
mov ecx, 0xffffffff
cmove ecx, dword [rsp + 0x44]
movsxd rax, ecx
cmp rax, 0xffffffffffffffff
je 0x18001601a
add qword [rbx + 0xa8], rax
lea ecx, [rsi + 4]
cmp qword [rbx + 0xa8], rcx
jne 0x180015fb7
mov r9, qword [rdi + 0xb8]
cmp r9, rbx
jne 0x180015f08
mov r9, qword [rbx]
jmp 0x180015f4e
mov rcx, qword [r9]
mov rdx, r9
test rcx, rcx
je 0x180015f40
mov r8, r9
nop word [rax + rax]
mov rax, rcx
mov rdx, r8
cmp rcx, rbx
je 0x180015f40
mov qword [rdi + 0xb8], rcx
mov r8, rax
mov rcx, qword [rcx]
mov rdx, rax
test rcx, rcx
jne 0x180015f20
mov rax, qword [rdx]
test rax, rax
je 0x180015f4e
mov rax, qword [rax]
mov qword [rdx], rax
mov qword [rdi + 0xb8], r9
nop word [rax + rax]
mov r8, qword [rbx + 0x48]
movzx eax, word [rbx + 0xe]
mov qword [rbx + 0x48], r12
sub dword [rdi + 0x70], eax
mov rdx, qword [rdi + 0xc0]
test rdx, rdx
jne 0x180015f80
mov rdx, rbx
jmp 0x180015fa5
mov rcx, qword [rdx]
mov rax, rdx
test rcx, rcx
je 0x180015fa2
nop dword [rax + rax]
mov rax, rcx
mov qword [rdi + 0xc0], rcx
mov rcx, qword [rcx]
test rcx, rcx
jne 0x180015f90
mov qword [rax], rbx
mov qword [rbx], r12
mov rbx, r8
mov qword [rdi + 0xc0], rdx
test r8, r8
jne 0x180015f60
mov rbx, qword [rdi + 0xb8]
test rbx, rbx
jne 0x180015dc1
xor eax, eax
mov r14, qword [rsp + 0x1068]
mov r13, qword [rsp + 0x1070]
mov r12, qword [rsp + 0x1078]
mov rsi, qword [rsp + 0x10a8]
mov rbp, qword [rsp + 0x10a0]
mov rbx, qword [rsp + 0x1098]
mov r15, qword [rsp + 0x1060]
mov rcx, qword [rsp + 0x1050]
xor rcx, rsp
call fcn.180010bf0
add rsp, 0x1080
pop rdi
ret
call fcn.18002cb90
cmp dword [rax], 0xb
je 0x180015fc7
call fcn.18002cb90
cmp dword [rax], 0x8c
je 0x180015fc7
call fcn.18002cb90
mov rcx, rdi
mov rbx, rax
call fcn.180011dc0
mov r8d, dword [rbx]
lea rdx, str.Error_when_writing_to_socket_:_d__s
mov r9, rax
mov rcx, rdi
call fcn.180011ef0
mov eax, 0xffffffff
jmp 0x180015fc9