Function at 0x14003ea70
Capabilities:
Get socket status

Disassembly:
push rbp
push rsi
push rdi
push r15
lea rbp, [rsp - 0x598]
sub rsp, 0x698
mov rax, qword [0x14008e168]
xor rax, rsp
mov qword [rbp + 0x570], rax
xor esi, esi
mov edi, r8d
mov r15, rcx
test rcx, rcx
je 0x14003eac2
mov r8d, esi
test edx, edx
je 0x14003eac2
mov rax, rcx
nop dword [rax]
cmp qword [rax], 0xffffffffffffffff
jne 0x14003eae5
inc r8d
add rax, 0x10
cmp r8d, edx
jb 0x14003eab0
test edi, edi
je 0x14003edaf
jns 0x14003eda7
mov ecx, 0x2726
call qword [sym.imp.WS2_32.dll_WSASetLastError]
or esi, 0xffffffff
mov eax, esi
jmp 0x14003ec93
mov qword [rsp + 0x6c8], rbx
mov qword [rsp + 0x690], r12
test edi, edi
mov qword [rsp + 0x688], r13
mov eax, esi
mov ebx, esi
cmovg eax, edi
mov qword [rsp + 0x680], r14
mov r11d, esi
mov dword [rsp + 0x40], esi
mov dword [rbp + 0x150], ebx
mov r8d, esi
mov dword [rsp + 0x38], eax
mov dword [rbp + 0x360], esi
or r14, 0xffffffffffffffff
lea r10, [rcx + 8]
mov r12d, edx
mov r13d, edx
nop word [rax + rax]
mov rdx, qword [r10 - 8]
mov word [r10 + 2], si
cmp rdx, 0xffffffffffffffff
je 0x14003ec38
movzx r9d, word [r10]
test r9b, 7
je 0x14003ec38
cmp rdx, r14
cmova r14, rdx
test r9b, 1
je 0x14003eba6
mov ecx, esi
mov rax, rsi
test r11d, r11d
je 0x14003eb89
cmp qword [rsp + rax*8 + 0x48], rdx
je 0x14003eb89
inc ecx
inc rax
cmp ecx, r11d
jb 0x14003eb78
cmp ecx, r11d
jne 0x14003eba6
cmp r11d, 0x40
jae 0x14003eba6
mov qword [rsp + rax*8 + 0x48], rdx
mov r11d, dword [rsp + 0x40]
inc r11d
mov dword [rsp + 0x40], r11d
test r9b, 4
je 0x14003ebe7
mov ecx, esi
mov rax, rsi
test ebx, ebx
je 0x14003ebc8
cmp qword [rbp + rax*8 + 0x158], rdx
je 0x14003ebc8
inc ecx
inc rax
cmp ecx, ebx
jb 0x14003ebb5
cmp ecx, ebx
jne 0x14003ebe7
cmp ebx, 0x40
jae 0x14003ebe7
mov qword [rbp + rax*8 + 0x158], rdx
mov ebx, dword [rbp + 0x150]
inc ebx
mov dword [rbp + 0x150], ebx
test r9b, 2
je 0x14003ec38
mov ecx, esi
mov rax, rsi
test r8d, r8d
je 0x14003ec14
nop word [rax + rax]
cmp qword [rbp + rax*8 + 0x368], rdx
je 0x14003ec14
inc ecx
inc rax
cmp ecx, r8d
jb 0x14003ec00
cmp ecx, r8d
jne 0x14003ec38
cmp r8d, 0x40
jae 0x14003ec38
mov qword [rbp + rax*8 + 0x368], rdx
mov r8d, dword [rbp + 0x360]
inc r8d
mov dword [rbp + 0x360], r8d
add r10, 0x10
dec r13
jne 0x14003eb40
mov r13, qword [rsp + 0x688]
test r11d, r11d
jne 0x14003ecaf
test ebx, ebx
jne 0x14003ecaf
test r8d, r8d
jne 0x14003ecaf
test edi, edi
je 0x14003ec79
jns 0x14003ec71
mov ecx, 0x2726
call qword [sym.imp.WS2_32.dll_WSASetLastError]
or esi, 0xffffffff
jmp 0x14003ec79
mov ecx, edi
call qword [sym.imp.KERNEL32.dll_Sleep]
mov eax, esi
mov r12, qword [rsp + 0x690]
mov rbx, qword [rsp + 0x6c8]
mov r14, qword [rsp + 0x680]
mov rcx, qword [rbp + 0x570]
xor rcx, rsp
call fcn.1400512b0
add rsp, 0x698
pop r15
pop rdi
pop rsi
pop rbp
ret
lea r10, [rsp + 0x30]
test edi, edi
cmovs r10, rsi
jle 0x14003ece9
mov ecx, dword [rsp + 0x38]
mov eax, 0x10624dd3
imul ecx
sar edx, 6
mov eax, edx
shr eax, 0x1f
add edx, eax
mov dword [rsp + 0x30], edx
imul edx, edx, 0x3e8
sub ecx, edx
imul ecx, ecx, 0x3e8
mov dword [rsp + 0x34], ecx
jmp 0x14003ecf0
jne 0x14003ecf0
mov qword [rsp + 0x30], rsi
test r8d, r8d
lea r9, [rbp + 0x360]
lea r8, [rbp + 0x150]
cmove r9, rsi
test ebx, ebx
lea rdx, [rsp + 0x40]
cmove r8, rsi
test r11d, r11d
lea ecx, [r14 + 1]
cmove rdx, rsi
mov qword [rsp + 0x20], r10
call qword [sym.imp.WS2_32.dll_select]
test eax, eax
jns 0x14003ed32
or eax, 0xffffffff
jmp 0x14003ec7b
jne 0x14003ed3b
xor eax, eax
jmp 0x14003ec7b
mov edi, esi
lea rbx, [r15 + 0xa]
mov rcx, qword [rbx - 0xa]
mov word [rbx], si
cmp rcx, 0xffffffffffffffff
je 0x14003ed97
lea rdx, [rsp + 0x40]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x14003ed60
or word [rbx], 1
mov rcx, qword [rbx - 0xa]
lea rdx, [rbp + 0x150]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x14003ed78
or word [rbx], 4
mov rcx, qword [rbx - 0xa]
lea rdx, [rbp + 0x360]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x14003ed90
or word [rbx], 2
cmp word [rbx], si
je 0x14003ed97
inc edi
add rbx, 0x10
dec r12
jne 0x14003ed41
mov eax, edi
jmp 0x14003ec7b
mov ecx, edi
call qword [sym.imp.KERNEL32.dll_Sleep]
mov eax, esi
jmp 0x14003ec93