Function at 0x1800018e0
Capabilities:
Create thread
Resume thread

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rbp
push rdi
push r12
lea rbp, [rsp - 0x6c00]
mov eax, 0x6d00
call fcn.180022e80
sub rsp, rax
call fcn.180018710
lea rcx, [rsp + 0x50]
call fcn.18001ce14
mov rcx, qword [0x1800290b8]
xor r12d, r12d
mov edi, 0x20
test rcx, rcx
jne 0x180001971
mov ecx, 0x710
call qword [sym.imp.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__]
mov rcx, rax
test rax, rax
je 0x180001967
add rax, 8
mov edx, edi
nop
mov dword [rax - 8], 0xffffffff
mov dword [rax - 4], r12d
mov qword [rax], r12
add rax, 0x38
dec rdx
jne 0x180001940
mov qword [rcx + 0x700], r12
mov qword [rcx + 0x708], r12
jmp 0x18000196a
mov rcx, r12
mov qword [0x1800290b8], rcx
call fcn.180016060
mov rbx, qword [0x1800290c0]
test rbx, rbx
jne 0x1800019cc
mov ecx, 0x2038
call qword [sym.imp.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__]
mov rbx, rax
test rax, rax
je 0x1800019c2
lea rcx, [rax + 0x2010]
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
xor edx, edx
mov r8d, 0x2000
mov rcx, rbx
call fcn.18001ca58
mov qword [rbx + 0x2000], r12
mov qword [rbx + 0x2008], r12
jmp 0x1800019c5
mov rbx, r12
mov qword [0x1800290c0], rbx
mov rcx, rbx
call fcn.180008ee0
lea rcx, [rsp + 0x30]
mov qword [rsp + 0x38], r12
mov qword [rsp + 0x48], r12
mov qword [rsp + 0x40], r12
mov dword [rsp + 0x30], r12d
call fcn.1800152e0
lea rcx, [rbp + 0x248]
call fcn.180001d90
lea rcx, [rbp + 0x128]
xor edx, edx
mov r8d, 0x120
mov qword [rbp + 0xf0], r12
mov qword [rbp + 0xf8], r12
call fcn.18001ca58
mov rdx, qword [rsp + 0x48]
lea rcx, [rbp + 0x100]
mov r8d, SQLNumResultCols
call qword [sym.imp.KERNEL32.dll_lstrcpynW]
xor r9d, r9d
xor r8d, r8d
lea edx, [r9 + 1]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateEventW]
mov rbx, qword [0x1800290b0]
mov qword [rbp + 0xf8], rax
test rbx, rbx
jne 0x180001a92
lea ecx, [rbx + 0x40]
call qword [sym.imp.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__]
mov rbx, rax
test rax, rax
je 0x180001a88
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
lea r11, [rbx + 0x28]
mov qword [r11], r11
mov qword [r11 + 8], r11
mov dword [r11 + 0x10], r12d
jmp 0x180001a8b
mov rbx, r12
mov qword [0x1800290b0], rbx
mov ecx, 0x38
call qword [sym.imp.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__]
mov rsi, rax
test rax, rax
je 0x180001b59
lea rax, [rbp + 0x6c20]
lea r8, [0x18001c790]
mov r9, rsi
mov qword [rsp + 0x28], rax
xor edx, edx
xor ecx, ecx
mov dword [rsp + 0x20], 4
call qword [sym.imp.KERNEL32.dll_CreateThread]
mov qword [rbp + 0xf0], rax
test rax, rax
jne 0x180001aee
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, rsi
call qword [sym.imp.msvcrt.dll_void___cdecl_operator_delete_void____ptr64_]
jmp 0x180001b59
mov qword [rsi + 0x18], rbx
mov eax, dword [rbp + 0x6c20]
mov rcx, rbx
mov dword [rsi + 0x10], eax
lea rax, str.OlProc
mov qword [rsi + 0x30], rax
lea rax, [0x1800057c0]
mov qword [rsi + 0x20], rax
lea rax, [rbp + 0xf0]
mov qword [rsi + 0x28], rax
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
lea r11, [rbx + 0x28]
mov qword [rsi], r11
mov rax, qword [r11 + 8]
mov rcx, rbx
mov qword [rsi + 8], rax
mov rax, qword [r11 + 8]
mov qword [rax], rsi
mov qword [r11 + 8], rsi
inc dword [r11 + 0x10]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov rcx, qword [rbp + 0xf0]
call qword [sym.imp.KERNEL32.dll_ResumeThread]
mov rbx, qword [0x180029098]
test rbx, rbx
jne 0x180001ba7
lea ecx, [rbx + 0x30]
call qword [sym.imp.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__]
mov rbx, rax
test rax, rax
je 0x180001b9d
xor r9d, r9d
xor r8d, r8d
xor ecx, ecx
lea edx, [r9 + 1]
mov qword [rax + 0x18], r12
mov qword [rax + 0x28], r12
mov qword [rax + 0x20], r12
mov dword [rax + 0x10], r12d
call qword [sym.imp.KERNEL32.dll_CreateEventW]
mov qword [rbx], rax
jmp 0x180001ba0
mov rbx, r12
mov qword [0x180029098], rbx
mov rcx, qword [rbx]
or edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rbx, qword [0x1800290b8]
test rbx, rbx
jne 0x180001c18
mov ecx, 0x710
call qword [sym.imp.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__]
mov rbx, rax
test rax, rax
je 0x180001c0e
lea rcx, [rax + 8]
nop word [rax + rax]
mov dword [rcx - 8], 0xffffffff
mov dword [rcx - 4], r12d
mov qword [rcx], r12
add rcx, 0x38
dec rdi
jne 0x180001be0
mov qword [rax + 0x700], r12
mov qword [rax + 0x708], r12
mov qword [0x1800290b8], rax
jmp 0x180001c18
mov rbx, r12
mov qword [0x1800290b8], rbx
mov rcx, qword [rbx + 0x708]
call qword [sym.imp.KERNEL32.dll_SetEvent]
mov rcx, qword [rbx + 0x700]
or edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, qword [rbx + 0x700]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbx + 0x708]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov qword [rbx + 0x700], r12
mov qword [rbx + 0x708], r12
cmp qword [rbp + 0xf0], r12
je 0x180001c72
lea rcx, [rbp + 0xf0]
call fcn.1800056c0
mov rbx, qword [0x1800290c0]
test rbx, rbx
jne 0x180001cc8
mov ecx, 0x2038
call qword [sym.imp.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__]
mov rbx, rax
test rax, rax
je 0x180001cbe
lea rcx, [rax + 0x2010]
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
xor edx, edx
mov r8d, 0x2000
mov rcx, rbx
call fcn.18001ca58
mov qword [rbx + 0x2000], r12
mov qword [rbx + 0x2008], r12
jmp 0x180001cc1
mov rbx, r12
mov qword [0x1800290c0], rbx
mov rcx, qword [rbx + 0x2008]
call qword [sym.imp.KERNEL32.dll_SetEvent]
mov rcx, qword [rbx + 0x2000]
or edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, qword [rbx + 0x2008]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbx + 0x2000]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov qword [rbx + 0x2000], r12
mov qword [rbx + 0x2008], r12
mov rcx, qword [rbp + 0x6be8]
test rcx, rcx
je 0x180001d34
call qword [sym.imp.msvcrt.dll_void___cdecl_operator_delete_void____ptr64_]
mov qword [rbp + 0x6be8], r12
mov qword [rbp + 0x6bf8], r12
mov qword [rbp + 0x6bf0], r12
mov rcx, qword [rbp + 0x6bc8]
test rcx, rcx
je 0x180001d5b
call qword [sym.imp.msvcrt.dll_void___cdecl_operator_delete_void____ptr64_]
mov qword [rbp + 0x6bc8], r12
mov qword [rbp + 0x6bd8], r12
mov qword [rbp + 0x6bd0], r12
mov rcx, qword [rsp + 0x38]
test rcx, rcx
je 0x180001d6b
call qword [sym.imp.msvcrt.dll_void___cdecl_operator_delete_void____ptr64_]
lea r11, [rsp + 0x6d00]
xor eax, eax
mov rbx, qword [r11 + 0x28]
mov rsi, qword [r11 + 0x30]
mov rsp, r11
pop r12
pop rdi
pop rbp
ret