Function at 0x140004890
Capabilities:
Receive data
Receive data on socket

Disassembly:
mov dword [rsp + 0x10], edx
mov qword [rsp + 8], rcx
push rbx
push rbp
push rsi
push rdi
push r13
sub rsp, 0x40
xor r13d, r13d
mov rbx, rcx
test dword [rcx + 0x18c], 0x2000
mov edi, 1
je 0x1400048c5
call fcn.140003790
cmp eax, edi
cmove edi, r13d
mov rax, qword [rbx + 0x10]
mov ebp, r13d
test rax, rax
je 0x1400048db
mov rax, qword [rax]
inc ebp
test rax, rax
jne 0x1400048d1
lea ecx, [rbp + 2]
mov edx, reloc.WS2_32.dll_recv
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_calloc]
mov rsi, rax
test rax, rax
jne 0x14000491e
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov ecx, dword [rax]
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_strerror]
lea rdx, [0x1400ba008]
mov rcx, rbx
mov r8, rax
call fcn.14000fca0
xor eax, eax
add rsp, 0x40
pop r13
pop rdi
pop rsi
pop rbp
pop rbx
ret
mov rcx, qword [rbx + 0x150]
mov qword [rsp + 0x38], r12
mov r12d, 0xffffffff
mov qword [rsp + 0x30], r14
mov qword [rsp + 0x28], r15
mov r15d, r13d
mov dword [rsp + 0x78], r12d
cmp rcx, 0xffffffffffffffff
je 0x140004982
movzx eax, byte [rbx + 0x171]
test al, al
jne 0x140004982
mov eax, dword [rbx + 0x17c]
cmp dword [rbx + 0x178], eax
jae 0x140004982
cmp byte [rbx + 0x172], r13b
jne 0x140004982
mov qword [rsi], rcx
mov r12d, r13d
mov dword [rsi + 8], 0x300
mov r15d, 1
mov dword [rsp + 0x78], r13d
mov rcx, qword [rbx + 0x160]
mov r14d, 0xffffffff
cmp rcx, 0xffffffffffffffff
je 0x1400049ad
mov eax, r15d
mov r14d, r15d
add rax, rax
inc r15d
mov qword [rsi + rax*8], rcx
mov dword [rsi + rax*8 + 8], 0x300
test edi, edi
jne 0x1400049b6
mov r10d, r13d
jmp 0x1400049f4
mov eax, dword [rbx + 0x18c]
and eax, 4
test al, al
jne 0x1400049ee
lea rdx, [rsp + 0x88]
mov rcx, rbx
call fcn.140003e20
cmp eax, 1
jne 0x1400049ee
mov r10, qword [rsp + 0x88]
mov eax, 0x7fffffff
cmp r10, rax
cmova r10d, eax
jmp 0x1400049f4
mov r10d, 0xffffffff
mov r8, qword [rbx + 0x18]
mov edi, 0x300
test r8, r8
je 0x140004a66
mov r11d, 0x200
mov r9d, r15d
lea r12d, [r11 + 0x10]
nop
mov rax, qword [r8 + 0x110]
mov edx, r9d
shl rdx, 4
add rdx, rsi
mov qword [rdx], rax
mov ecx, dword [r8 + 0x124]
test ecx, ecx
je 0x140004a51
sub ecx, 1
je 0x140004a4a
sub ecx, 1
je 0x140004a43
cmp ecx, 1
jne 0x140004a55
mov r10d, r13d
jmp 0x140004a55
or word [rdx + 8], r11w
jmp 0x140004a55
or word [rdx + 8], r12w
jmp 0x140004a55
or word [rdx + 8], di
mov r8, qword [r8 + 8]
inc r9d
test r8, r8
jne 0x140004a10
mov r12d, dword [rsp + 0x78]
lea edx, [r15 + rbp]
test edx, edx
je 0x140004bac
mov r8d, r10d
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_WSAPoll]
test eax, eax
jns 0x140004abc
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2714
je 0x140004bac
mov ecx, eax
call fcn.14000f270
mov r8, rax
lea rdx, str.poll_failed:__s_n
mov rcx, rbx
call fcn.14000fca0
mov rcx, rsi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
xor eax, eax
jmp 0x140004bba
mov byte [rbx + 0x174], r13b
cmp r14d, 0xffffffff
je 0x140004b00
movsxd rax, r14d
add rax, rax
movzx ecx, word [rsi + rax*8 + 0xa]
and cx, di
cmp r13w, cx
je 0x140004b00
nop dword [rax]
mov rcx, qword [rbx + 0x160]
lea rdx, [rsp + 0x80]
xor r9d, r9d
lea r8d, [r9 + 4]
call qword [sym.imp.WS2_32.dll_recv]
test eax, eax
jg 0x140004ae0
movzx eax, byte [rbx + 0x170]
test al, al
jne 0x140004aac
mov r10, qword [rbx + 0x18]
mov r14d, r13d
test r10, r10
je 0x140004b8a
mov ebx, 0x607
mov r12d, 0x300
mov rdi, qword [r10 + 8]
cmp r14d, ebp
jae 0x140004b7b
mov rax, qword [r10 + 0x110]
lea ecx, [r14 + r15]
add rcx, rcx
cmp qword [rsi + rcx*8], rax
jne 0x140004b73
movzx edx, word [rsi + rcx*8 + 0xa]
mov rcx, r10
movzx eax, dx
mov r8d, edx
and ax, bx
cmp r13w, ax
setne r9b
shr r8d, 4
and dx, r12w
and r8b, 1
cmp r13w, dx
setne dl
call fcn.140002510
inc r14d
mov r10, rdi
test rdi, rdi
jne 0x140004b22
mov rbx, qword [rsp + 0x70]
mov edi, 0x300
mov r12d, dword [rsp + 0x78]
cmp r12d, 0xffffffff
je 0x140004bac
movsxd rcx, r12d
add rcx, rcx
movzx edx, word [rsi + rcx*8 + 0xa]
and dx, di
cmp r13w, dx
je 0x140004bac
mov rcx, rbx
call fcn.140003a20
mov rcx, rsi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov eax, 1
mov r14, qword [rsp + 0x30]
mov r12, qword [rsp + 0x38]
mov r15, qword [rsp + 0x28]
add rsp, 0x40
pop r13
pop rdi
pop rsi
pop rbp
pop rbx
ret