Function at 0x14016a660
Capabilities:
Get socket status
Receive data
Receive data on socket

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
push r14
push r15
sub rsp, 0x270
mov qword [rsp + 0x48], 0xfffffffffffffffe
mov rax, qword [0x140479080]
xor rax, rsp
mov qword [rsp + 0x260], rax
mov r12, r8
mov r14, rdx
mov rdi, rcx
cmp dword [rcx + 0x60], 2
je 0x14016a6ab
mov qword [rcx + 0x2c], 0x17b
mov al, 1
jmp 0x14016a8f6
xor ebx, ebx
mov qword [rsp + 0x38], rbx
mov qword [rsp + 0x40], rbx
xor r8d, r8d
xor edx, edx
call fcn.14000c460
mov rsi, rax
mov qword [rsp + 0x38], rax
mov ebp, ebx
cmp dword [rdi + 0x34], ebx
je 0x14016a6f7
cmp byte [0x1404a2d71], bl
jne 0x14016a6e8
lea ecx, [rbx + 1]
call qword [sym.imp.WINMM.dll_timeBeginPeriod]
mov byte [0x1404a2d71], 1
call qword [sym.imp.WINMM.dll_timeGetTime]
mov r15d, dword [rdi + 0x34]
add r15d, eax
jmp 0x14016a700
mov r15d, ebx
nop word [rax + rax]
cmp dword [rdi + 0x34], 0
je 0x14016a730
cmp byte [0x1404a2d71], 0
jne 0x14016a721
mov ecx, 1
call qword [sym.imp.WINMM.dll_timeBeginPeriod]
mov byte [0x1404a2d71], 1
call qword [sym.imp.WINMM.dll_timeGetTime]
cmp eax, r15d
jae 0x14016a886
cmp byte [rdi + 0x64], 0
jne 0x14016a886
test rbp, rbp
jne 0x14016a752
mov ecx, dword [rdi + 0xa0]
inc ecx
call fcn.14023ed88
mov rbp, rax
mov qword [r14], rax
cmp dword [rdi + 0x34], 0
jne 0x14016a7a5
cmp byte [rdi + 0x65], 0
jne 0x14016a7a5
movsxd rcx, dword [rdi + 0x58]
mov qword [rsp + 0x58], rcx
mov dword [rsp + 0x50], 1
mov dword [rsp + 0x30], ebx
mov dword [rsp + 0x34], 0x3e8
inc ecx
lea rax, [rsp + 0x30]
mov qword [rsp + 0x20], rax
xor r9d, r9d
xor r8d, r8d
lea rdx, [rsp + 0x50]
call qword [sym.imp.WS2_32.dll_select]
cmp eax, 0xffffffff
je 0x14016a7f7
test eax, eax
je 0x14016a700
movsxd rcx, dword [rdi + 0x58]
xor r9d, r9d
mov r8d, dword [rdi + 0xa0]
mov rdx, rbp
call qword [sym.imp.WS2_32.dll_recv]
movsxd rcx, eax
test eax, eax
je 0x14016a863
cmp ecx, 0xffffffff
je 0x14016a7d4
cmp ecx, dword [rdi + 0xa0]
jle 0x14016a80c
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x14016a846
cmp byte [rdi + 0x65], 0
jne 0x14016a826
mov ecx, 1
call qword [case.0x14024b920.42]
jmp 0x14016a700
mov dword [rdi + 0x2c], 0x1af
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [rdi + 0x30], eax
jmp 0x14016a8b1
mov byte [rcx + rbp], 0
mov ebx, ecx
mov eax, dword [rdi + 0xa0]
cmp ecx, eax
jne 0x14016a876
add eax, eax
mov dword [rdi + 0xa0], eax
jmp 0x14016a876
mov dword [rdi + 0x2c], 0x1ce
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [rdi + 0x30], eax
mov rcx, rbp
call fcn.14023ed44
mov qword [r14], rbx
xor dil, dil
jmp 0x14016a8bc
mov dword [rdi + 0x2c], 0x1d9
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [rdi + 0x30], eax
mov rcx, rbp
call fcn.14023ed44
mov qword [r14], rbx
jmp 0x14016a892
mov rcx, rbp
call fcn.14023ed44
mov qword [r14], rbx
mov rcx, rdi
call fcn.14016a920
test r12, r12
je 0x14016a881
mov eax, ebx
mov qword [r12], rax
xor dil, dil
jmp 0x14016a8bc
mov byte [rdi + 0x64], 0
mov qword [rdi + 0x2c], 0x18b
mov rbx, qword [rsi]
cmp rbx, rsi
je 0x14016a8b1
nop word [rax + rax]
mov rcx, qword [rbx + 0x10]
call fcn.14023ed44
mov rbx, qword [rbx]
cmp rbx, rsi
jne 0x14016a8a0
mov rcx, rdi
call fcn.14016a920
mov dil, 1
mov rcx, qword [rsi]
mov qword [rsi], rsi
mov qword [rsi + 8], rsi
cmp rcx, rsi
je 0x14016a8e5
nop dword [rax + rax]
mov rbx, qword [rcx]
mov edx, 0x20
call fcn.14023ed44
mov rcx, rbx
cmp rbx, rsi
jne 0x14016a8d0
mov edx, 0x20
mov rcx, rsi
call fcn.14023ed44
movzx eax, dil
mov rcx, qword [rsp + 0x260]
xor rcx, rsp
call fcn.14023ed20
add rsp, 0x270
pop r15
pop r14
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret