Function at 0x180020370
Capabilities:
Write file on windows

Disassembly:
mov dword [rsp + 0x20], r9d
mov qword [rsp + 0x18], r8
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0xe0
mov r12d, r9d
mov rsi, rdx
mov dword [rsp + 0x60], 0xc0000001
xor r14d, r14d
mov qword [rsp + 0x128], r14
mov ebx, r14d
mov r13d, r14d
mov r15, qword [rsp + 0x148]
test r15, r15
je 0x1800203bf
mov dword [r15], 0xc0000001
xor r9d, r9d
xor r8d, r8d
lea rdx, [rsp + 0x90]
call qword [sym.imp.ntdll.dll_RtlDosPathNameToNtPathName_U]
test al, al
jne 0x1800203f8
test r15, r15
je 0x1800203e3
mov dword [r15], 0xc00000ef
xor eax, eax
add rsp, 0xe0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
ret
mov eax, 3
mov ecx, 5
mov edi, dword [rsp + 0x140]
test edi, edi
cmove eax, ecx
mov edx, r14d
setne dl
add edx, 0x100002
mov dword [rsp + 0xa8], 0x30
mov qword [rsp + 0xb0], r14
mov dword [rsp + 0xc0], 0x40
lea rcx, [rsp + 0x90]
mov qword [rsp + 0xb8], rcx
xorps xmm0, xmm0
movdqu xmmword [rsp + 0xc8], xmm0
mov dword [rsp + 0x50], r14d
mov qword [rsp + 0x48], r14
mov dword [rsp + 0x40], 0x60
mov dword [rsp + 0x38], eax
mov dword [rsp + 0x30], r14d
mov dword [rsp + 0x28], 0x80
mov qword [rsp + 0x20], r14
lea r9, [rsp + 0x68]
lea r8, [rsp + 0xa8]
lea rcx, [rsp + 0x128]
call qword [sym.imp.ntdll.dll_NtCreateFile]
mov r14d, eax
mov dword [rsp + 0x60], eax
test eax, eax
js 0x18002062a
test edi, edi
je 0x1800204b8
mov qword [rsp + 0x78], 0xffffffffffffffff
lea r13, [rsp + 0x78]
mov eax, 0x80000000
mov rcx, qword [rsp + 0x130]
cmp rcx, rax
jae 0x180020522
mov qword [rsp + 0x40], 0
mov qword [rsp + 0x38], r13
mov dword [rsp + 0x30], ecx
mov qword [rsp + 0x28], rsi
lea rax, [rsp + 0x68]
mov qword [rsp + 0x20], rax
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov rcx, qword [rsp + 0x128]
call qword [sym.imp.ntdll.dll_NtWriteFile]
mov r14d, eax
mov dword [rsp + 0x60], eax
test eax, eax
js 0x18002062a
mov rbx, qword [rsp + 0x70]
mov qword [rsp + 0x80], rbx
jmp 0x18002062a
movabs rax, 0x200000005
mul rcx
mov r12, rcx
sub r12, rdx
shr r12, 1
add r12, rdx
shr r12, 0x1e
imul rax, r12, 0x7fffffff
sub rcx, rax
mov qword [rsp + 0x130], rcx
xor edi, edi
mov qword [rsp + 0x88], rdi
cmp rdi, r12
jae 0x1800205c7
mov qword [rsp + 0x40], 0
mov qword [rsp + 0x38], r13
mov dword [rsp + 0x30], 0x7fffffff
mov qword [rsp + 0x28], rsi
lea rax, [rsp + 0x68]
mov qword [rsp + 0x20], rax
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov rcx, qword [rsp + 0x128]
call qword [sym.imp.ntdll.dll_NtWriteFile]
mov r14d, eax
mov dword [rsp + 0x60], eax
test eax, eax
js 0x180020622
add rsi, 0x7fffffff
mov qword [rsp + 0xa0], rsi
add rbx, qword [rsp + 0x70]
mov qword [rsp + 0x80], rbx
inc rdi
jmp 0x180020553
mov rcx, qword [rsp + 0x130]
test ecx, ecx
je 0x180020622
mov qword [rsp + 0x40], 0
mov qword [rsp + 0x38], r13
mov dword [rsp + 0x30], ecx
mov qword [rsp + 0x28], rsi
lea rax, [rsp + 0x68]
mov qword [rsp + 0x20], rax
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov rcx, qword [rsp + 0x128]
call qword [sym.imp.ntdll.dll_NtWriteFile]
mov r14d, eax
mov dword [rsp + 0x60], eax
test eax, eax
js 0x180020622
add rbx, qword [rsp + 0x70]
mov qword [rsp + 0x80], rbx
mov r12d, dword [rsp + 0x138]
mov rcx, qword [rsp + 0x128]
test rcx, rcx
je 0x180020655
test r12d, r12d
je 0x18002064f
lea rdx, [rsp + 0x68]
call qword [sym.imp.ntdll.dll_NtFlushBuffersFile]
mov rcx, qword [rsp + 0x128]
call qword [sym.imp.ntdll.dll_NtClose]
lea rcx, [rsp + 0x90]
call qword [sym.imp.ntdll.dll_RtlFreeUnicodeString]
test r15, r15
je 0x18002066b
mov dword [r15], r14d
mov rax, rbx
jmp 0x1800203e5