Function at 0x1400d45a0
Capabilities:
Connect socket
Set socket configuration

Disassembly:
push rbp
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbx
sub rsp, 0x478
lea rbp, [rsp + 0x80]
movaps xmmword [rbp + 0x3e0], xmm6
mov qword [rbp + 0x3d8], 0xfffffffffffffffe
mov r14d, r9d
mov rbx, r8
mov r15, rdx
mov rsi, rcx
mov dword [rbp + 0x1b0], 1
mov rdi, qword [rcx]
lea r8, [rbp + 0x1b0]
mov rcx, rdi
mov edx, 0x8004667e
call qword [sym.imp.WS2_32.dll_ioctlsocket]
cmp eax, 0xffffffff
je 0x1400d4660
cmp word [r15], 0
je 0x1400d4675
movups xmm0, xmmword [r15 + 4]
movups xmm1, xmmword [r15 + 0x10]
movups xmmword [rbp + 0x1bc], xmm1
movaps xmmword [rbp + 0x1b0], xmm0
lea r13, [rbp + 0x1b0]
mov rcx, r13
call fcn.1400e2e40
mov r15d, eax
rol r15w, 8
mov rcx, r13
call fcn.1400ce530
movups xmm6, xmmword [rax]
mov rcx, r13
call fcn.1400e2e50
mov r12d, eax
mov rcx, r13
call fcn.1400e2e60
mov r8d, 0x1c
mov cx, 0x17
jmp 0x1400d46ba
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, eax
shl rsi, 0x20
or rsi, 2
jmp 0x1400d493a
mov eax, dword [r15 + 2]
movzx ecx, word [r15 + 6]
mov word [rbp + 0x1b4], cx
mov dword [rbp + 0x1b0], eax
lea r12, [rbp + 0x1b0]
mov rcx, r12
call fcn.1400e2e10
mov r15d, eax
rol r15w, 8
mov rcx, r12
call fcn.1400ce530
mov r12d, dword [rax]
xorps xmm6, xmm6
mov r8d, reloc.WS2_32.dll_recv
mov cx, 2
mov word [rbp + 0x1b0], cx
mov word [rbp + 0x1b2], r15w
mov dword [rbp + 0x1b4], r12d
movups xmmword [rbp + 0x1b8], xmm6
mov dword [rbp + 0x1c8], eax
lea rdx, [rbp + 0x1b0]
mov rcx, rdi
call qword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
je 0x1400d46f7
xor r12d, r12d
jmp 0x1400d4708
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov r12d, eax
shl r12, 0x20
or r12, 2
mov dword [rbp + 0x1b0], 0
lea r8, [rbp + 0x1b0]
mov rcx, rdi
mov edx, 0x8004667e
call qword [sym.imp.WS2_32.dll_ioctlsocket]
cmp eax, 0xffffffff
je 0x1400d475a
test r12, r12
je 0x1400d4776
mov r15d, r12d
and r15d, 3
lea rax, [0x1400d4a80]
movsxd rcx, dword [rax + r15*4]
add rcx, rax
jmp rcx
movzx eax, byte [r12 + 0x10]
cmp al, 0xd
je 0x1400d47a7
mov rsi, r12
jmp 0x1400d493a
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, eax
shl rsi, 0x20
or rsi, 2
mov r15d, r12d
and r15d, 3
jmp 0x1400d48d6
xor esi, esi
jmp 0x1400d493a
movzx eax, byte [r12 + 0xf]
cmp al, 0xd
jne 0x1400d4752
jmp 0x1400d47a7
test rbx, rbx
jne 0x1400d47bd
test r14d, r14d
jne 0x1400d47bd
lea rsi, str.cannot_set_a_0_duration_timeout
jmp 0x1400d48d6
mov eax, r14d
imul rax, rax, 0x10624dd3
shr rax, 0x26
mov dword [rbp + 0x3c0], ebx
cmp r14d, 0x3e8
mov ecx, 1
mov edx, eax
cmovb edx, ecx
test ebx, ebx
cmovne edx, eax
mov dword [rbp + 0x3c4], edx
lea rcx, [rbp + 0x1c0]
mov r8d, 0x1f8
xor edx, edx
call fcn.1400f5750
mov qword [rbp - 0x58], 1
mov qword [rbp - 0x50], rdi
lea rcx, [rbp - 0x48]
mov r8d, 0x1f8
xor edx, edx
call fcn.1400f5750
mov qword [rbp + 0x1b0], 1
mov qword [rbp + 0x1b8], rdi
lea rax, [rbp + 0x3c0]
mov qword [rsp + 0x20], rax
lea r8, [rbp - 0x58]
lea r9, [rbp + 0x1b0]
mov ecx, 1
xor edx, edx
call qword [sym.imp.WS2_32.dll_select]
test eax, eax
je 0x1400d486f
cmp eax, 0xffffffff
jne 0x1400d487f
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, eax
shl rsi, 0x20
or rsi, 2
jmp 0x1400d48d6
mov qword [rbp + 0x3d0], r12
lea rsi, str.connection_timed_out
jmp 0x1400d488e
cmp dword [rbp - 0x58], 1
jne 0x1400d48bd
mov qword [rbp + 0x3d0], r12
xor esi, esi
cmp r15d, 1
jne 0x1400d493a
mov rdx, qword [rbp + 0x3d0]
lea rax, [rdx - 1]
mov qword [rbp + 0x3c8], rax
mov rcx, qword [rdx - 1]
mov qword [rbp + 0x3d0], rdx
mov rax, qword [rdx + 7]
call qword [rax]
jmp 0x1400d4900
mov rcx, rsi
call fcn.1400ce7a0
mov rsi, rdx
test rax, rax
jne 0x1400d48d6
test rsi, rsi
je 0x1400d4958
test r12, r12
je 0x1400d493a
cmp r15d, 1
jne 0x1400d493a
lea rax, [r12 - 1]
mov qword [rbp + 0x3c8], rax
mov rcx, qword [r12 - 1]
mov rax, qword [r12 + 7]
mov qword [rbp + 0x3d0], r12
call qword [rax]
mov rax, qword [rbp + 0x3d0]
mov rax, qword [rax + 7]
mov rdx, qword [rax + 8]
test rdx, rdx
mov rdi, qword [rbp + 0x3c8]
je 0x1400d4927
mov r8, qword [rax + 0x10]
mov rcx, qword [rdi]
call fcn.140001ab0
mov edx, 0x18
mov r8d, 8
mov rcx, rdi
call fcn.140001ab0
mov rax, rsi
movaps xmm6, xmmword [rbp + 0x3e0]
add rsp, 0x478
pop rbx
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
pop rbp
ret
mov qword [rbp + 0x3d0], r12
xor esi, esi
xor ecx, ecx
call fcn.1400c8830
jmp 0x1400d488e