Function at 0x140047030
Capabilities:
Check for time delay via gettickcount

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
push rbp
push rdi
push r12
push r14
mov rbp, rsp
sub rsp, 0x68
xor r14d, r14d
mov rdi, r8
mov r12, rcx
mov dword [rbp + 0x38], 0
mov dword [rbp + 0x40], 0
mov dword [rbp - 0x34], 0
test r8, r8
je 0x14004819b
cmp dword [r8 + 0x8c10], 0xc0dedbad
jne 0x14004819b
mov qword [rsp + 0x60], rbx
mov qword [rsp + 0x58], rsi
mov qword [rsp + 0x50], r13
xor r13d, r13d
mov qword [rsp + 0x48], r15
lea ebx, [r14 + 3]
cmp dword [r8 + 0x8acc], r13d
je 0x1400470e5
mov r9, qword [r8 + 0x8ad8]
lea rdx, str.Pipe_broke:_handle_0x_p__url___s_n
mov rcx, r8
call fcn.140052ba0
mov eax, dword [rdi + 0x18]
cmp eax, 0x10
jge 0x1400470d5
cmp eax, 2
je 0x1400470cd
mov dword [rdi + 0x18], 2
or r14d, 0xffffffff
mov dword [rdi + 0x1c], r13d
mov dword [rdi + 0x8acc], r13d
mov qword [rdi + 0x10], r13
jmp 0x14004814c
mov rcx, qword [r8 + 0x10]
test rcx, rcx
jne 0x140047133
mov r8d, dword [r8 + 0x18]
lea eax, [r8 - 3]
cmp eax, 0xb
ja 0x14004712e
lea rdx, str.In_state__d_with_no_easy_conn__bail_out__n
mov rcx, rdi
call fcn.140052c80
mov eax, 4
mov r13, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x58]
mov rbx, qword [rsp + 0x60]
mov r15, qword [rsp + 0x48]
add rsp, 0x68
pop r14
pop r12
pop rdi
pop rbp
ret
test rcx, rcx
je 0x140047140
mov eax, dword [rdi + 0x18]
sub eax, ebx
cmp eax, 0xc
ja 0x140047140
mov qword [rcx], rdi
cmp qword [rdi + 0x10], r13
je 0x1400472db
mov ecx, dword [rdi + 0x18]
lea eax, [rcx - 2]
cmp eax, 0xd
ja 0x1400472db
xor r8d, r8d
cmp ecx, 7
lea rdx, [rbp + 0x30]
setle r8b
mov rcx, rdi
call fcn.14004f920
test eax, eax
jns 0x1400472db
mov eax, dword [rdi + 0x18]
mov rcx, qword [rdi + 0x7d0]
cmp eax, ebx
jne 0x1400471c7
mov edx, dword [rbp + 0x34]
mov rax, rcx
shr rax, 0x20
sub edx, eax
mov eax, 0x10624dd3
imul edx
mov eax, dword [rbp + 0x30]
sar edx, 6
sub eax, ecx
mov r8d, edx
shr r8d, 0x1f
add r8d, edx
lea rdx, str.Resolving_timed_out_after__ld_milliseconds
imul ecx, eax, 0x3e8
add r8d, ecx
mov rcx, rdi
call fcn.140052c80
jmp 0x1400472a9
cmp eax, 4
mov rax, rcx
jne 0x14004720e
mov edx, dword [rbp + 0x34]
shr rax, 0x20
sub edx, eax
mov eax, 0x10624dd3
imul edx
mov eax, dword [rbp + 0x30]
sar edx, 6
sub eax, ecx
mov r8d, edx
shr r8d, 0x1f
add r8d, edx
lea rdx, str.Connection_timed_out_after__ld_milliseconds
imul ecx, eax, 0x3e8
add r8d, ecx
mov rcx, rdi
call fcn.140052c80
jmp 0x1400472a9
mov r8, qword [rdi + 0x90]
shr rax, 0x20
cmp r8, 0xffffffffffffffff
je 0x14004726c
mov r9, qword [rdi + 0xd0]
mov qword [rsp + 0x20], r8
mov rdx, r9
sub r9d, ecx
mov rcx, rdi
shr rdx, 0x20
sub edx, eax
mov eax, 0x10624dd3
imul edx
sar edx, 6
mov eax, edx
shr eax, 0x1f
add edx, eax
imul eax, r9d, 0x3e8
mov r9, qword [rdi + 0xb0]
add edx, eax
mov r8d, edx
lea rdx, [0x140177b20]
call fcn.140052c80
jmp 0x1400472a9
mov edx, dword [rbp + 0x34]
mov r9, qword [rdi + 0xb0]
sub edx, eax
mov eax, 0x10624dd3
imul edx
mov eax, dword [rbp + 0x30]
sar edx, 6
sub eax, ecx
mov r8d, edx
shr r8d, 0x1f
add r8d, edx
lea rdx, [0x140177b70]
imul ecx, eax, 0x3e8
add r8d, ecx
mov rcx, rdi
call fcn.140052c80
mov rax, qword [rdi + 0x10]
mov dword [rax + 0x2a8], 1
mov dword [rdi + 0x1c], 0x1c
cmp dword [rdi + 0x18], 0x10
je 0x140048152
mov rax, qword [rdi + 0x78]
mov dword [rdi + 0x18], reloc.WS2_32.dll_recv
dec dword [rax + 0x1c]
jmp 0x14004814c
movsxd rax, dword [rdi + 0x18]
cmp eax, 0x11
ja case.default.0x1400472f9
lea rdx, [0x140000000]
mov ecx, dword [rdx + rax*4 + 0x481ac]
add rcx, rdx
jmp rcx
mov rcx, rdi
call fcn.140059ea0
mov dword [rdi + 0x1c], eax
test eax, eax
jne case.0x1400472f9.1
cmp dword [rdi + 0x18], 2
je 0x14004731b
mov dword [rdi + 0x18], 2
mov edx, 1
mov rcx, rdi
call fcn.14005fb50
or r14d, 0xffffffff
jmp case.0x1400472f9.1
call qword [sym.imp.KERNEL32.dll_GetTickCount]
lea r8, [rbp - 0x34]
mov dword [rbp - 0x34], r13d
mov ecx, eax
mov eax, 0x10624dd3
mul ecx
shr edx, 6
mov dword [rbp - 0x30], edx
imul eax, edx, 0x3e8
sub ecx, eax
lea rdx, [rdi + 0x10]
imul eax, ecx, 0x3e8
mov dword [rbp - 0x2c], eax
mov rax, qword [rbp - 0x30]
mov rcx, rdi
mov qword [rdi + 0x7d0], rax
call fcn.14004e8d0
mov r15d, dword [rbp - 0x34]
mov ebx, eax
test eax, eax
jne 0x1400473ae
mov rcx, qword [rdi + 0x10]
mov rax, qword [rcx + 0x408]
cmp qword [rax + 0x18], r13
jne 0x1400473b5
mov rax, qword [rcx + 0x410]
cmp qword [rax + 0x18], r13
jne 0x1400473b5
test r15d, r15d
jne 0x1400473d6
lea rdx, [rbp + 0x38]
call fcn.14004f1e0
mov ebx, eax
cmp ebx, 0x59
jne 0x1400473be
jmp 0x1400473d2
mov dword [rbp + 0x38], 1
jmp 0x1400473d6
test ebx, ebx
je 0x1400473d6
mov rcx, qword [rdi + 0x10]
test rcx, rcx
je 0x1400473d6
xor edx, edx
call fcn.14004b8e0
mov qword [rdi + 0x10], r13
mov dword [rdi + 0x1c], ebx
cmp ebx, 0x59
jne 0x140047410
cmp dword [rdi + 0x18], 1
je 0x1400473eb
mov dword [rdi + 0x18], 1
mov rcx, qword [r12 + 0x28]
mov r8, rdi
mov rdx, qword [rcx + 8]
call fcn.14005aa10
xor ecx, ecx
mov edx, 0x1b
test eax, eax
cmove ecx, edx
mov dword [rdi + 0x1c], ecx
jmp 0x140047ae2
test ebx, ebx
jne 0x140047ae2
mov rdx, qword [rdi + 0x10]
mov rcx, rdi
call fcn.140057a20
mov dword [rdi + 0x1c], eax
test eax, eax
jne 0x140047adc
test r15d, r15d
je 0x140047448
lea ebx, [rax + 3]
cmp dword [rdi + 0x18], ebx
je case.0x1400472f9.1
mov dword [rdi + 0x18], ebx
jmp case.0x1400472f9.1
or r14d, 0xffffffff
cmp dword [rbp + 0x38], r13d
je 0x140047483
mov eax, dword [r12 + 0x58]
neg eax
sbb ecx, ecx
add ecx, 8
cmp dword [rdi + 0x18], ecx
je 0x140047ae2
mov dword [rdi + 0x18], ecx
lea ebx, [r14 + 4]
cmp ecx, 0x10
jne case.0x1400472f9.1
mov rax, qword [rdi + 0x78]
dec dword [rax + 0x1c]
jmp case.0x1400472f9.1
mov rax, qword [rdi + 0x10]
cmp dword [rax + 0x7d0], 1
jne 0x140047705
cmp dword [rdi + 0x18], 5
mov ebx, 3
je case.0x1400472f9.1
mov dword [rdi + 0x18], 5
jmp case.0x1400472f9.1
mov r15, qword [rdi + 0x10]
cmp qword [rdi + 0x88], r13
je 0x1400474c6
mov edx, ebx
mov rcx, rdi
call fcn.14005a990
mov r8d, dword [r15 + 0xe8]
mov rdx, qword [r15 + 0xb8]
lea r9, [rbp - 0x34]
mov rcx, r15
call fcn.1400513d0
mov rbx, rax
mov qword [rbp - 0x30], rax
test rax, rax
je 0x140047514
inc dword [rax + 0x10]
mov qword [r15 + 0x670], rax
mov dword [r15 + 0x678], 1
lea rdx, str.Hostname_was_found_in_DNS_cache_n
mov rcx, rdi
mov dword [rdi + 0x1c], r13d
call fcn.140052ba0
cmp dword [rbp - 0x34], r13d
je 0x140047529
lea rdx, [0x140177bf0]
mov rcx, rdi
call fcn.140052ba0
mov r8, qword [rdi + 0x88]
test r8, r8
je 0x140047552
test byte [r8], 8
je 0x140047552
mov rax, qword [r8 + 0x10]
test rax, rax
je 0x140047552
mov r8, qword [r8 + 0x18]
mov edx, 3
mov rcx, rdi
call rax
test rbx, rbx
jne 0x14004756b
mov rcx, qword [rdi + 0x10]
lea rdx, [rbp - 0x30]
call fcn.1400520b0
mov rbx, qword [rbp - 0x30]
mov dword [rdi + 0x1c], eax
mov rdx, rdi
mov rcx, r12
call fcn.140048570
test rbx, rbx
je 0x14004761b
mov rbx, qword [rdi + 0x10]
mov rax, qword [rbx + 0x670]
test rax, rax
je 0x14004759a
mov qword [rbx + 0x50], rax
mov qword [rbx + 0x670], r13
lea rdx, [rbp + 0x38]
mov rcx, rbx
call fcn.14004f1e0
mov r15d, eax
test eax, eax
je 0x1400475b7
xor edx, edx
mov rcx, rbx
call fcn.14004b8e0
mov dword [rdi + 0x1c], r15d
test r15d, r15d
je 0x1400475c6
mov qword [rdi + 0x10], r13
jmp 0x14004761b
or r14d, 0xffffffff
cmp dword [rbp + 0x38], r13d
je 0x1400475f2
mov eax, dword [r12 + 0x58]
neg eax
sbb ecx, ecx
add ecx, 8
cmp dword [rdi + 0x18], ecx
je 0x14004761b
mov dword [rdi + 0x18], ecx
cmp ecx, 0x10
jne 0x14004761b
mov rax, qword [rdi + 0x78]
dec dword [rax + 0x1c]
jmp 0x14004761b
mov rax, qword [rdi + 0x10]
cmp dword [rax + 0x7d0], 1
jne 0x14004760e
cmp dword [rdi + 0x18], 5
je 0x14004761b
mov dword [rdi + 0x18], 5
jmp 0x14004761b
cmp dword [rdi + 0x18], 4
je 0x14004761b
mov dword [rdi + 0x18], 4
mov ebx, 3
cmp dword [rdi + 0x1c], r13d
je case.0x1400472f9.1
lea r13d, [rbx - 2]
jmp case.0x1400472f9.1
mov rbx, qword [rdi + 0x10]
mov rcx, rbx
mov dword [rbx + 0x2a8], r13d
call fcn.140062c40
test eax, eax
jne 0x1400476e0
cmp dword [rbx + 0x7d0], 1
je 0x1400476de
mov rax, qword [rbx + 0x328]
test byte [rax + 0x78], 1
je 0x1400476d7
lea r9, [rbp + 0x38]
mov rcx, rbx
mov dword [rbx + 0x1f0], 1
call fcn.140069b70
test eax, eax
jne 0x1400476cb
cmp dword [rbp + 0x38], r13d
je 0x1400476de
mov rbx, qword [rbx]
call qword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, eax
mov eax, 0x10624dd3
mul ecx
shr edx, 6
mov dword [rbp - 0x30], edx
imul eax, edx, 0x3e8
mov rdx, qword [rbx + 0x7d0]
sub ecx, eax
imul eax, ecx, 0x3e8
mov dword [rbp - 0x2c], eax
mov rcx, qword [rbp - 0x30]
call fcn.1400534d0
movsd qword [rbx + 0x7a8], xmm0
jmp 0x1400476de
mov dword [rbx + 0x2a8], 1
jmp 0x1400476e0
mov dword [rbp + 0x38], 1
xor eax, eax
mov rcx, qword [rdi + 0x10]
mov dword [rdi + 0x1c], eax
cmp dword [rcx + 0x300], r13d
jne 0x140047758
test eax, eax
jne 0x140047ae2
cmp dword [rcx + 0x7d0], 2
jne 0x140047ae2
cmp dword [rdi + 0x18], 4
mov ebx, 3
je case.0x1400472f9.1
mov dword [rdi + 0x18], 4
jmp case.0x1400472f9.1
mov rcx, qword [rdi + 0x10]
lea r8, [rbp - 0x34]
call fcn.1400503c0
mov ebx, dword [rbp - 0x34]
mov dword [rdi + 0x1c], eax
test ebx, ebx
je 0x14004774b
test eax, eax
jne 0x14004774b
mov rcx, qword [rdi + 0x10]
lea rdx, [rbp + 0x38]
call fcn.14004c6f0
mov dword [rdi + 0x1c], eax
mov rax, qword [rdi + 0x10]
cmp dword [rax + 0x300], r13d
je 0x14004777a
or r14d, 0xffffffff
cmp dword [rdi + 0x18], 2
mov dword [rdi + 0x1c], r13d
lea ebx, [r14 + 4]
je case.0x1400472f9.1
mov dword [rdi + 0x18], 2
jmp case.0x1400472f9.1
cmp dword [rdi + 0x1c], r13d
jne 0x140047adc
test ebx, ebx
je 0x140047ae2
cmp dword [rbp + 0x38], r13d
jne 0x1400477c7
cmp dword [rax + 0x7d0], 1
jne 0x1400477b1
cmp dword [rdi + 0x18], 5
je 0x1400477e7
mov dword [rdi + 0x18], 5
or r14d, 0xffffffff
jmp 0x140047ae2
cmp dword [rdi + 0x18], 6
je 0x1400477e7
mov dword [rdi + 0x18], 6
or r14d, 0xffffffff
jmp 0x140047ae2
mov eax, dword [r12 + 0x58]
neg eax
sbb ecx, ecx
add ecx, 8
cmp dword [rdi + 0x18], ecx
je 0x1400477e7
mov dword [rdi + 0x18], ecx
cmp ecx, 0x10
jne 0x1400477e7
mov rax, qword [rdi + 0x78]
dec dword [rax + 0x1c]
or r14d, 0xffffffff
jmp 0x140047ae2
mov rcx, qword [rdi + 0x10]
xor edx, edx
test rcx, rcx
je 0x140047820
mov rax, qword [rcx + 0x320]
cmp qword [rax + 0x30], rdx
je 0x140047820
mov dword [rbp + 0x38], edx
mov rax, qword [rcx + 0x320]
lea rdx, [rbp + 0x38]
call qword [rax + 0x30]
mov edx, eax
mov eax, dword [rbp + 0x38]
jmp 0x140047828
mov eax, 1
mov dword [rbp + 0x38], eax
mov dword [rdi + 0x1c], edx
test edx, edx
jne 0x140047860
test eax, eax
je case.0x1400472f9.1
mov eax, dword [r12 + 0x58]
neg eax
sbb ecx, ecx
add ecx, 8
cmp dword [rdi + 0x18], ecx
je 0x140047857
mov dword [rdi + 0x18], ecx
cmp ecx, 0x10
jne 0x140047857
mov rax, qword [rdi + 0x78]
dec dword [rax + 0x1c]
or r14d, 0xffffffff
jmp case.0x1400472f9.1
lea rcx, [rdi + 0x10]
mov r8d, 1
call fcn.14004f430
mov r13d, 1
jmp case.0x1400472f9.1
mov rcx, qword [rdi + 0x10]
cmp dword [rcx + 0x404], r13d
jne case.0x1400472f9.1
mov rax, qword [rcx + 0x408]
mov rdx, qword [rax]
test rdx, rdx
je case.0x1400472f9.1
xor eax, eax
cmp qword [rdx], rdi
sete al
test eax, eax
je case.0x1400472f9.1
mov dword [rcx + 0x404], 1
cmp dword [rdi + 0x18], 8
je 0x1400478c5
mov dword [rdi + 0x18], 8
or r14d, 0xffffffff
jmp case.0x1400472f9.1
cmp dword [rdi + 0x530], r13d
je 0x1400478fc
mov rax, qword [rdi + 0x10]
mov dword [rax + 0x2a8], r13d
cmp dword [rdi + 0x18], 0xf
je 0x1400478ef
mov dword [rdi + 0x18], reloc.WS2_32.dll_ntohs
mov dword [rdi + 0x1c], r13d
or r14d, 0xffffffff
jmp case.0x1400472f9.1
mov r15, qword [rdi + 0x10]
xor ebx, ebx
mov rax, qword [r15 + 0x320]
mov r12, qword [r15]
mov r8, qword [rax + 0x10]
test r8, r8
je 0x140047972
lea rdx, [rbp + 0x40]
mov rcx, r15
call r8
mov ebx, eax
cmp eax, 0x37
jne 0x140047960
cmp dword [r15 + 0x2ac], r13d
je 0x140047972
cmp qword [r12 + 0x78], r13
jne 0x1400479c4
lea rcx, [rdi + 0x10]
call fcn.14005a650
mov ebx, eax
test eax, eax
jne 0x140047972
mov r15, qword [rdi + 0x10]
lea rdx, [rbp + 0x40]
mov rax, qword [r15 + 0x320]
mov rcx, r15
call qword [rax + reloc.WS2_32.dll_recv]
mov ebx, eax
test ebx, ebx
jne 0x140047972
cmp dword [rbp + 0x40], r13d
je 0x140047972
mov rcx, r15
call fcn.14004f770
mov dword [rdi + 0x1c], ebx
test ebx, ebx
jne 0x140047a20
cmp dword [rbp + 0x40], r13d
jne 0x1400479e2
cmp dword [rdi + 0x6bc], r13d
je 0x1400479cb
mov eax, dword [rdi + 0x8b18]
sub eax, 4
test eax, 0xfffffffd
jne 0x1400479cb
lea rcx, [rdi + 0x10]
xor r8d, r8d
xor edx, edx
call fcn.14004f430
cmp dword [rdi + 0x18], 0xf
je 0x1400479b7
mov dword [rdi + 0x18], reloc.WS2_32.dll_ntohs
mov r12, qword [rbp + 0x28]
or r14d, 0xffffffff
jmp 0x140047ae2
mov ebx, 0x37
jmp 0x140047972
cmp dword [rdi + 0x18], 9
je 0x1400479d9
mov eax, 9
mov dword [rdi + 0x18], eax
mov r12, qword [rbp + 0x28]
jmp 0x140047ae2
mov rax, qword [rdi + 0x10]
cmp dword [rax + 0x2c8], r13d
je 0x140047a05
cmp dword [rdi + 0x18], 0xa
je 0x1400479fc
mov dword [rdi + 0x18], 0xa
mov r12, qword [rbp + 0x28]
jmp 0x140047ae2
cmp dword [rdi + 0x18], 0xb
je 0x140047a13
mov ecx, ntohs
mov dword [rdi + 0x18], ecx
mov r12, qword [rbp + 0x28]
or r14d, 0xffffffff
jmp 0x140047ae2
cmp ebx, 0x37
jne 0x140047ac4
mov rcx, qword [rdi + 0x10]
cmp dword [rcx + 0x2ac], r13d
je 0x140047ac4
lea rdx, [rbp - 0x30]
mov qword [rbp - 0x30], r13
xor r15d, r15d
call fcn.14005a780
mov rbx, qword [rbp - 0x30]
test eax, eax
je 0x140047a5b
mov dword [rdi + 0x1c], eax
lea r13d, [r15 + 1]
jmp 0x140047a62
test rbx, rbx
setne r15b
mov edx, dword [rdi + 0x1c]
lea rcx, [rdi + 0x10]
xor r8d, r8d
call fcn.14004f430
test r15d, r15d
je 0x140047ad8
test eax, eax
je 0x140047a91
cmp eax, 0x37
je 0x140047a91
mov rcx, rbx
mov dword [rdi + 0x1c], eax
call qword [case.0x140054204.2]
mov r12, qword [rbp + 0x28]
jmp 0x140047ae2
mov r8d, 2
mov rdx, rbx
mov rcx, rdi
call fcn.14005a300
test eax, eax
jne 0x140047a7f
cmp dword [rdi + 0x18], 2
je 0x140047ab3
mov dword [rdi + 0x18], 2
mov r12, qword [rbp + 0x28]
or r14d, 0xffffffff
mov dword [rdi + 0x1c], 0
jmp 0x140047ae2
cmp qword [rdi + 0x10], r13
je 0x140047ad8
lea rcx, [rdi + 0x10]
xor r8d, r8d
mov edx, ebx
call fcn.14004f430
mov r12, qword [rbp + 0x28]
mov r13d, 1
mov ebx, 3
cmp dword [rdi + 0x18], 0x10
jge 0x140048150
cmp dword [rdi + 0x1c], 0
je 0x140048101
mov rax, qword [rdi + 0x10]
mov dword [rdi + 0x8acc], 0
test rax, rax
je 0x1400472be
mov dword [rax + 0x404], 0
mov rax, qword [rdi + 0x10]
mov dword [rax + 0x400], 0
mov rax, qword [rdi + 0x10]
mov rcx, qword [rax + 0x408]
mov rdx, qword [rcx]
test rdx, rdx
je 0x1400480a7
cmp qword [rdx], rdi
je 0x14004809f
mov rdx, qword [rdx + 0x10]
test rdx, rdx
jne 0x140047b41
jmp 0x1400480a7
mov rcx, qword [rdi + 0x10]
xor edx, edx
test rcx, rcx
je 0x140047b88
mov rax, qword [rcx + 0x320]
cmp qword [rax + 0x38], rdx
je 0x140047b88
mov dword [rbp + 0x40], edx
mov rax, qword [rcx + 0x320]
lea rdx, [rbp + 0x40]
call qword [rax + 0x38]
mov edx, eax
mov eax, dword [rbp + 0x40]
jmp 0x140047b90
mov eax, 1
mov dword [rbp + 0x40], eax
mov dword [rdi + 0x1c], edx
test edx, edx
jne 0x140047bc4
test eax, eax
je case.0x1400472f9.1
mov rax, qword [rdi + 0x10]
mov ecx, dword [rax + 0x2c8]
neg ecx
sbb eax, eax
add eax, 0xb
cmp dword [rdi + 0x18], eax
je 0x140047857
mov dword [rdi + 0x18], eax
cmp eax, 0x10
jmp 0x14004784e
lea rcx, [rdi + 0x10]
xor r8d, r8d
call fcn.14004f430
mov r13d, 1
jmp case.0x1400472f9.1
mov r15, qword [rdi + 0x10]
xor edx, edx
xor ebx, ebx
mov dword [rbp - 0x38], edx
mov rax, qword [r15 + 0x320]
mov r8, qword [rax + 0x20]
test r8, r8
je 0x140047c19
lea rdx, [rbp - 0x38]
mov rcx, r15
call r8
mov edx, dword [rbp - 0x38]
mov ebx, eax
test eax, eax
jne 0x140047c19
cmp edx, 1
jne 0x140047c19
mov rcx, r15
call fcn.14004f770
mov edx, dword [rbp - 0x38]
mov dword [rdi + 0x1c], ebx
test ebx, ebx
jne 0x140047c4c
test edx, edx
je 0x140047ae2
cmp edx, 1
mov eax, 9
mov ecx, ntohs
cmove eax, ecx
cmp dword [rdi + 0x18], eax
je 0x1400477e7
mov dword [rdi + 0x18], eax
cmp eax, 0x10
jmp 0x1400477de
lea rcx, [rdi + 0x10]
xor r8d, r8d
mov edx, ebx
call fcn.14004f430
jmp 0x140047adc
mov rbx, qword [rdi + 0x10]
mov rcx, qword [rbx + 0x408]
mov rdx, qword [rcx]
test rdx, rdx
je 0x140047cb5
cmp qword [rdx], rdi
je 0x140047c82
mov rdx, qword [rdx + 0x10]
test rdx, rdx
jne 0x140047c72
jmp 0x140047cb5
mov r8, qword [rbx + 0x410]
mov r9, qword [r8 + 8]
call fcn.14005ac40
mov rcx, qword [rbx + 0x408]
cmp qword [rcx], r13
je 0x140047cb5
mov dword [rbx + 0x404], r13d
mov rcx, qword [rcx]
mov edx, 1
mov rcx, qword [rcx]
call fcn.140048fa0
mov rcx, r12
call fcn.140049280
mov rax, qword [rdi + 0x10]
cmp qword [rax + 0x338], 0xffffffffffffffff
jne 0x140047cef
cmp qword [rax + 0x340], 0xffffffffffffffff
jne 0x140047cef
cmp dword [rdi + 0x18], 0xf
je 0x1400477e7
mov dword [rdi + 0x18], reloc.WS2_32.dll_ntohs
or r14d, 0xffffffff
jmp 0x140047ae2
cmp dword [rdi + 0x18], 0xc
je 0x1400477e7
mov dword [rdi + 0x18], recv
or r14d, 0xffffffff
jmp 0x140047ae2
mov rcx, qword [rdi + 0x10]
cmp dword [rcx + 0x400], r13d
jne case.0x1400472f9.1
mov rax, qword [rcx + 0x410]
mov rdx, qword [rax]
test rdx, rdx
je case.0x1400472f9.1
xor eax, eax
cmp qword [rdx], rdi
sete al
test eax, eax
je case.0x1400472f9.1
mov dword [rcx + 0x400], 1
cmp dword [rdi + 0x18], 0xd
je 0x140047d54
mov dword [rdi + 0x18], send
or r14d, 0xffffffff
jmp case.0x1400472f9.1
mov rcx, qword [rdi + 0x10]
call fcn.14005fd00
test eax, eax
je 0x140047d73
mov dword [rdi + 0x1c], 0x2a
jmp 0x140047d82
mov rdx, qword [rbp + 0x30]
mov rcx, rdi
call fcn.140060370
mov dword [rdi + 0x1c], eax
mov rax, qword [rdi + 0x360]
test rax, rax
je 0x140047d9b
cmp qword [rdi + 0x790], rax
jge case.0x1400472f9.1
mov rax, qword [rdi + 0x368]
test rax, rax
je 0x140047db4
cmp qword [rdi + 0x788], rax
jge case.0x1400472f9.1
cmp dword [rdi + 0x18], 0xd
je case.0x1400472f9.1
mov dword [rdi + 0x18], send
jmp case.0x1400472f9.1
mov rcx, qword [rdi + 0x360]
xor ebx, ebx
xor r15d, r15d
mov qword [rbp - 0x30], rbx
test rcx, rcx
jle 0x140047e18
mov rdx, qword [rdi + 0x790]
cmp rdx, rcx
jle 0x140047e18
mov eax, dword [rdi + 0x468]
mov r8d, 0x4000
mov dword [rdi + 0x18], send
test eax, eax
cmovne r8d, eax
call fcn.140059e30
mov rcx, rdi
mov edx, eax
call fcn.140049190
jmp 0x140047ae2
mov rcx, qword [rdi + 0x368]
test rcx, rcx
jle 0x140047e30
mov rdx, qword [rdi + 0x788]
cmp rdx, rcx
jg 0x140047deb
mov rcx, qword [rdi + 0x10]
lea rdx, [rbp - 0x34]
call fcn.140059980
mov dword [rdi + 0x1c], eax
test byte [rdi + 0x1c8], 1
jne 0x140047e53
mov rax, qword [rdi + 0x10]
mov dword [rax + 0x400], ebx
test byte [rdi + 0x1c8], 2
jne 0x140047e66
mov rax, qword [rdi + 0x10]
mov dword [rax + 0x404], ebx
mov r12d, dword [rbp - 0x34]
test r12d, r12d
jne 0x140047e75
cmp dword [rdi + 0x1c], 0x38
jne 0x140047e9e
mov rcx, qword [rdi + 0x10]
lea rdx, [rbp - 0x30]
call fcn.14005a780
mov rbx, qword [rbp - 0x30]
test eax, eax
jne 0x140047e9e
test rbx, rbx
setne r15b
test r15d, r15d
je 0x140047e9e
mov dword [rdi + 0x1c], r13d
lea r12d, [rax + 1]
cmp dword [rdi + 0x1c], r13d
je 0x140047ee9
mov rcx, qword [rdi + 0x10]
mov rax, qword [rcx + 0x320]
test byte [rax + 0x78], 2
jne 0x140047ebf
mov dword [rcx + 0x2a8], 1
mov edx, dword [rdi + 0x1c]
lea rcx, [rdi + 0x10]
xor r8d, r8d
call fcn.14004f430
mov r12, qword [rbp + 0x28]
test rbx, rbx
je 0x140047ae2
mov rcx, rbx
call qword [case.0x140054204.2]
jmp 0x140047ae2
test r12d, r12d
je 0x140047ece
mov rdx, qword [rdi + 0x10]
mov rcx, rdi
mov rdx, qword [rdx + 0x410]
call fcn.14004ba10
mov rax, qword [rdi + 0x10]
mov rcx, qword [rax + 0x410]
mov rcx, qword [rcx]
test rcx, rcx
je 0x140047f21
mov rcx, qword [rcx]
mov edx, 1
call fcn.140049190
mov r12, qword [rbp + 0x28]
mov rcx, r12
call fcn.140049280
mov rax, qword [rdi + 0x1e0]
test rax, rax
jne 0x140047f9b
test r15d, r15d
jne 0x140047fb2
cmp qword [rdi + 0x1d8], r13
je 0x140047f85
test rbx, rbx
je 0x140047f55
mov rcx, rbx
call qword [case.0x140054204.2]
mov rbx, qword [rdi + 0x1d8]
mov r8d, 1
mov rcx, rdi
mov rdx, rbx
mov qword [rdi + 0x1d8], r13
call fcn.14005a300
mov dword [rdi + 0x1c], eax
test eax, eax
jne 0x140047f7f
xor ebx, ebx
jmp 0x140047f85
mov r13d, 1
cmp dword [rdi + 0x18], 0xf
je 0x140047f92
mov dword [rdi + 0x18], reloc.WS2_32.dll_ntohs
or r14d, 0xffffffff
jmp 0x140047ed2
test r15d, r15d
jne 0x140047fb2
mov rbx, rax
mov qword [rdi + 0x1e0], r13
mov r15d, 3
jmp 0x140047fb8
mov r15d, 2
lea rcx, [rdi + 0x10]
xor r8d, r8d
xor edx, edx
call fcn.14004f430
mov dword [rdi + 0x1c], eax
test eax, eax
jne 0x140047ed2
mov r8d, r15d
mov rdx, rbx
mov rcx, rdi
call fcn.14005a300
mov dword [rdi + 0x1c], eax
test eax, eax
jne 0x140047ed2
cmp dword [rdi + 0x18], 2
je 0x1400477e7
mov dword [rdi + 0x18], 2
or r14d, 0xffffffff
jmp 0x140047ae2
mov rdx, qword [rdi + 0x10]
or r14d, 0xffffffff
test rdx, rdx
je 0x14004804a
mov rdx, qword [rdx + 0x410]
mov rcx, rdi
call fcn.14004ba10
mov rcx, r12
call fcn.140049280
mov edx, dword [rdi + 0x1c]
lea rcx, [rdi + 0x10]
xor r8d, r8d
call fcn.14004f430
cmp dword [rdi + 0x1c], r13d
jne 0x140048040
mov dword [rdi + 0x1c], eax
cmp qword [rdi + 0x10], r13
je 0x14004804a
mov qword [rdi + 0x10], r13
cmp dword [rdi + 0x6bc], r13d
je 0x14004806f
cmp dword [rdi + 0x8b18], 6
je 0x14004806f
cmp dword [rdi + 0x18], r13d
je case.0x1400472f9.1
mov dword [rdi + 0x18], r13d
jmp case.0x1400472f9.1
cmp dword [rdi + 0x18], 0x10
je 0x140048152
mov rax, qword [rdi + 0x78]
mov dword [rdi + 0x18], reloc.WS2_32.dll_recv
dec dword [rax + 0x1c]
jmp case.0x1400472f9.1
xor edx, edx
mov rcx, rdi
mov qword [rdi + 0x10], r13
call fcn.140048fa0
jmp case.0x1400472f9.1
xor r8d, r8d
call fcn.14005aad0
mov rax, qword [rdi + 0x10]
mov rcx, qword [rax + 0x410]
mov rdx, qword [rcx]
test rdx, rdx
je 0x1400480d8
nop word [rax + rax]
cmp qword [rdx], rdi
je 0x1400480d0
mov rdx, qword [rdx + 0x10]
test rdx, rdx
jne 0x1400480c0
jmp 0x1400480d8
xor r8d, r8d
call fcn.14005aad0
mov rcx, r12
call fcn.140049280
test r13d, r13d
je 0x1400472be
mov rcx, qword [rdi + 0x10]
xor edx, edx
call fcn.14004b8e0
mov qword [rdi + 0x10], 0
jmp 0x1400472be
mov rcx, qword [rdi + 0x10]
test rcx, rcx
je 0x14004814c
call fcn.14005fd00
test eax, eax
je 0x14004814c
mov rax, qword [rdi + 0x10]
xor ecx, ecx
mov dword [rdi + 0x1c], 0x2a
mov dword [rax + 0x2a8], 1
cmp dword [rdi + 0x18], 0xf
setge cl
add ecx, 0xf
cmp dword [rdi + 0x18], ecx
je 0x140048148
mov dword [rdi + 0x18], ecx
cmp ecx, 0x10
jne 0x140048148
mov rax, qword [rdi + 0x78]
dec dword [rax + 0x1c]
or r14d, 0xffffffff
cmp dword [rdi + 0x18], 0x10
jne 0x14004818c
lea r8, [rdi + 0x20]
mov dword [r8], 1
mov qword [r8 + 8], rdi
mov eax, dword [rdi + 0x1c]
mov dword [r8 + 0x10], eax
mov rcx, qword [r12 + 0x20]
mov rdx, qword [rcx + 8]
call fcn.14005aa10
xor r14d, r14d
test eax, eax
cmove r14d, ebx
cmp dword [rdi + 0x18], 0x11
je 0x14004818c
mov dword [rdi + 0x18], send
mov eax, r14d
jmp 0x14004710f
xor eax, eax
jmp 0x14004710f
mov eax, 2
add rsp, 0x68
pop r14
pop r12
pop rdi
pop rbp
ret