Function at 0x18017fb40
Capabilities:
Get socket status

Disassembly:
mov byte [rsp + 0x20], r9b
push rbp
push rsi
push r14
sub rsp, 0x40
movzx r10d, r9b
mov esi, r8d
mov r14d, edx
mov rbp, rcx
cmp r8d, 0x32
jbe 0x18017fcaf
test edx, edx
je 0x18017fcaf
mov qword [rsp + 0x30], r15
mov r15, qword [rsp + 0x90]
mov dword [r15], 0xffffffff
cmp dword [rcx + 0x10], 0
jne 0x18017fbab
mov rcx, qword [rsp + 0x88]
lea rdx, str.No_sockets_exists_for_fdSetSelect.
mov rax, qword [rcx]
call qword [rax + 0x28]
mov r15, qword [rsp + 0x30]
xor al, al
add rsp, 0x40
pop r14
pop rsi
pop rbp
ret
mov qword [rsp + 0x60], rbx
mov al, 1
mov qword [rsp + 0x68], rdi
xor edi, edi
mov qword [rsp + 0x70], r12
mov r12, qword [rsp + 0x98]
mov qword [rsp + 0x38], r13
mov r13, qword [rsp + 0x88]
mov ecx, 1
mov ebx, r14d
cmp esi, edi
jbe 0x18017fbea
mov ebx, esi
sub ebx, edi
cmp ebx, r14d
cmova ebx, r14d
test al, al
je 0x18017fbf6
shr ebx, 1
cmp ebx, 1
cmovb ebx, ecx
mov r9, r13
mov qword [rsp + 0x20], r15
movzx r8d, r10b
mov edx, ebx
mov rcx, rbp
call 0x18017fce0
mov ecx, dword [r15]
cmp ecx, 0xffffffff
je 0x18017fc6f
test ecx, ecx
jg 0x18017fc6f
add edi, ebx
cmp edi, esi
jae 0x18017fc91
test r12, r12
je 0x18017fc32
mov rdx, r13
mov rcx, r12
call fcn.180125000
test al, al
jne 0x18017fc40
xor al, al
cmp edi, esi
jae 0x18017fc91
movzx r10d, byte [rsp + 0x78]
jmp 0x18017fbd3
mov rax, qword [r13]
lea rdx, str.socket_set_select_aborted_by_application_callback
mov rcx, r13
call qword [rax + 0x28]
xor eax, eax
mov dword [r15], eax
mov rcx, qword [rbp + 8]
mov dword [rbp + 0x10], eax
mov dword [rbp + 0x1018], eax
test rcx, rcx
je 0x18017fc6d
call fcn.18018d110
mov al, 1
mov r13, qword [rsp + 0x38]
mov r12, qword [rsp + 0x70]
mov rdi, qword [rsp + 0x68]
mov rbx, qword [rsp + 0x60]
mov r15, qword [rsp + 0x30]
add rsp, 0x40
pop r14
pop rsi
pop rbp
ret
mov rcx, qword [rbp + 8]
xor ebx, ebx
mov dword [rbp + 0x10], ebx
mov dword [rbp + 0x1018], ebx
test rcx, rcx
je 0x18017fcaa
call fcn.18018d110
mov dword [r15], ebx
jmp 0x18017fc6d
mov rax, qword [rsp + 0x90]
movzx r8d, r10b
mov r9, qword [rsp + 0x88]
mov edx, esi
mov qword [rsp + 0x80], rax
add rsp, 0x40
pop r14
pop rsi
pop rbp
jmp 0x18017fce0
push rbx
push rsi
push rdi
push r14
push r15
sub rsp, 0x40
mov rax, qword [0x18036d060]
xor rax, rsp
mov qword [rsp + 0x38], rax
mov r14, qword [rsp + 0x90]
xor r15d, r15d
mov rdi, r9
movzx r10d, r8b
mov r9d, edx
mov rbx, rcx
mov r8d, r15d
mov dword [r14], 0xffffffff
mov eax, dword [rcx + 0x1018]
mov dword [rcx + 0x10], eax
test eax, eax
je 0x18017fd53
nop word [rax + rax]
mov edx, r8d
inc r8d
mov rax, qword [rcx + rdx*8 + 0x1020]
mov qword [rcx + rdx*8 + 0x18], rax
cmp r8d, dword [rcx + 0x1018]
jb 0x18017fd30
mov eax, dword [rcx + 0x10]
test eax, eax
jne 0x18017fd6a
mov rax, qword [rdi]
lea rdx, str.No_sockets_exists_for_fdSetSelect.
mov rcx, rdi
call qword [rax + 0x28]
xor al, al
jmp 0x18017feb1
mov eax, 0x10624dd3
mul r9d
shr edx, 6
imul eax, edx, 0x3e8
mov dword [rsp + 0x30], edx
sub r9d, eax
imul eax, r9d, 0x3e8
xor r9d, r9d
mov dword [rsp + 0x34], eax
lea rax, [rsp + 0x30]
mov qword [rsp + 0x20], rax
test r10b, r10b
je 0x18017fda8
xor r8d, r8d
lea rdx, [rcx + 0x10]
jmp 0x18017fdae
lea r8, [rcx + 0x10]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.WS2_32.dll_select]
mov qword [rsp + 0x80], rbp
mov dword [r14], eax
cmp eax, 0xffffffff
jne 0x18017fdf6
mov rax, qword [rdi]
lea rdx, str.select_system_call_failed.
mov rcx, rdi
call qword [rax + 0x28]
mov rcx, qword [rbx + 8]
mov dword [rbx + 0x10], r15d
mov dword [rbx + 0x1018], r15d
test rcx, rcx
je 0x18017fe2b
call fcn.18018d110
xor al, al
jmp 0x18017fea9
cmp dword [rbx + 0x10], r15d
jne 0x18017fe1e
mov rcx, qword [rbx + 8]
mov dword [rbx + 0x10], r15d
mov dword [rbx + 0x1018], r15d
test rcx, rcx
je 0x18017fea7
call fcn.18018d110
jmp 0x18017fea7
call fcn.18018d120
mov rbp, rax
test rax, rax
jne 0x18017fe2f
xor al, al
jmp 0x18017fea9
movsxd rsi, dword [rbx + 0x10]
test rsi, rsi
jle 0x18017fe90
mov rdi, r15
nop dword [rax + rax]
movsxd rax, dword [rbx + 0x1018]
mov edx, r15d
mov rcx, r15
test eax, eax
jle 0x18017fe88
mov r8, qword [rbx + rdi*8 + 0x18]
mov r9, rax
lea rax, [rbx + 0x1020]
cmp r8, qword [rax]
je 0x18017fe75
inc edx
inc rcx
add rax, 8
cmp rcx, r9
jl 0x18017fe60
jmp 0x18017fe88
mov rcx, qword [rbx + 8]
call fcn.18018d1e0
mov edx, eax
mov rcx, rbp
call fcn.18018d0b0
inc rdi
cmp rdi, rsi
jl 0x18017fe40
mov rcx, qword [rbx + 8]
test rcx, rcx
je fcn.18017fea3
mov rax, qword [rcx]
mov edx, 1
call qword [rax]