Function at 0x18001b9c0
Capabilities:
Create directory
Get common file path
Write file on windows

Disassembly:
mov rax, rsp
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x4a0
mov qword [rsp + 0x38], 0xfffffffffffffffe
mov qword [rax + 0x18], rbx
mov rax, qword [0x1800a7120]
xor rax, rsp
mov qword [rsp + 0x490], rax
mov r14, r9
mov qword [rsp + 0x30], r9
mov r15d, r8d
mov r13, rdx
mov qword [rsp + 0x20], rdx
mov rbx, rcx
mov rax, qword [rdx + 0x18]
add rax, rax
cmp rax, 0xbb8
jae 0x18001ba23
mov eax, 1
jmp 0x18001bc95
xor esi, esi
mov word [rsp + 0x70], si
xor edx, edx
mov r8d, 0x206
lea rcx, [rsp + 0x72]
call fcn.18005c190
lea rdx, [rsp + 0x70]
mov ecx, 0x104
call qword [sym.imp.KERNEL32.dll_GetTempPathW]
xor edx, edx
lea rcx, [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
lea r9, [rsp + 0x280]
xor r8d, r8d
lea rdx, str.QZTMP
lea rcx, [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_GetTempFileNameW]
lea r8, [0x180088730]
lea rdx, [rsp + 0x280]
lea rcx, [rsp + 0x28]
call fcn.18005f1e8
mov rdi, qword [rsp + 0x28]
cmp rdi, rsi
jne 0x18001baa0
xor eax, eax
jmp 0x18001bc95
mov rcx, qword [rbx + 0x80]
sub rcx, qword [rbx + 0x78]
movabs r8, 0x6666666666666667
mov rax, r8
imul rcx
sar rdx, 4
mov rax, rdx
shr rax, 0x3f
add rdx, rax
mov ebp, esi
mov r12d, esi
test edx, edx
jle 0x18001bbf1
movsxd r14, edx
xor r13d, r13d
mov rax, qword [rbx + 0xb0]
sub rax, qword [rbx + 0xa8]
sar rax, 2
cmp rsi, rax
jb 0x18001bb02
call fcn.18005dfbc
movabs r8, 0x6666666666666667
mov rax, qword [rbx + 0xa8]
test dword [rax + rsi*4], r15d
je 0x18001bbc9
movsxd rdi, r12d
mov rcx, qword [rbx + 0x80]
sub rcx, qword [rbx + 0x78]
mov rax, r8
imul rcx
sar rdx, 4
mov rax, rdx
shr rax, 0x3f
add rdx, rax
cmp rdi, rdx
jb 0x18001bb3f
call fcn.18005dfbc
lea rcx, [rdi + rdi*4]
mov rax, qword [rbx + 0x78]
lea rdx, [rax + rcx*8]
mov qword [rsp + 0x60], 7
mov qword [rsp + 0x58], r13
mov word [rsp + 0x48], r13w
or r9, 0xffffffffffffffff
xor r8d, r8d
lea rcx, [rsp + 0x40]
call fcn.1800017b8
nop
mov r8d, 2
lea rdx, [0x180088750]
lea rcx, [rsp + 0x40]
call fcn.180017e9c
lea rcx, [rsp + 0x48]
cmp qword [rsp + 0x60], 8
cmovae rcx, qword [rsp + 0x48]
mov rdi, qword [rsp + 0x58]
mov r9, qword [rsp + 0x28]
mov r8, rdi
mov edx, 2
call fcn.18005f008
cmp rax, rdi
jne 0x18001bbb7
inc ebp
cmp qword [rsp + 0x60], 8
jb 0x18001bbc9
mov rcx, qword [rsp + 0x48]
call fcn.18005bda0
inc r12d
inc rsi
cmp rsi, r14
movabs r8, 0x6666666666666667
jl 0x18001badc
mov rdi, qword [rsp + 0x28]
mov r13, qword [rsp + 0x20]
mov r14, qword [rsp + 0x30]
mov rcx, rdi
call fcn.18005edf4
xor esi, esi
cmp eax, esi
je 0x18001bc06
xor eax, eax
jmp 0x18001bc95
cmp ebp, esi
jne 0x18001bc11
xor eax, eax
jmp 0x18001bc95
lea rcx, case.0x18003191c.6
mov rax, qword [case.0x18003191c.6]
call qword [rax + Ordinal_26]
add rax, 0x18
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x280]
mov r8, r14
lea rdx, str.___s_s_
lea rcx, [rsp + 0x20]
call fcn.180010c18
mov rcx, r13
call fcn.180020944
xor eax, eax
or rbp, 0xffffffffffffffff
mov rcx, rbp
mov rbx, qword [rsp + 0x20]
mov rdi, rbx
repne scasw ax, word [rdi]
not rcx
lea r8, [rcx - 1]
mov rdx, rbx
mov rcx, r13
call fcn.180017e9c
nop
lea rdx, [rbx - 0x18]
mov eax, ebp
lock xadd dword [rdx + 0x10], eax
add eax, ebp
cmp eax, esi
jg 0x18001bc90
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + ioctlsocket]
mov eax, 1
mov rcx, qword [rsp + 0x490]
xor rcx, rsp
call fcn.18005c4c0
mov rbx, qword [rsp + 0x4f0]
add rsp, 0x4a0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret