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

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x270
mov rax, qword [0x180067048]
xor rax, rsp
mov qword [rsp + 0x260], rax
mov rsi, rcx
xor ebp, ebp
nop
mov rdi, qword [rsi + 0x28]
mov edx, 0xffffffff
mov rbx, rbp
mov rcx, qword [rdi + 0x28]
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov r8, qword [rdi + 0x50]
test r8, r8
je 0x180006ede
mov rax, qword [rdi + 0x30]
mov rdx, qword [rdi + 0x48]
test rax, rax
je 0x180006ea8
mov rbx, qword [rax]
mov rax, qword [rbx + 0x10]
mov rcx, rdx
mov rbx, qword [rbx + 8]
dec rax
shr rcx, 1
and edx, 1
and rcx, rax
lea rax, [r8 - 1]
mov rbx, qword [rbx + rcx*8]
mov rbx, qword [rbx + rdx*8]
mov qword [rdi + 0x50], rax
test rax, rax
jne 0x180006eda
mov qword [rdi + 0x48], rbp
jmp 0x180006ede
inc qword [rdi + 0x48]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
test rbx, rbx
je 0x1800070b5
mov rax, qword [rbx]
lea rdx, [rsp + 0x50]
xor r9d, r9d
mov qword [rsp + 0x58], rax
lea rax, [rsp + 0x40]
mov dword [rsp + 0x50], 1
xor r8d, r8d
mov dword [rsp + 0x40], ebp
mov dword [rsp + 0x44], 1
lea ecx, [r9 + 1]
mov qword [rsp + 0x20], rax
call qword [sym.imp.WS2_32.dll_select]
test eax, eax
jle 0x180006ffb
mov rcx, qword [rbx]
lea rdx, [rsp + 0x50]
call qword [sym.imp.WS2_32.dll___WSAFDIsSet]
test eax, eax
je 0x180006fdf
mov rax, qword [rbx + 0x10]
mov rdx, qword [rax + 0x18]
test rdx, rdx
je 0x180006f9e
mov rcx, qword [rax + 0x20]
test rcx, rcx
je 0x180006f9e
sub ecx, dword [rax + 0x28]
xor r9d, r9d
mov rax, qword [rax + 0x28]
mov r8d, ecx
mov rcx, qword [rbx]
add rdx, rax
call qword [sym.imp.WS2_32.dll_recv]
test eax, eax
jle 0x180006fb8
mov rdx, qword [rbx + 0x10]
movsxd rcx, eax
add qword [rdx + 0x28], rcx
mov rdx, qword [rbx + 0x10]
mov rcx, qword [rdx + 0x20]
cmp qword [rdx + 0x28], rcx
jne 0x180006fb6
mov dword [rdx + 0x34], 1
jmp 0x180006fb6
mov rcx, qword [rbx]
lea rdx, [rsp + 0x30]
mov r9d, 2
lea r8d, [r9 - 1]
call qword [sym.imp.WS2_32.dll_recv]
test eax, eax
jne 0x180006fc7
mov rax, qword [rbx + 0x10]
mov dword [rax + 0x34], 2
jmp 0x180006fd6
test eax, eax
jns 0x180006fd6
mov rax, qword [rbx + 0x10]
mov dword [rax + 0x34], 3
mov rax, qword [rbx + 0x10]
cmp dword [rax + 0x34], ebp
jne 0x180007050
mov rcx, qword [rsi + 0x28]
mov rdx, rbx
call fcn.180007370
mov ecx, 1
call qword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x180006e70
jns 0x180006fdf
mov rcx, qword [rbx]
lea rax, [rsp + 0x38]
lea r9, [rsp + 0x34]
mov qword [rsp + 0x20], rax
mov edx, 0xffff
mov dword [rsp + 0x34], ebp
mov r8d, 0x1007
mov dword [rsp + 0x38], 4
call qword [sym.imp.WS2_32.dll_getsockopt]
cmp eax, 0xffffffff
jne 0x18000703d
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [rsp + 0x34], eax
jmp 0x180007041
mov eax, dword [rsp + 0x34]
test eax, eax
je 0x180006fdf
mov rax, qword [rbx + 0x10]
mov dword [rax + 0x34], 3
mov r8d, dword [rbx + 0x18]
mov edx, dword [rbx + 8]
mov rcx, qword [0x18006b810]
call fcn.180005580
mov rcx, qword [rbx + 0x10]
test eax, eax
je 0x180007094
mov r8, rcx
mov r9b, 1
mov rcx, qword [0x18006b810]
mov edx, eax
mov rcx, qword [rcx]
call fcn.1800121b0
mov edx, 0x20
mov rcx, rbx
call fcn.180037f3c
jmp 0x180006e70
test rcx, rcx
je 0x1800070a3
mov rax, qword [rcx]
mov edx, 1
call qword [rax]
mov edx, 0x20
mov rcx, rbx
call fcn.180037f3c
jmp 0x180006e70
mov rcx, qword [rsp + 0x260]
xor rcx, rsp
call fcn.1800377f0
lea r11, [rsp + 0x270]
mov rbx, qword [r11 + 0x18]
mov rbp, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop rdi
ret