Function at 0x1401128c0
Capabilities:
Get socket status

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x658
mov rdi, r8
mov rax, qword [0x14051d038]
xor rax, rsp
mov qword [rsp + 0x650], rax
test rcx, rcx
je 0x140112910
test edx, edx
je 0x140112910
mov rsi, rcx
mov r12d, edx
mov r13, r12
shl r13, 4
xor eax, eax
cmp qword [rsi + rax], 0xffffffffffffffff
jne 0x140112966
add rax, 0x10
cmp r13, rax
jne 0x140112900
xor r12d, r12d
test rdi, rdi
je 0x14011292c
js 0x140112953
mov ecx, 0xfffffffe
cmp rdi, rcx
cmovl rcx, rdi
call qword [sym.imp.KERNEL32.dll_Sleep]
mov rcx, qword [rsp + 0x650]
xor rcx, rsp
call fcn.1402ddd70
mov eax, r12d
add rsp, 0x658
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
mov ecx, 0x2726
call qword [sym.imp.WS2_32.dll_WSASetLastError]
mov r12d, 0xffffffff
jmp 0x14011292c
lea rcx, [rsp + 0x448]
mov r8d, 0x208
mov dl, 0xaa
call fcn.1402e0d10
lea rcx, [rsp + 0x240]
mov r8d, 0x208
mov dl, 0xaa
call fcn.1402e0d10
lea r15, [rsp + 0x38]
mov r8d, 0x208
mov rcx, r15
mov dl, 0xaa
call fcn.1402e0d10
xor eax, eax
xor ebp, ebp
xor ebx, ebx
xor r14d, r14d
jmp 0x140112a0b
mov r9d, r8d
cmp r9d, ebx
jne 0x1401129c7
cmp ebx, 0x3f
ja 0x1401129c7
mov qword [rsp + r8*8 + 0x248], rcx
inc ebx
test edx, 0x600
je 0x1401129ff
mov edx, r14d
xor r8d, r8d
test r14d, r14d
je 0x1401129ec
cmp qword [rsp + r8*8 + 0x40], rcx
je 0x1401129ec
inc r8
cmp rdx, r8
jne 0x1401129da
mov r8d, edx
cmp r8d, r14d
jne 0x1401129ff
cmp r14d, 0x3f
ja 0x1401129ff
mov qword [rsp + rdx*8 + 0x40], rcx
inc r14d
inc rax
cmp rax, r12
je 0x140112a9d
mov rdx, rax
shl rdx, 4
mov word [rsi + rdx + 0xa], 0
mov rcx, qword [rsi + rdx]
cmp rcx, 0xffffffffffffffff
je 0x1401129ff
movzx edx, word [rsi + rdx + 8]
test edx, 0x710
je 0x1401129ff
test edx, 0x300
je 0x140112a6b
mov r8d, ebp
xor r9d, r9d
test ebp, ebp
je 0x140112a57
cmp qword [rsp + r9*8 + 0x450], rcx
je 0x140112a57
inc r9
cmp r8, r9
jne 0x140112a42
mov r9d, r8d
cmp r9d, ebp
jne 0x140112a6b
cmp ebp, 0x3f
ja 0x140112a6b
mov qword [rsp + r8*8 + 0x450], rcx
inc ebp
test dl, 0x10
je 0x1401129c7
mov r8d, ebx
xor r9d, r9d
test ebx, ebx
je 0x1401129b3
cmp qword [rsp + r9*8 + 0x248], rcx
je 0x1401129b3
inc r9
cmp r8, r9
jne 0x140112a82
jmp 0x1401129b0
mov dword [rsp + 0x448], ebp
mov dword [rsp + 0x240], ebx
mov dword [rsp + 0x38], r14d
movabs rax, 0xaaaaaaaaaaaaaaaa
mov qword [rsp + 0x30], rax
test ebp, ebp
jne 0x140112b24
test ebx, ebx
jne 0x140112b24
test r14d, r14d
jne 0x140112b24
xor r12d, r12d
test rdi, rdi
je 0x140112ae8
js 0x140112b0c
mov ecx, 0xfffffffe
cmp rdi, rcx
cmovl rcx, rdi
call qword [sym.imp.KERNEL32.dll_Sleep]
cmp r12d, 0xffffffff
jne 0x14011292c
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
xor r12d, r12d
cmp eax, 0x2714
setne r12b
neg r12d
jmp 0x14011292c
mov ecx, 0x2726
call qword [sym.imp.WS2_32.dll_WSASetLastError]
mov r12d, 0xffffffff
jmp 0x140112ae8
mov r12d, eax
jmp 0x140112ae8
lea rcx, [rsp + 0x30]
mov rdx, rdi
call fcn.14011bd30
xor r12d, r12d
test r14d, r14d
cmove r15, r12
test ebx, ebx
lea r8, [rsp + 0x240]
cmove r8, r12
test ebp, ebp
lea rdx, [rsp + 0x448]
cmove rdx, r12
mov qword [rsp + 0x20], rax
xor ecx, ecx
mov r9, r15
call qword [sym.imp.WS2_32.dll_select]
test eax, eax
jle 0x140112b1f
lea rdi, [rsp + 0x448]
lea rbx, [rsp + 0x240]
lea r14, [rsp + 0x38]
xor r15d, r15d
jmp 0x140112ba0
movzx eax, word [rsi + r15 + 0xa]
cmp ax, 1
sbb r12d, 0xffffffff
add r15, 0x10
cmp r13, r15
je 0x14011292c
mov word [rsi + r15 + 0xa], 0
mov rcx, qword [rsi + r15]
cmp rcx, 0xffffffffffffffff
je 0x140112b93
mov rdx, rdi
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x140112bdc
mov eax, dword [rsi + r15 + 8]
bt eax, 8
jae 0x140112bcf
or byte [rsi + r15 + 0xb], 1
test eax, 0x300
je 0x140112bdc
or byte [rsi + r15 + 0xb], 3
mov rcx, qword [rsi + r15]
mov rdx, rbx
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x140112bfa
test byte [rsi + r15 + 8], 0x10
je 0x140112bfa
or byte [rsi + r15 + 0xa], 0x10
mov rcx, qword [rsi + r15]
mov rdx, r14
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x140112b85
movzx r8d, word [rsi + r15 + 8]
mov ecx, r8d
and ecx, 0x200
or cx, word [rsi + r15 + 0xa]
mov edx, r8d
and dx, 0x400
mov eax, 1
cmove eax, ecx
test r8d, 0x600
je 0x140112b8b
movzx edx, dx
or edx, ecx
mov word [rsi + r15 + 0xa], dx
jmp 0x140112b8b