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

Disassembly:
mov rax, rsp
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push rbp
push r14
push r15
lea rbp, [rax - 0x3a8]
sub rsp, 0x490
mov rax, qword [0x1401c76e0]
xor rax, rsp
mov qword [rbp + 0x380], rax
lea r14, [rcx + 8]
mov rsi, rcx
mov dl, 0xa
mov rax, qword [r14]
movsxd rcx, dword [rax + 4]
add rcx, r14
call fcn.1400070b0
mov rcx, r14
mov dl, al
call fcn.14001977c
mov rcx, r14
call fcn.14000372c
lea rdx, [rsp + 0x38]
lea rcx, [rsi + 0x10]
call fcn.140006f48
mov rax, qword [0x1401c9b10]
test rax, rax
je 0x140018952
mov r9, qword [rsi + 0xf0]
mov r8d, dword [rsi + 0x100]
mov rdx, qword [rsi + 0xf8]
lea rcx, [rsp + 0x38]
mov qword [rsp + 0x20], rcx
mov ecx, dword [rsi]
call rax
test al, al
jne 0x140018ae1
test byte [reloc.WS2_32.dll_accept], 2
je 0x140018974
cmp qword [rsp + 0x50], 0x10
lea rcx, [rsp + 0x38]
cmovae rcx, qword [rsp + 0x38]
call qword [sym.imp.KERNEL32.dll_OutputDebugStringA]
jmp 0x140018979
cmp dword [rsi], 2
jl 0x1400189b7
cmp qword [rsp + 0x50], 0x10
mov rbx, qword [rsp + 0x48]
lea rdi, [rsp + 0x38]
cmovae rdi, qword [rsp + 0x38]
call fcn.14009dfec
mov r8d, 1
lea r9, [rax + 0x60]
mov rdx, rbx
mov rcx, rdi
call fcn.14009e490
call fcn.14009dfec
lea rcx, [rax + 0x60]
call fcn.14009e1d4
test byte [reloc.WS2_32.dll_accept], 1
je 0x140018a67
xor edx, edx
xor ecx, ecx
call fcn.140019134
cmp dword [0x1401c9b2c], 0
jne 0x1400189e8
mov rcx, qword [0x1401c9b20]
or edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
jmp 0x1400189f4
mov rcx, qword [0x1401c9b18]
call sub.KERNEL32.dll_EnterCriticalSection
call fcn.140019368
test al, al
je 0x140018a43
mov rcx, qword [0x1401c9b00]
mov r9d, 2
xor r8d, r8d
xor edx, edx
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp qword [rsp + 0x50], 0x10
mov r8d, dword [rsp + 0x48]
mov rcx, qword [0x1401c9b00]
lea rdx, [rsp + 0x38]
lea r9, [rsp + 0x30]
cmovae rdx, qword [rsp + 0x38]
and qword [rsp + 0x20], 0
call qword [sym.imp.KERNEL32.dll_WriteFile]
cmp dword [0x1401c9b2c], 0
jne 0x140018a5b
mov rcx, qword [0x1401c9b20]
call qword [sym.imp.KERNEL32.dll_ReleaseMutex]
jmp 0x140018a67
mov rcx, qword [0x1401c9b18]
call sub.KERNEL32.dll_LeaveCriticalSection
cmp dword [rsi], 3
jne 0x140018ae1
mov r8d, 0x400
lea rdx, [rsp + 0x38]
cmp qword [rsp + 0x48], r8
cmovb r8, qword [rsp + 0x48]
cmp qword [rsp + 0x50], 0x10
cmovae rdx, qword [rsp + 0x38]
test r8, r8
je 0x140018a9c
lea rcx, [rbp - 0x80]
call fcn.14009bfb0
lea rcx, [rbp - 0x80]
call fcn.14002b1fc
cmp qword [0x1401c9b08], 0
je 0x140018adc
lea rdx, [rsp + 0x58]
lea rcx, [rsi + 0x10]
call fcn.140006f48
lea rcx, [rsp + 0x58]
call qword [0x1401c9b08]
cmp qword [rsp + 0x70], 0x10
jb 0x140018ae1
mov rcx, qword [rsp + 0x58]
call fcn.14009bc2c
jmp 0x140018ae1
call fcn.140018794
cmp qword [rsp + 0x50], 0x10
jb 0x140018af3
mov rcx, qword [rsp + 0x38]
call fcn.14009bc2c
mov ecx, dword [rsi + 0x104]
call qword [sym.imp.KERNEL32.dll_SetLastError]
lea rbx, [r14 + 0x88]
mov rcx, rbx
call fcn.140004560
lea rax, vtable.std::ios_base.0
mov rcx, rbx
mov qword [rbx], rax
call fcn.14009b9ac
mov rcx, qword [rbp + 0x380]
xor rcx, rsp
call fcn.14009c5b0
lea r11, [rsp + 0x490]
mov rbx, qword [r11 + 0x28]
mov rsi, qword [r11 + 0x30]
mov rdi, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop rbp
ret