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

Disassembly:
mov rax, rsp
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rax - 0xcb8]
sub rsp, 0xd80
mov qword [rbp - 0x50], 0xfffffffffffffffe
mov qword [rax + 0x20], rbx
mov rax, qword [0x14007edf8]
xor rax, rsp
mov qword [rbp + 0xc70], rax
mov rsi, r9
mov qword [rbp - 0x78], r9
mov r14, r8
mov r13, rdx
mov r15, rcx
mov qword [rbp + 0xb0], 7
xor ebx, ebx
mov qword [rbp + 0xa8], rbx
mov word [rbp + 0x98], bx
lea r8d, [rbx + 1]
lea rdx, [0x140088b60]
lea rcx, [rbp + 0x98]
call fcn.14000528c
nop
lea r8, [rbp + 0x98]
mov rdx, r13
lea rcx, [rbp + 0x180]
call fcn.1400293c0
mov r8, rax
lea rdx, str.StreamClient::WaitFBs:__s
lea ecx, [rbx + 3]
call fcn.14004b6f8
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0x180]
call fcn.140004d54
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0x98]
call fcn.140004d54
call qword [sym.imp.KERNEL32.dll_GetTickCount]
mov r12d, eax
mov dword [rsp + 0x58], eax
mov edx, 0x9c40
mov rcx, r15
call fcn.140064530
test al, al
jne 0x14006577b
lea r8, str.StreamClient::WaitFBs_failed_to_ensure_connection
lea edx, [rbx + 0x58]
lea rcx, [rbp + 0x1c0]
call fcn.14004bba0
lea rdx, [0x14008f3c8]
lea rcx, [rbp + 0x1c0]
call sub.VCRUNTIME140.dll__CxxThrowException
int3
mov rdi, qword [r13 + 8]
mov rbx, qword [r13]
jmp 0x1400657d0
mov qword [rbp + 0x50], 7
xor eax, eax
mov qword [rbp + 0x48], rax
mov word [rbp + 0x38], ax
or r9, 0xffffffffffffffff
xor r8d, r8d
mov rdx, rbx
lea rcx, [rbp + 0x38]
call fcn.140005154
nop
xor r8d, r8d
lea rdx, [rbp + 0x38]
mov rcx, r15
call fcn.140064f94
test al, al
jne 0x1400657d7
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0x38]
call fcn.140004d54
add rbx, 0x20
cmp rbx, rdi
jne 0x140065785
jmp 0x14006581e
lea r8, [rbp + 0x38]
lea rdx, str.StreamClient::WaitFBs:__s_complete
mov ecx, 3
call fcn.1400640d0
lea rax, [rbp + 0x38]
cmp r14, rax
je 0x140065809
or r9, 0xffffffffffffffff
xor r8d, r8d
lea rdx, [rbp + 0x38]
mov rcx, r14
call fcn.140005154
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0x38]
call fcn.140004d54
mov al, 1
jmp 0x14006604a
xorps xmm0, xmm0
movdqu xmmword [rsp + 0x60], xmm0
xor eax, eax
mov qword [rsp + 0x70], rax
mov rdi, qword [r13 + 8]
mov rbx, qword [r13]
cmp rbx, rdi
je 0x140065da3
xor r12d, r12d
or rsi, 0xffffffffffffffff
mov qword [rbp + 0x30], 7
mov qword [rbp + 0x28], r12
mov word [rbp + 0x18], r12w
mov r9, rsi
xor r8d, r8d
mov rdx, rbx
lea rcx, [rbp + 0x18]
call fcn.140005154
nop
mov qword [rbp + 0x10], 7
mov qword [rbp + 8], r12
mov word [rbp - 8], r12w
mov r9, rsi
xor r8d, r8d
lea rdx, [rbp + 0x18]
lea rcx, [rbp - 8]
call fcn.140005154
nop
mov rcx, qword [rbp + 8]
test rcx, rcx
sete al
test al, al
jne 0x1400658de
test rcx, rcx
je 0x1400658db
lea rax, [rbp - 8]
cmp qword [rbp + 0x10], 8
cmovae rax, qword [rbp - 8]
lea rsi, [rbp - 8]
cmovae rsi, qword [rbp - 8]
movzx ecx, word [rax + r12*2]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_towlower]
mov word [rsi + r12*2], ax
inc r12
cmp r12, qword [rbp + 8]
jb 0x1400658a2
xor r12d, r12d
or rsi, 0xffffffffffffffff
jmp 0x1400658de
xor r12d, r12d
lea r8, [0x140078630]
lea rdx, [r15 + 0x10]
lea rcx, [rbp + 0x1a0]
call fcn.140002764
nop
lea r8, [rbp - 8]
mov rdx, rax
lea rcx, [rbp + 0xf8]
call fcn.1400026f8
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0x1a0]
call fcn.140004d54
mov qword [rbp + 0xf0], 7
mov qword [rbp + 0xe8], r12
mov word [rbp + 0xd8], r12w
mov r8d, 1
lea rdx, [0x140078630]
lea rcx, [rbp + 0xd8]
call fcn.14000528c
nop
mov qword [rbp + 0xd0], 7
mov qword [rbp + 0xc8], r12
mov word [rbp + 0xb8], r12w
mov r8d, 1
lea rdx, [0x140077c54]
lea rcx, [rbp + 0xb8]
call fcn.14000528c
nop
xor r9d, r9d
lea r8, [rbp + 0xd8]
lea rdx, [rbp + 0xb8]
lea rcx, [rbp + 0xf8]
call fcn.1400045ac
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0xb8]
call fcn.140004d54
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0xd8]
call fcn.140004d54
mov qword [rbp + 0x70], 7
mov qword [rbp + 0x68], r12
mov word [rbp + 0x58], r12w
mov r9, rsi
xor r8d, r8d
lea rcx, [rbp + 0x58]
cmp byte [r15 + 0x30], r12b
je 0x1400659f6
lea rdx, [0x1400b8c28]
call fcn.140005154
mov r8d, r12d
jmp 0x140065a08
lea rdx, [0x1400b8c68]
call fcn.140005154
mov r8d, 1
mov byte [rsp + 0x28], r12b
mov dword [rsp + 0x20], r12d
xor r9d, r9d
lea rdx, [rbp + 0xf8]
lea rcx, [rbp + 0x78]
call fcn.1400088bc
nop
mov qword [rsp + 0x78], r12
mov dword [rbp - 0x80], 0x93
call fcn.14004bb88
test al, al
jne 0x140065aad
cmp byte [r15 + 0x30], r12b
je 0x140065aad
mov ecx, 0x48
call fcn.140039574
mov qword [rbp - 0x48], rax
test rax, rax
je 0x140065a65
lea rdx, [rbp + 0x78]
mov rcx, rax
call fcn.140007e7c
mov rsi, rax
jmp 0x140065a68
mov rsi, r12
mov dword [rbp - 0x20], 0x93
test rsi, rsi
je 0x140065a78
lock inc dword [rsi + 0x18]
mov qword [rbp - 0x40], r12
mov qword [rsp + 0x78], rsi
mov qword [rbp - 0x28], r12
lea rcx, [rsp + 0x78]
call fcn.140008508
mov rcx, rax
mov edx, 0x100000
call fcn.1400652a4
test al, al
je 0x140065c2c
or rsi, 0xffffffffffffffff
jmp 0x140065b7b
lea rax, vtable.RefCounted.0
mov qword [rbp + 0x120], rax
mov dword [rbp + 0x128], r12d
lea rax, vtable.OSecurityAttributes.0
mov qword [rbp + 0x120], rax
lea rdx, [rbp + 0x58]
lea rcx, [rbp + 0x148]
call fcn.14002b408
mov dword [rbp + 0x170], 0x8b
mov dword [rbp + 0x130], 0x18
mov dword [rbp + 0x140], r12d
mov rax, qword [rbp + 0x148]
mov qword [rbp + 0x138], rax
mov ecx, 0x48
call fcn.140039574
mov qword [rbp - 0x38], rax
test rax, rax
je 0x140065b39
mov byte [rsp + 0x20], r12b
mov r9b, 1
lea r8, [rbp + 0x120]
lea rdx, [rbp + 0x78]
mov rcx, rax
call fcn.14002b2c0
jmp 0x140065b3c
mov rax, r12
mov dword [rbp - 0x10], 0x93
test rax, rax
je 0x140065b4c
lock inc dword [rax + 0x18]
mov qword [rbp - 0x30], r12
mov qword [rsp + 0x78], rax
mov qword [rbp - 0x18], r12
mov rcx, qword [rbp + 0x148]
test rcx, rcx
je 0x140065b6a
call sub.Mso20Win32Client.dll_Ordinal_192_1
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0x150]
call fcn.140004d54
lea r9, [rbp + 0x78]
lea r8, [rbp + 0x18]
lea rdx, str.StreamClient::WaitFBs:__s_going_to_wait_on_FB_Event:__s
mov ecx, 3
call fcn.1400450d0
lea rdx, [rsp + 0x78]
lea rcx, [rsp + 0x60]
call fcn.140066260
nop
mov rcx, qword [rsp + 0x78]
test rcx, rcx
je 0x140065bcd
add rcx, 0x10
mov eax, esi
lock xadd dword [rcx + 8], eax
add eax, esi
jne 0x140065bcd
test rcx, rcx
je 0x140065bcd
mov rax, qword [rcx]
mov edx, 1
call qword [rax]
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0x78]
call fcn.140004d54
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0x58]
call fcn.140004d54
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0xf8]
call fcn.140004d54
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp - 8]
call fcn.140004d54
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0x18]
call fcn.140004d54
add rbx, 0x20
cmp rbx, rdi
je 0x140065d98
jmp 0x140065846
lea r9, [rbp + 0x78]
lea r8, [rbp + 0x18]
lea rdx, str.StreamClient::WaitFBs:__s_failed_to_open_FB_Event:__s
mov ecx, 1
call fcn.1400641e0
xor r8d, r8d
lea rdx, [rbp - 8]
mov rcx, r15
call fcn.140064f94
test al, al
je 0x140065d12
lea r8, [rbp + 0x18]
lea rdx, str.StreamClient::WaitFBs:__s_complete
mov ecx, 3
call fcn.1400640d0
lea rax, [rbp + 0x18]
cmp r14, rax
je 0x140065c8e
or r9, 0xffffffffffffffff
xor r8d, r8d
lea rdx, [rbp + 0x18]
mov rcx, r14
call fcn.140005154
nop
test rsi, rsi
je 0x140065cb4
lea rcx, [rsi + 0x10]
or eax, 0xffffffff
lock xadd dword [rcx + 8], eax
sub eax, 1
jne 0x140065cb4
test rcx, rcx
je 0x140065cb4
mov rax, qword [rcx]
mov edx, 1
call qword [rax]
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0x78]
call fcn.140004d54
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0x58]
call fcn.140004d54
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0xf8]
call fcn.140004d54
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp - 8]
call fcn.140004d54
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0x18]
call fcn.140004d54
nop
lea rcx, [rsp + 0x60]
call fcn.1400661d4
nop
jmp 0x140065817
test rsi, rsi
je 0x140065d38
lea rcx, [rsi + 0x10]
or eax, 0xffffffff
lock xadd dword [rcx + 8], eax
sub eax, 1
jne 0x140065d38
test rcx, rcx
je 0x140065d38
mov rax, qword [rcx]
mov edx, 1
call qword [rax]
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0x78]
call fcn.140004d54
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0x58]
call fcn.140004d54
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0xf8]
call fcn.140004d54
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp - 8]
call fcn.140004d54
nop
xor r8d, r8d
mov dl, 1
lea rcx, [rbp + 0x18]
call fcn.140004d54
nop
lea rcx, [rsp + 0x60]
call fcn.1400661d4
nop
xor al, al
jmp 0x14006604a
mov rsi, qword [rbp - 0x78]
mov r12d, dword [rsp + 0x58]
xor eax, eax
mov qword [rsp + 0x48], rax
mov qword [rsp + 0x50], rax
xor r8d, r8d
xor edx, edx
lea rcx, [rsp + 0x48]
call fcn.140009f50
mov qword [rsp + 0x48], rax
mov rbx, qword [rsp + 0x60]
cmp rbx, qword [rsp + 0x68]
je 0x140065e35
mov rdi, qword [rbx]
mov qword [rbp - 0x70], rdi
mov dword [rbp - 0x68], 0x93
test rdi, rdi
je 0x140065de8
lock inc dword [rdi + 0x18]
mov rdi, qword [rbp - 0x70]
lea rcx, [rbp - 0x70]
call fcn.14001bad0
mov rdx, rax
lea rcx, [rsp + 0x48]
call fcn.140019e98
nop
test rdi, rdi
je 0x140065e25
lea rcx, [rdi + 0x10]
or eax, 0xffffffff
lock xadd dword [rcx + 8], eax
cmp eax, 1
jne 0x140065e25
test rcx, rcx
je 0x140065e25
mov rax, qword [rcx]
mov edx, 1
call qword [rax]
nop
add rbx, 0x10
cmp rbx, qword [rsp + 0x68]
jne 0x140065dcd
mov rbx, qword [rsp + 0x60]
mov rsi, qword [rsi]
mov rdi, qword [rsi]
jmp 0x140065e68
lea rdx, [rdi + 0x10]
lea rcx, [rbp - 0x60]
call fcn.14003ca88
nop
lea rdx, [rbp - 0x60]
lea rcx, [rsp + 0x48]
call fcn.140019e98
nop
lea rax, vtable.OSynchronizationHandle.0
mov qword [rbp - 0x60], rax
mov rdi, qword [rdi]
cmp rdi, rsi
jne 0x140065e3d
mov esi, 1
or r8d, 0xffffffff
xor edx, edx
lea rcx, [rsp + 0x48]
call fcn.14003cab8
mov edx, eax
cmp rdx, qword [rsp + 0x50]
jae 0x140066015
mov rax, qword [rsp + 0x68]
sub rax, rbx
sar rax, 4
cmp rdx, rax
jae 0x140065fde
shl rdx, 5
add rdx, qword [r13]
cmp r14, rdx
je 0x140065ec0
or r9, 0xffffffffffffffff
xor r8d, r8d
mov rcx, r14
call fcn.140005154
mov r8, r14
lea rdx, str.StreamClient::WaitFBs:__s_completion_event_set
mov ecx, esi
call fcn.140064188
xor r8d, r8d
mov rdx, r14
mov rcx, r15
call fcn.140064f94
test al, al
jne 0x140065fb6
mov rdx, r14
mov rcx, r15
call fcn.1400646f8
mov edi, eax
mov dword [rsp + 0x40], eax
call qword [sym.imp.KERNEL32.dll_GetTickCount]
mov edx, eax
sub edx, r12d
lea ecx, [rdx - 1]
cmp eax, r12d
cmovb edx, ecx
mov dword [rsp + 0x5c], edx
cmp edi, 0x570
je 0x140065f62
lea eax, [rdi - 2]
cmp eax, esi
jbe 0x140065f62
cmp edi, 5
je 0x140065f62
lea eax, [rdi - 0x190]
cmp eax, 0xc7
jbe 0x140065f62
cmp edx, dword [rbp + 0xce0]
ja 0x140065f62
lea r9, [rsp + 0x40]
mov r8, r14
lea rdx, str.StreamClient::WaitFBs_Failed_for__s._Error:__d._Continuing_to_wait_due_to_timeout.
mov ecx, esi
call fcn.140064290
xor r8d, r8d
mov rdx, r14
mov rcx, r15
call fcn.140065418
jmp 0x140065e72
lea rax, [rbp + 0xce0]
mov qword [rsp + 0x38], rax
lea rax, [rsp + 0x5c]
mov qword [rsp + 0x30], rax
lea rax, [rsp + 0x40]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r14
lea r9, str.StreamClient::WaitFBs_Failed_for__s._Error:__d__Elapsed:__d__Timeout:__d
mov r8d, edi
mov edx, 0xae
lea rcx, [rbp + 0x550]
call fcn.140063ab8
lea rdx, [0x14008f3c8]
lea rcx, [rbp + 0x550]
call sub.VCRUNTIME140.dll__CxxThrowException
nop
lea rcx, [rsp + 0x48]
call fcn.14000a174
mov rdx, rsi
mov rcx, qword [rsp + 0x48]
call fcn.14001ad80
nop
lea rcx, [rsp + 0x60]
call fcn.1400661d4
nop
mov al, sil
jmp 0x14006604a
lea rdx, str.StreamClient::WaitFB:__s_Cancel_event_set
mov ecx, esi
call fcn.140064130
nop
lea rcx, [rsp + 0x48]
call fcn.14000a174
mov rdx, rsi
mov rcx, qword [rsp + 0x48]
call fcn.14001ad80
nop
lea rcx, [rsp + 0x60]
call fcn.1400661d4
nop
jmp 0x140065d91
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r8d, eax
lea r9, str.StreamClient::WaitFBs:_Wait_for_multiple_events_failed._Returned_value_is_greater_than_number_of_events
mov edx, 0xf
lea rcx, [rbp + 0x8e0]
call fcn.140063b98
lea rdx, [0x14008f3c8]
lea rcx, [rbp + 0x8e0]
call sub.VCRUNTIME140.dll__CxxThrowException
nop
mov rcx, qword [rbp + 0xc70]
xor rcx, rsp
call fcn.14003a6d0
mov rbx, qword [rsp + 0xdd8]
add rsp, 0xd80
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret