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

Disassembly:
push rbx
push rbp
push rsi
push r12
push r13
push r15
sub rsp, 0x188
mov rax, qword [0x1800ac030]
xor rax, rsp
mov qword [rsp + 0x160], rax
mov rax, qword [rsp + 0x1e0]
xor r13d, r13d
mov ebp, r9d
mov qword [rsp + 0x48], rax
lea rax, [rsp + 0x80]
mov dword [rsp + 0x34], r9d
mov esi, r8d
mov dword [rsp + 0x38], r8d
mov qword [rsp + 0x40], rdx
mov qword [rsp + 0x28], rax
mov r15, rcx
mov ebx, r13d
mov dword [rsp + 0x30], r13d
mov dword [rsp + 0x20], r13d
test rcx, rcx
je 0x18005205d
cmp dword [rcx], 0xbab1e
jne 0x18005205d
cmp dword [rcx + 0x178], ebx
je 0x180051cab
lea eax, [r13 + 8]
jmp 0x180051d9c
mov qword [rsp + 0x180], rdi
mov rdi, qword [rcx + 8]
mov r12d, 1
mov qword [rsp + 0x178], r14
test rdi, rdi
je 0x180051d2a
nop word [rax + rax]
lea rdx, [rsp + 0x50]
mov rcx, rdi
call fcn.180050a20
mov r9d, r13d
mov ecx, r12d
mov r11d, eax
lea r8, [rsp + 0x50]
nop dword [rax + rax]
or rdx, 0xffffffffffffffff
test r11d, ecx
je 0x180051cfe
mov rdx, qword [r8]
inc ebx
mov eax, ecx
rol eax, 0x10
test r11d, eax
je 0x180051d0d
mov rdx, qword [r8]
inc ebx
cmp rdx, 0xffffffffffffffff
je 0x180051d22
inc r9d
add r8, 8
rol ecx, 1
cmp r9d, 5
jb 0x180051cf0
mov rdi, qword [rdi]
test rdi, rdi
jne 0x180051cd0
lea rdx, [rsp + 0x3c]
mov rcx, r15
call fcn.180051450
mov r11d, dword [rsp + 0x3c]
test r11d, r11d
js 0x180051d4c
cmp r11d, ebp
cmovl ebp, r11d
mov dword [rsp + 0x34], ebp
mov r13d, dword [rsp + 0x1f0]
lea r14d, [rsi + rbx]
mov eax, r14d
test r13d, r13d
je 0x180051d6c
cmp qword [r15 + 0x180], 0xffffffffffffffff
je 0x180051d6c
inc eax
cmp eax, 0xa
jbe 0x180051dc2
mov ecx, eax
shl rcx, 4
call qword [fcn.1800339ec]
mov qword [rsp + 0x28], rax
test rax, rax
jne 0x180051dbd
mov eax, 3
mov rdi, qword [rsp + 0x180]
mov r14, qword [rsp + 0x178]
mov rcx, qword [rsp + 0x160]
xor rcx, rsp
call fcn.1800334b0
add rsp, 0x188
pop r15
pop r13
pop r12
pop rsi
pop rbp
pop rbx
ret
mov dword [rsp + 0x30], r12d
xor r10d, r10d
mov esi, r10d
test ebx, ebx
je 0x180051e97
mov rbp, qword [r15 + 8]
mov edi, r10d
test rbp, rbp
je 0x180051e93
mov r13, qword [rsp + 0x28]
nop word [rax + rax]
lea rdx, [rsp + 0x50]
mov rcx, rbp
call fcn.180050a20
xor r10d, r10d
mov rdx, rdi
shl rdx, 4
mov ecx, r12d
lea r9, [rsp + 0x50]
add rdx, r13
lea r13d, [r10 + 4]
mov r11d, eax
nop dword [rax]
or r8, 0xffffffffffffffff
test r11d, ecx
je 0x180051e40
mov rax, qword [r9]
mov word [rdx + 8], r12w
inc esi
mov qword [rdx], rax
mov r8, qword [r9]
inc rdi
add rdx, 0x10
mov eax, ecx
rol eax, 0x10
test r11d, eax
je 0x180051e61
mov rax, qword [r9]
mov word [rdx + 8], r13w
inc esi
mov qword [rdx], rax
mov r8, qword [r9]
inc rdi
add rdx, 0x10
cmp r8, 0xffffffffffffffff
je 0x180051e76
inc r10d
add r9, 8
rol ecx, 1
cmp r10d, 5
jb 0x180051e20
mov rbp, qword [rbp]
mov r13, qword [rsp + 0x28]
test rbp, rbp
jne 0x180051df0
mov r13d, dword [rsp + 0x1f0]
xor r10d, r10d
mov ebp, dword [rsp + 0x34]
mov r8d, dword [rsp + 0x38]
mov r9, qword [rsp + 0x28]
movsxd rax, esi
test r8d, r8d
je 0x180051ef4
mov rdx, qword [rsp + 0x40]
add rax, rax
add rdx, 8
add esi, r8d
lea rcx, [r9 + rax*8 + 8]
nop dword [rax]
mov rax, qword [rdx - 8]
mov word [rcx], r10w
mov qword [rcx - 8], rax
test byte [rdx], r12b
je 0x180051ed5
mov word [rcx], r12w
test byte [rdx], 2
je 0x180051ede
or word [rcx], 2
test byte [rdx], 4
je 0x180051ee7
or word [rcx], 4
add rcx, 0x10
add rdx, 0x10
dec r8
jne 0x180051ec0
test r13d, r13d
je 0x180051f17
mov rcx, qword [r15 + 0x180]
cmp rcx, 0xffffffffffffffff
je 0x180051f17
mov eax, esi
add rax, rax
inc esi
mov qword [r9 + rax*8], rcx
mov word [r9 + rax*8 + 8], r12w
test esi, esi
je 0x180051fdd
mov r8d, ebp
mov edx, esi
mov rcx, r9
call fcn.18004f300
mov edi, eax
test eax, eax
jle 0x180051fe8
mov eax, dword [rsp + 0x38]
movsxd rdx, ebx
test eax, eax
je 0x180051f92
mov r8, qword [rsp + 0x40]
shl rdx, 4
sub rdx, r8
lea rcx, [r8 + 0xa]
mov r8, qword [rsp + 0x28]
lea r9, [rdx + r8]
mov r8d, eax
xor ebp, ebp
nop
movsx edx, word [r9 + rcx]
movzx eax, bp
test r12b, dl
je 0x180051f70
mov eax, r12d
test dl, 4
je 0x180051f79
or ax, 4
test dl, 2
je 0x180051f82
or ax, 2
mov word [rcx], ax
add rcx, 0x10
dec r8
jne 0x180051f60
mov ebp, dword [rsp + 0x34]
test r13d, r13d
je 0x180051ff3
cmp qword [r15 + 0x180], 0xffffffffffffffff
mov rcx, qword [rsp + 0x28]
je 0x180051ffc
mov eax, r14d
add rax, rax
test byte [rcx + rax*8 + 0xa], r12b
je 0x180051ffc
mov rcx, qword [r15 + 0x180]
xor r9d, r9d
lea rdx, [rsp + 0x120]
lea r8d, [r9 + 0x40]
call qword [sym.imp.WS2_32.dll_recv]
test eax, eax
jns 0x180051fb3
mov rcx, qword [rsp + 0x28]
lea ebx, [rdi - 1]
jmp 0x180051ffe
mov rcx, qword [rsp + 0x28]
mov ebx, dword [rsp + 0x20]
jmp 0x180051ffe
mov ebx, dword [rsp + 0x20]
mov rcx, qword [rsp + 0x28]
jmp 0x180051ffe
mov rcx, qword [rsp + 0x28]
mov ebx, edi
jmp 0x180051ffe
mov ebx, edi
cmp dword [rsp + 0x30], 0
je 0x18005200b
call qword [fcn.1800337e4]
mov rax, qword [rsp + 0x48]
test rax, rax
je 0x180052017
mov dword [rax], ebx
cmp dword [rsp + 0x1e8], 0
je 0x180052056
test esi, esi
jne 0x180052056
xor eax, eax
lea rdx, [rsp + 0x30]
mov rcx, r15
mov dword [rsp + 0x30], eax
call fcn.180051540
test eax, eax
jne 0x180052056
mov eax, dword [rsp + 0x30]
test eax, eax
je 0x180052056
cmp eax, ebp
jg 0x18005204f
test eax, eax
cmovs eax, ebp
mov ebp, eax
mov ecx, ebp
call fcn.18004ef40
xor eax, eax
jmp 0x180051d8c
mov eax, 1
jmp 0x180051d9c