Function at 0x140008670
Capabilities:
Print debug messages
Write file on windows

Disassembly:
test rdx, rdx
je 0x140008bf1
push rbp
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x1f]
sub rsp, 0xd8
mov qword [rbp - 0x59], 0xfffffffffffffffe
mov rax, qword [0x14005d098]
xor rax, rsp
mov qword [rbp + 0xf], rax
mov qword [rbp - 0x79], r9
mov rdi, r8
mov qword [rbp - 0x69], r8
mov r13, rdx
mov r14, rcx
xor r12d, r12d
mov rcx, qword [rdx + 0x18]
lea rbx, [0x14004e52c]
test rcx, rcx
je 0x1400086d6
add rcx, 8
call fcn.140003a60
jmp 0x1400086d9
mov rax, rbx
mov rcx, rax
call fcn.14001aa50
test rax, rax
jne 0x1400086f3
cmp qword [r14 + 0x360], r12
je 0x140008bd2
mov rcx, qword [r13 + 0x18]
test rcx, rcx
je 0x140008701
mov eax, dword [rcx + 0x28]
jmp 0x140008704
mov eax, r12d
movzx esi, word [r13 + 0x10]
shl esi, 0xa
test esi, esi
je 0x140008718
cmp eax, esi
jae 0x140008bd2
test rcx, rcx
je 0x140008728
add rcx, 8
call fcn.140003a60
jmp 0x14000872b
mov rax, rbx
mov rdx, rax
call fcn.14000848c
mov r15, rax
mov rax, qword [r14 + 0x90]
test rax, rax
je 0x140008751
mov rax, qword [rax + 0x18]
test rax, rax
je 0x140008751
lea rbx, [rax + 0x30]
jmp 0x14000875c
mov rbx, qword [r14 + 0xe0]
add rbx, 0x28
mov qword [rsp + 0x38], rbx
test rdi, rdi
jne 0x14000876c
mov qword [rbp - 0x71], r12
jmp 0x14000877b
mov rcx, rdi
call fcn.14001aa50
mov r12, rax
mov qword [rbp - 0x71], rax
mov rcx, rbx
call fcn.140003600
xor ecx, ecx
cmp qword [rax], rcx
mov edi, ecx
jbe 0x14000878e
mov edi, dword [rax]
mov dword [rsp + 0x34], edi
mov rax, qword [rbp - 0x79]
test rax, rax
jne 0x1400087a3
mov ebx, ecx
mov qword [rbp - 0x61], rbx
jmp 0x1400087b2
mov rcx, rax
call fcn.14001aa50
mov rbx, rax
mov qword [rbp - 0x61], rax
lea ecx, [rbx + rdi]
lea eax, [r12 + 3]
add eax, ecx
mov dword [rsp + 0x30], eax
mov r12, qword [r14 + 0x360]
test r12, r12
je 0x1400087ee
mov rbx, qword [r12]
mov rcx, qword [rsp + 0x38]
call fcn.140003a60
mov r8, rax
mov r9, qword [rbp - 0x79]
mov rdx, qword [rbp - 0x69]
mov rcx, r12
call qword [rbx]
mov rbx, qword [rbp - 0x61]
or r12, 0xffffffffffffffff
cmp r15, r12
je 0x1400089d2
lea r9d, [r12 + 3]
xor r8d, r8d
xor edx, edx
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov edi, eax
xor ebx, ebx
test esi, esi
je 0x14000881e
cmp eax, esi
jae 0x1400089c4
mov rdx, r15
mov rcx, r14
call fcn.14000852c
add edi, eax
mov rax, qword [rbp - 0x71]
test eax, eax
je 0x140008856
lea r8d, [rax + rax]
mov qword [rsp + 0x20], rbx
lea r9, [rsp + 0x30]
mov rdx, qword [rbp - 0x69]
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x140008856
add edi, dword [rsp + 0x30]
mov ebx, dword [rsp + 0x34]
test ebx, ebx
je 0x140008890
add ebx, ebx
mov rcx, qword [rsp + 0x38]
call fcn.140003a60
mov rdx, rax
and qword [rsp + 0x20], 0
lea r9, [rsp + 0x30]
mov r8d, ebx
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_WriteFile]
xor ebx, ebx
test eax, eax
je 0x140008892
add edi, dword [rsp + 0x30]
jmp 0x140008892
xor ebx, ebx
mov rax, qword [rbp - 0x61]
test eax, eax
je 0x1400088e5
lea r8d, [rax + rax]
mov qword [rsp + 0x20], rbx
lea r9, [rsp + 0x30]
mov rdx, qword [rbp - 0x79]
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1400088bd
add edi, dword [rsp + 0x30]
mov qword [rsp + 0x20], rbx
lea r9, [rsp + 0x30]
mov r8d, 4
lea rdx, [0x14004f428]
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1400088e5
add edi, dword [rsp + 0x30]
test esi, esi
je 0x1400089b8
cmp edi, esi
jb 0x1400089b8
xor r8d, r8d
mov edx, 0x80
lea rcx, [rbp - 0x51]
call fcn.14000a640
nop
lea rbx, [r14 + 0x110]
lea rcx, [r14 + 8]
call fcn.140003a60
mov r9, rax
lea r8, str._FILE_SIZE_LIMIT_REACHED__LOGGING_DISABLED_FOR__s_MODULE_
mov edx, 0x104
mov rcx, rbx
call fcn.1400048b4
xor esi, esi
cmp word [rbx], si
jne 0x14000893a
mov r12d, esi
jmp 0x140008944
inc r12
cmp word [rbx + r12*2], si
jne 0x14000893a
mov r8, r12
mov rdx, rbx
lea rcx, [rbp - 0x51]
call fcn.140003400
lea rcx, [rbp - 0x51]
call fcn.140003600
mov rcx, qword [rax]
lea ebx, [rcx + rcx]
mov dword [rsp + 0x30], ebx
lea rcx, [rbp - 0x51]
call fcn.140003a60
mov rdx, rax
mov qword [rsp + 0x20], rsi
lea r9, [rsp + 0x30]
mov r8d, ebx
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_WriteFile]
xor ebx, ebx
test eax, eax
je 0x140008992
add edi, dword [rsp + 0x30]
mov eax, dword [r13 + 0x10]
mov ecx, 0x30000
and eax, ecx
cmp eax, ecx
jne 0x1400089af
mov rax, qword [r13 + 0x18]
test rax, rax
je 0x1400089af
mov byte [rax], 1
mov edi, ebx
lea rcx, [rbp - 0x51]
call fcn.140003bf0
mov rax, qword [r13 + 0x18]
test rax, rax
je 0x1400089c4
mov dword [rax + 0x28], edi
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x140008bd2
lea rcx, [rbp - 0x51]
call fcn.140002fb0
nop
mov esi, dword [rsp + 0x30]
lea rcx, [rbp - 0x51]
call fcn.140003600
mov r15, qword [rax]
cmp r15, rsi
ja 0x140008a3f
lea rcx, [rbp - 0x51]
call fcn.140003b50
cmp qword [rax], rsi
je 0x140008a3f
mov r8b, 1
mov edx, esi
lea rcx, [rbp - 0x51]
call fcn.140003880
xor esi, esi
test al, al
je 0x140008a41
lea rcx, [rbp - 0x51]
call fcn.140002fe0
mov word [rsp + 0x30], si
mov qword [rax + 0x10], r15
cmp qword [rax + 0x18], 8
jb 0x140008a2f
mov rax, qword [rax]
lea rcx, [rax + r15*2]
lea rdx, [rsp + 0x30]
call fcn.140003b60
jmp 0x140008a41
xor esi, esi
cmp qword [r14 + 0x358], rsi
jne 0x140008a74
lea rdx, str.____Queued_Lines_Start_____r_n
lea rcx, [rbp - 0x11]
call fcn.140002f60
nop
lea rcx, [r14 + 0x338]
mov rdx, rax
call fcn.14000a284
nop
lea rcx, [rbp - 0x11]
call fcn.140003bf0
mov rax, qword [rbp - 0x71]
test eax, eax
je 0x140008a89
mov rdx, qword [rbp - 0x69]
lea rcx, [rbp - 0x51]
call fcn.1400052f8
test edi, edi
je 0x140008aa1
mov r9, r12
xor r8d, r8d
mov rdx, qword [rsp + 0x38]
lea rcx, [rbp - 0x51]
call fcn.14000553c
test ebx, ebx
je 0x140008ab2
mov rdx, qword [rbp - 0x79]
lea rcx, [rbp - 0x51]
call fcn.1400052f8
lea rdx, [0x14004f428]
lea rcx, [rbp - 0x51]
call fcn.1400052f8
lea rbx, [r14 + 0x338]
mov rax, qword [rbx + 0x20]
inc rax
cmp qword [rbx + 0x10], rax
ja 0x140008ade
mov rcx, rbx
call fcn.14000aeb4
mov rax, qword [rbx + 0x10]
dec rax
and qword [rbx + 0x18], rax
mov rdx, qword [rbx + 0x18]
add rdx, qword [rbx + 0x20]
mov rdi, qword [rbx + 0x10]
dec rdi
and rdi, rdx
mov rax, qword [rbx + 8]
cmp qword [rax + rdi*8], rsi
jne 0x140008b1d
mov r8b, 1
mov edx, 0x20
lea ecx, [rdx - 0x1f]
call fcn.140003620
mov rcx, qword [rbx + 8]
mov qword [rcx + rdi*8], rax
mov rax, qword [rbx + 8]
mov rcx, qword [rax + rdi*8]
mov qword [rbp - 0x69], rcx
mov qword [rbp - 0x71], rcx
test rcx, rcx
je 0x140008b3c
lea rdx, [rbp - 0x51]
call fcn.140003240
nop
inc qword [rbx + 0x20]
lea rcx, [rbp - 0x31]
call fcn.140002fb0
nop
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
lea r9, [rbp - 0x31]
xor r8d, r8d
mov rcx, r14
call fcn.1400099e0
lea rcx, str.Unable_to_open_log_file:_r_n_
call qword [sym.imp.KERNEL32.dll_OutputDebugStringW]
mov rcx, qword [r13 + 0x18]
test rcx, rcx
je 0x140008b82
add rcx, 8
call fcn.140003a60
jmp 0x140008b89
lea rax, [0x14004e52c]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_OutputDebugStringW]
lea rcx, [0x14004f4a8]
call qword [sym.imp.KERNEL32.dll_OutputDebugStringW]
lea rcx, [rbp - 0x31]
call fcn.140003a60
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_OutputDebugStringW]
lea rcx, [0x14004f428]
call qword [sym.imp.KERNEL32.dll_OutputDebugStringW]
nop
lea rcx, [rbp - 0x31]
call fcn.140003bf0
nop
lea rcx, [rbp - 0x51]
call fcn.140003bf0
mov rcx, qword [rbp + 0xf]
xor rcx, rsp
call fcn.140013b90
add rsp, 0xd8
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret