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

Disassembly:
push rbp
push rbx
push rsi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x1a0]
sub rsp, 0x2a0
mov rax, qword [0x140116008]
xor rax, rsp
mov qword [rbp + 0x190], rax
mov r15, qword [rbp + 0x200]
xor r8d, r8d
xor ebx, ebx
mov qword [rsp + 0x48], rcx
mov qword [rsp + 0x50], 1
mov r14, r9
mov dword [rbp - 0x80], r8d
mov rsi, rcx
test r9, r9
je 0x14001c016
mov rbx, qword [r9]
mov r8d, 1
mov qword [rbp - 0x78], rbx
mov dword [rbp - 0x80], r8d
mov qword [rsp + 0x2e8], rdi
lea r12, str.ytcp
movsxd r13, edx
test edx, edx
jle 0x14001c0cb
xor edi, edi
mov rsi, qword [rsi + rdi*8]
cmp dword [rsi + 0x17c], 3
je 0x14001c062
mov r9, r12
mov dword [rsp + 0x20], 0x52c
lea r8, str.ASSERT_FAILED:_s:_d_n
mov edx, 0x52c
mov rcx, r12
call fcn.14000a9a0
mov r8d, dword [rbp - 0x80]
mov rdx, qword [rsi + 0x1a0]
cmp rdx, 0xffffffffffffffff
je 0x14001c10e
xor eax, eax
test r8d, r8d
je 0x14001c08e
nop word [rax + rax]
cmp qword [rbp + rax*8 - 0x78], rdx
je 0x14001c08e
inc eax
cmp eax, r8d
jb 0x14001c080
cmp eax, r8d
jne 0x14001c0a9
cmp r8d, 0x40
jae 0x14001c0a9
mov qword [rbp + rax*8 - 0x78], rdx
mov r8d, dword [rbp - 0x80]
inc r8d
mov dword [rbp - 0x80], r8d
mov rax, qword [rsi + 0x1a0]
mov rsi, qword [rsp + 0x48]
cmp rax, rbx
cmovbe rax, rbx
inc rdi
mov rbx, rax
cmp rdi, r13
jl 0x14001c032
test rbx, rbx
je 0x14001c783
lea rax, [rsp + 0x50]
xor r9d, r9d
lea ecx, [rbx + 1]
mov qword [rsp + 0x20], rax
xor r8d, r8d
lea rdx, [rbp - 0x80]
call qword [sym.imp.WS2_32.dll_select]
test eax, eax
jns 0x14001c165
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
test r15, r15
jne 0x14001c14a
mov r12d, 0xfffffff8
mov eax, r12d
jmp 0x14001c785
test r15, r15
je 0x14001c140
mov dword [rsp + 0x28], 0x52e
lea r9, str.Invalid_argument
lea r8, str._s___s:_d_
mov qword [rsp + 0x20], r12
mov edx, 0x100
mov rcx, r15
call fcn.1400217a0
nop dword [rax + rax]
mov eax, 0xfffffffe
jmp 0x14001c785
mov r9, r15
mov r8d, eax
mov edx, 0x541
mov rcx, r12
call fcn.140019fe0
mov r12d, eax
jmp 0x14001c785
je 0x14001c783
mov r12d, 0xfffffff8
test r14, r14
je 0x14001c1dc
mov rcx, qword [r14]
lea rdx, [rbp - 0x80]
call qword [sym.imp.WS2_32.dll___WSAFDIsSet]
test eax, eax
je 0x14001c1dc
mov rcx, qword [r14]
lea r8d, [r12 + 9]
xor r9d, r9d
mov byte [rsp + 0x40], 0
lea rdx, [rsp + 0x40]
call qword [sym.imp.WS2_32.dll_recv]
test eax, eax
jns 0x14001c1cf
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
test r15, r15
jne 0x14001c1b6
mov eax, r12d
jmp 0x14001c1d4
mov r9, r15
lea rcx, str.ytcp
mov r8d, eax
mov edx, 0x11d
call fcn.140019fe0
jmp 0x14001c1d4
movzx eax, byte [rsp + 0x40]
test eax, eax
js 0x14001c785
test r13, r13
jle 0x14001c783
xor r14d, r14d
nop dword [rax + rax]
mov rbx, qword [rsi + r14*8]
lea rdx, [rbp - 0x80]
mov rcx, qword [rbx + 0x1a0]
call qword [sym.imp.WS2_32.dll___WSAFDIsSet]
test eax, eax
je 0x14001c777
mov rcx, qword [rbx + 8]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov edi, dword [rbx + 0x40]
mov ecx, dword [rbx + 0x44]
lea eax, [rdi - 0x100]
cmp ecx, eax
jl 0x14001c259
add edi, edi
movsxd rcx, edi
call fcn.140056e8c
movsxd r8, dword [rbx + 0x44]
mov rcx, rax
mov rdx, qword [rbx + 0x38]
mov rsi, rax
call fcn.140050fe0
mov rcx, qword [rbx + 0x38]
call fcn.140052f7c
mov ecx, dword [rbx + 0x44]
mov qword [rbx + 0x38], rsi
mov dword [rbx + 0x40], edi
jmp 0x14001c25d
mov rsi, qword [rbx + 0x38]
sub edi, ecx
movsxd rdx, ecx
mov rcx, qword [rbx + 0x1a0]
add rdx, rsi
mov r8d, edi
xor r9d, r9d
call qword [sym.imp.WS2_32.dll_recv]
mov edi, eax
test eax, eax
jne 0x14001c2b9
test r15, r15
je 0x14001c2b2
lea rax, str.ytcp
mov dword [rsp + 0x28], 0x2d0
lea r9, str.No_more_data
mov qword [rsp + 0x20], rax
lea r8, str._s___s:_d_
mov edx, 0x100
mov rcx, r15
call fcn.1400217a0
mov edi, 0xfffffff7
jmp 0x14001c2f7
jns 0x14001c2f7
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x14001c2ce
xor esi, esi
mov edi, esi
jmp 0x14001c2f9
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
test r15, r15
jne 0x14001c2de
mov edi, r12d
jmp 0x14001c2f7
mov r9, r15
lea rcx, str.ytcp
mov r8d, eax
mov edx, 0x2db
call fcn.140019fe0
mov edi, eax
xor esi, esi
call fcn.140009a00
mov qword [rbx + 0x168], rax
test edi, edi
jns 0x14001c48f
mov dword [rbx + 0x48], esi
lea rsi, [rbx + 0x54]
test rsi, rsi
je 0x14001c400
lea eax, [rdi + 0xe]
cmp eax, 0xe
ja case.default.0x14001c33c
lea rdx, [0x140000000]
cdqe
mov ecx, dword [rdx + rax*4 + 0x1c7b0]
add rcx, rdx
jmp rcx
lea r9, str.Success
jmp 0x14001c3cf
lea r9, str.API_not_initialized
jmp 0x14001c3cf
lea r9, str.Invalid_argument
jmp 0x14001c3cf
lea r9, str.Not_supported
jmp 0x14001c3cf
lea r9, str.Device_not_found
jmp 0x14001c3cf
lea r9, str.Version_mismatch
jmp 0x14001c3cf
lea r9, str.Device_busy
jmp 0x14001c3cf
lea r9, str.Timeout
jmp 0x14001c3cf
lea r9, str.I_O_error
jmp 0x14001c3cf
lea r9, str.No_more_data
jmp 0x14001c3cf
lea r9, str.Resource_exhausted
jmp 0x14001c3cf
lea r9, str.Double_access_to_the_same_device
jmp 0x14001c3cf
lea r9, str.Unauthorized_access
jmp 0x14001c3cf
lea r9, str.Real_time_clock_has_not_been_initialized
jmp 0x14001c3cf
lea r9, str.File_is_not_found
jmp 0x14001c3cf
lea r9, str.Unknown_error
lea rax, str.ytcp
mov dword [rsp + 0x28], 0x55f
lea r8, str._s___s:_d_
mov qword [rsp + 0x20], rax
mov edx, 0x100
mov rcx, rsi
call fcn.1400217a0
nop word [rax + rax]
and dword [rbx + 0x178], 0xfffffffe
mov r10, qword [rbx + 0x180]
mov dword [rbx + 0x50], edi
test r10, r10
je 0x14001c462
movsxd rax, dword [rbx + 0x48]
mov r8d, dword [rbx + 0x44]
mov rdx, rax
add rdx, qword [rbx + 0x38]
sub r8d, eax
mov rcx, qword [rbx + 0x188]
cmp edi, 0xfffffff7
jne 0x14001c445
lea rax, [0x140079790]
xor r9d, r9d
mov qword [rsp + 0x20], rax
jmp 0x14001c44d
mov qword [rsp + 0x20], rsi
mov r9d, edi
call r10
and dword [rbx + 0x178], 0xfffffffd
mov qword [rbx + 0x180], 0
mov rcx, qword [rbx + 0x1a0]
cmp rcx, 0xffffffffffffffff
je 0x14001c480
call qword [sym.imp.WS2_32.dll_closesocket]
mov qword [rbx + 0x1a0], 0xffffffffffffffff
mov rcx, qword [rbx + 0x10]
call qword [sym.imp.KERNEL32.dll_SetEvent]
jmp 0x14001c768
jle 0x14001c768
mov edx, dword [rbx + 0x44]
add edx, edi
cmp dword [rbx + 0x48], 0
mov dword [rbx + 0x44], edx
jge 0x14001c753
cmp edx, 8
jne 0x14001c510
mov rcx, qword [rbx + 0x38]
mov rax, qword [rcx]
cmp rax, qword [str.0K_r_n_r_n_r_n]
jne 0x14001c510
mov dword [rbx + 0x48], esi
mov byte [rcx], 0x4f
lea rcx, [rbx + 0x54]
test rcx, rcx
je 0x14001c4f7
lea rax, str.ytcp
mov dword [rsp + 0x28], 0x56b
lea r9, str.No_more_data
mov qword [rsp + 0x20], rax
lea r8, str._s___s:_d_
mov edx, 0x100
call fcn.1400217a0
mov edx, 1
mov dword [rbx + 0x50], 0xfffffff7
mov rcx, rbx
call fcn.14001bf00
jmp 0x14001c753
cmp edx, 4
jl 0x14001c527
mov rax, qword [rbx + 0x38]
mov ecx, dword [rax]
cmp ecx, dword [str.OK_r_n]
je 0x14001c750
cmp edx, 0xc
jl 0x14001c753
mov rcx, qword [rbx + 0x38]
mov rax, qword [rcx]
cmp rax, qword [str.HTTP_1.1_401]
jne 0x14001c750
mov eax, dword [rcx + 8]
cmp eax, dword [0x14010b898]
jne 0x14001c750
mov rax, qword [rbx]
mov qword [rsp + 0x58], rsi
mov qword [rsp + 0x68], rsi
mov qword [rsp + 0x60], rsi
cmp qword [rax + 0x10], 0
mov qword [rsp + 0x70], rsi
mov qword [rsp + 0x78], rsi
je 0x14001c700
mov r8d, dword [rbx + 0x4c]
lea eax, [r8 + 1]
mov dword [rbx + 0x4c], eax
cmp r8d, 3
jg 0x14001c700
lea rax, [rsp + 0x78]
mov qword [rsp + 0x30], rax
lea r9, [rsp + 0x68]
lea rax, [rsp + 0x70]
mov qword [rsp + 0x28], rax
lea r8, [rsp + 0x58]
lea rax, [rsp + 0x60]
mov qword [rsp + 0x20], rax
call fcn.140015350
test eax, eax
js 0x14001c753
mov rdx, qword [rsp + 0x58]
lea r8, str.Digest
mov rcx, rsi
movzx eax, byte [rdx + rcx]
inc rcx
cmp al, byte [r8 + rcx - 1]
jne 0x14001c6ea
cmp rcx, 7
jne 0x14001c5d3
mov rdx, qword [rsp + 0x60]
lea r8, str.auth
mov rcx, rsi
nop word [rax + rax]
movzx eax, byte [rdx + rcx]
inc rcx
cmp al, byte [r8 + rcx - 1]
jne 0x14001c6ea
cmp rcx, 5
jne 0x14001c600
mov rcx, qword [rbx + 0x1a0]
call qword [sym.imp.WS2_32.dll_closesocket]
mov rcx, qword [rbx]
mov qword [rbx + 0x1a0], 0xffffffffffffffff
mov rcx, qword [rcx + 0x758]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rcx, qword [rbx]
mov rdx, qword [rsp + 0x68]
add rcx, 0x7a0
call fcn.140019f50
mov rcx, qword [rbx]
mov rdx, qword [rsp + 0x70]
add rcx, 0x7a8
call fcn.140019f50
mov rcx, qword [rbx]
mov rdx, qword [rsp + 0x78]
add rcx, 0x7b0
call fcn.140019f50
mov r9, qword [rbx]
mov rax, r9
mov rdx, qword [r9 + 0x10]
test rdx, rdx
je 0x14001c6aa
mov r8, qword [r9 + 0x18]
test r8, r8
je 0x14001c6aa
lea rcx, [r9 + 0x7b8]
mov r9, qword [r9 + 0x7a0]
call fcn.140014c60
mov rax, qword [rbx]
mov dword [rax + 0x7c8], esi
mov rcx, qword [rbx]
mov rcx, qword [rcx + 0x758]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov rdx, qword [rbx + 0x170]
lea r8, [rbx + 0x54]
mov rcx, rbx
call fcn.14001b630
mov dword [rbx + 0x50], eax
test eax, eax
jns 0x14001c753
xor edx, edx
mov rcx, rbx
call fcn.14001bf00
jmp 0x14001c753
lea rcx, [rbx + 0x54]
mov dword [rbx + 0x48], esi
test rcx, rcx
je 0x14001c73d
mov dword [rsp + 0x28], 0x597
jmp 0x14001c719
lea rcx, [rbx + 0x54]
mov qword [rbx + 0x44], 0
test rcx, rcx
je 0x14001c73d
mov dword [rsp + 0x28], 0x57c
lea rax, str.ytcp
mov edx, 0x100
lea r9, str.Unauthorized_access
mov qword [rsp + 0x20], rax
lea r8, str._s___s:_d_
call fcn.1400217a0
xor edx, edx
mov dword [rbx + 0x50], 0xfffffff4
mov rcx, rbx
call fcn.14001bf00
jmp 0x14001c753
mov dword [rbx + 0x48], esi
cmp dword [rbx + 0x50], 0
jne 0x14001c768
lea rdx, [rbx + 0x54]
mov rcx, rbx
call fcn.14001b560
mov dword [rbx + 0x50], eax
mov rcx, qword [rbx + 8]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov rsi, qword [rsp + 0x48]
inc r14
cmp r14, r13
jl 0x14001c1f0
xor eax, eax
mov rdi, qword [rsp + 0x2e8]
mov rcx, qword [rbp + 0x190]
xor rcx, rsp
call fcn.14004ee60
add rsp, 0x2a0
pop r15
pop r14
pop r13
pop r12
pop rsi
pop rbx
pop rbp
ret