Function at 0x140121c20
Capabilities:
Check for time delay via gettickcount
Check for time delay via queryperformancecounter
Set socket configuration

Disassembly:
push rbp
push rbx
push rsi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x80]
sub rsp, 0x180
mov rax, qword [0x1402dc040]
xor rax, rsp
mov qword [rbp + 0x70], rax
cmp byte [0x1402df141], 0
mov rsi, rdx
mov r14, qword [rcx + 0x10]
mov r13, rcx
je 0x140121c92
lea rcx, [rsp + 0x68]
call qword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
mov r8, qword [0x1402df138]
mov rax, qword [rsp + 0x68]
cqo
idiv r8
mov qword [rsp + 0x58], rax
mov rax, qword [rsp + 0x68]
cqo
idiv r8
imul rax, rdx, 0xf4240
cqo
idiv r8
jmp 0x140121cbd
call qword [sym.imp.KERNEL32.dll_GetTickCount]
mov r8d, eax
mov eax, 0x10624dd3
mul r8d
shr edx, 6
mov ecx, edx
mov qword [rsp + 0x58], rcx
imul ecx, edx, 0x3e8
sub r8d, ecx
imul eax, r8d, 0x3e8
mov dword [rsp + 0x60], eax
lea r15, [r14 + 0x98]
movups xmm0, xmmword [rsp + 0x58]
mov r8, r15
mov qword [rsp + 0x1d0], rdi
lea rdx, [r14 + 8]
mov rcx, rsi
movups xmmword [r14 + 0x148], xmm0
call fcn.140120d70
mov ebx, eax
test eax, eax
jne 0x140121d5d
mov rbx, qword [r13 + 0x10]
mov edx, dword [rbx + 0x14]
lea r9, [rbx + 0x13c]
lea r8, [rbx + 0xe0]
lea rcx, [rbx + 0x18]
call fcn.14010d3f0
test al, al
jne 0x140121dbf
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov ecx, dword [rax]
mov dword [rbx + 0x178], ecx
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov ebx, dword [rax]
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
lea rdx, [rsp + 0x70]
mov ecx, ebx
mov rdi, rax
call fcn.1400fb380
mov r8d, dword [rdi]
lea rdx, str.sa_addr_inet_ntop___failed_with_errno__d:__s
mov r9, rax
mov rcx, rsi
call fcn.140101f40
mov ebx, 2
mov r14, qword [r15]
cmp r14, 0xffffffffffffffff
je 0x14012211d
mov rdi, qword [r13 + 0x18]
test rdi, rdi
je 0x14012210d
cmp qword [rdi + 0x18], 0
mov rdx, r14
mov rcx, rsi
je 0x140122108
call fcn.14010acb0
test rsi, rsi
je 0x1401220d8
mov rax, qword [rsi + 0xe0]
test rax, rax
je 0x1401220b6
mov byte [rax + 0x1cb], 1
mov rdx, r14
mov rax, qword [rdi + 0x18]
mov rcx, qword [rdi + 0x20]
call rax
jmp 0x1401220e7
mov r9d, dword [r14 + 0x13c]
lea r8, [r14 + 0xe0]
lea rdx, str.__Trying__s:_d...
mov rcx, rsi
xor ebx, ebx
call fcn.140102070
cmp dword [r14 + 8], 2
jne 0x140121f3f
cmp dword [r14 + 0xc], 1
jne 0x140121f3f
cmp byte [rsi + 0xabc], bl
je 0x140121e4d
mov rcx, qword [r15]
lea r9, [rsp + 0x50]
mov edx, 6
mov dword [rsp + 0x50], 1
mov r8d, 1
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x140121e4d
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, eax
lea rdx, [rsp + 0x70]
call fcn.1400fb380
mov r8, rax
lea rdx, str.Could_not_set_TCP_NODELAY:__s
mov rcx, rsi
call fcn.140102070
mov rcx, qword [r15]
call fcn.140120e20
cmp byte [rsi + 0xac3], 0
je 0x140121f47
mov rdi, qword [r15]
lea r9, [rsp + 0x50]
mov rcx, rdi
mov dword [rsp + 0x50], 1
mov edx, 0xffff
mov dword [rsp + 0x20], 4
mov r8d, 8
call qword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x140121eb2
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov r8, rdi
lea rdx, str.Failed_to_set_SO_KEEPALIVE_on_fd__qd:_errno__d
mov r9d, eax
mov rcx, rsi
call fcn.140102070
jmp 0x140121f47
mov eax, dword [rsi + 0xa34]
lea r8, [rsp + 0x58]
btr eax, 0x1f
mov dword [rsp + 0x58], 1
imul eax, eax, 0x3e8
mov r9d, ntohs
mov edx, 0x98000004
mov dword [rsp + 0x5c], eax
mov eax, dword [rsi + 0xa38]
btr eax, 0x1f
imul ecx, eax, 0x3e8
lea rax, [rsp + 0x68]
mov dword [rsp + 0x50], ecx
mov dword [rsp + 0x60], ecx
xor ecx, ecx
mov qword [rsp + 0x40], rcx
mov qword [rsp + 0x38], rcx
mov qword [rsp + 0x30], rax
mov dword [rsp + 0x28], ecx
mov qword [rsp + 0x20], rcx
mov rcx, rdi
call qword [sym.imp.WS2_32.dll_WSAIoctl]
test eax, eax
je 0x140121f47
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov r8, rdi
lea rdx, str.Failed_to_set_SIO_KEEPALIVE_VALS_on_fd__qd:_errno__d
mov r9d, eax
mov rcx, rsi
call fcn.140102070
jmp 0x140121f47
mov rcx, qword [r15]
call fcn.140120e20
cmp qword [rsi + 0x298], 0
je 0x140121fbb
mov rax, qword [rsi + 0xe0]
lea rdi, [rsi + 0xd8]
test rax, rax
jne 0x140121f6c
mov rax, qword [rdi]
test rax, rax
je 0x140121f73
mov byte [rax + 0x1cb], 1
mov rdx, qword [r15]
xor r8d, r8d
mov rcx, qword [rsi + 0x2a0]
call qword [rsi + 0x298]
mov ecx, eax
mov rax, qword [rsi + 0xe0]
test rax, rax
jne 0x140121f9c
mov rax, qword [rdi]
test rax, rax
je 0x140121fa3
mov byte [rax + 0x1cb], 0
cmp ecx, 2
jne 0x140121fad
mov dil, 1
jmp 0x140121fbe
test ecx, ecx
je 0x140121fbb
mov ebx, Ordinal_46
jmp 0x140121d5d
xor dil, dil
cmp dword [r14 + 8], 2
jne 0x140121ff3
mov r8, qword [r15]
mov r9d, 2
mov rdx, qword [r13 + 0x18]
mov rcx, rsi
call fcn.140120f10
mov ebx, eax
test eax, eax
je 0x140121ff3
cmp eax, 1
jne 0x140121d5d
mov ebx, 7
jmp 0x140121d5d
mov rcx, qword [r15]
lea r8, [rsp + 0x50]
mov edx, 0x8004667e
mov dword [rsp + 0x50], 1
call qword [sym.imp.WS2_32.dll_ioctlsocket]
cmp dword [r14 + 0xc], 2
setne al
mov byte [r14 + 0x17e], al
test dil, dil
je 0x14012211d
mov rdx, rsi
mov rcx, r13
call fcn.140121a40
cmp byte [0x1402df141], 0
je 0x140122073
lea rcx, [rsp + 0x68]
call qword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
mov r8, qword [0x1402df138]
mov rax, qword [rsp + 0x68]
cqo
idiv r8
mov qword [rsp + 0x58], rax
mov rax, qword [rsp + 0x68]
cqo
idiv r8
imul rax, rdx, 0xf4240
cqo
idiv r8
jmp 0x14012209e
call qword [sym.imp.KERNEL32.dll_GetTickCount]
mov r8d, eax
mov eax, 0x10624dd3
mul r8d
shr edx, 6
mov ecx, edx
mov qword [rsp + 0x58], rcx
imul ecx, edx, 0x3e8
sub r8d, ecx
imul eax, r8d, 0x3e8
mov dword [rsp + 0x60], eax
movups xmm0, xmmword [rsp + 0x58]
movups xmmword [r14 + 0x158], xmm0
mov byte [r13 + 0x24], 1
jmp 0x14012211d
mov rax, qword [rsi + 0xd8]
test rax, rax
je 0x1401220d8
mov byte [rax + 0x1cb], 1
mov rdx, r14
mov rax, qword [rdi + 0x18]
mov rcx, qword [rdi + 0x20]
call rax
jmp 0x1401220e7
mov rcx, qword [rdi + 0x20]
mov rdx, r14
call qword [rdi + Ordinal_26]
test rsi, rsi
je 0x140122116
mov rax, qword [rsi + 0xe0]
test rax, rax
jne 0x1401220ff
mov rax, qword [rsi + 0xd8]
test rax, rax
je 0x140122116
mov byte [rax + 0x1cb], 0
jmp 0x140122116
call fcn.14010acb0
mov rcx, r14
call qword [sym.imp.WS2_32.dll_closesocket]
mov qword [r15], 0xffffffffffffffff
mov rax, qword [r15]
lea r8, str.cf_socket_open_______d__fd_qd
mov r9d, ebx
mov qword [rsp + 0x20], rax
mov rdx, r13
mov rcx, rsi
call fcn.140102180
mov rdi, qword [rsp + 0x1d0]
mov eax, ebx
mov rcx, qword [rbp + 0x70]
xor rcx, rsp
call fcn.14016dfe0
add rsp, 0x180
pop r15
pop r14
pop r13
pop r12
pop rsi
pop rbx
pop rbp
ret