Function at 0x1801078f0
Capabilities:
Encode data using xor

Disassembly:
push rbp
push rbx
push rdi
push r12
push r13
push r14
push r15
mov rbp, rsp
sub rsp, 0x40
mov rdi, r9
movzx ebx, r8b
mov r13d, edx
mov r12, rcx
mov r15, qword [rbp + 0x60]
sub r15, r9
call sub.MSVCP140.dll__Xtime_get_ticks
mov r10, rax
movabs rax, 0xd6bf94d5e57a42bd
imul r10
add rdx, r10
sar rdx, 0x17
mov rax, rdx
shr rax, 0x3f
add rdx, rax
mov eax, edx
shr eax, 0x18
mov byte [rbp + 0x48], al
mov eax, edx
shr eax, 0x10
mov byte [rbp + 0x49], al
mov eax, edx
shr eax, 8
mov byte [rbp + 0x4a], al
mov byte [rbp + 0x4b], dl
xorps xmm0, xmm0
movdqu xmmword [rbp - 0x20], xmm0
xor r14d, r14d
mov qword [rbp - 0x10], r14
mov byte [rbp + 0x50], r14b
movzx eax, byte [r12 + 0x20]
nop
neg al
sbb rdx, rdx
and edx, 4
mov eax, r14d
mov ecx, 2
cmp r15, 0x7e
cmovae eax, ecx
add rdx, rax
mov eax, 8
cmp r15, 0x10000
cmovae ecx, eax
add rdx, rcx
lea r8, [rbp + 0x50]
lea rcx, [rbp - 0x20]
call fcn.1801087b0
mov rcx, qword [rbp - 0x20]
mov byte [rcx], r13b
movzx eax, r13b
test bl, bl
je 0x1801079be
or al, 0x80
mov byte [rcx], al
cmp byte [rbp + 0x68], 0
je 0x1801079cd
test r13d, r13d
je 0x1801079cd
or al, 0x40
mov byte [rcx], al
cmp r15, 0x7e
jae 0x180107a22
movzx eax, byte [r12 + 0x20]
nop
mov rcx, qword [rbp - 0x20]
neg al
sbb al, al
and al, 0x80
or al, r15b
mov byte [rcx + 1], al
movzx eax, byte [r12 + 0x20]
nop
test al, al
je 0x180107b1a
mov r13, qword [rbp - 0x20]
movzx eax, byte [rbp + 0x48]
mov byte [r13 + 2], al
movzx eax, byte [rbp + 0x49]
mov byte [r13 + 3], al
movzx eax, byte [rbp + 0x4a]
mov byte [r13 + 4], al
movzx eax, byte [rbp + 0x4b]
mov byte [r13 + 5], al
jmp 0x180107b1e
mov r8, r15
shr r8, 8
movzx ecx, byte [r12 + 0x20]
nop
mov rdx, qword [rbp - 0x20]
cmp r15, 0x10000
jae 0x180107a91
mov eax, 0x7e
mov r9d, 0xfe
test cl, cl
cmovne eax, r9d
mov byte [rdx + 1], al
mov byte [rdx + 2], r8b
mov byte [rdx + 3], r15b
movzx eax, byte [r12 + 0x20]
nop
test al, al
je 0x180107b1a
mov r13, qword [rbp - 0x20]
movzx eax, byte [rbp + 0x48]
mov byte [r13 + 4], al
movzx eax, byte [rbp + 0x49]
mov byte [r13 + 5], al
movzx eax, byte [rbp + 0x4a]
mov byte [r13 + 6], al
movzx eax, byte [rbp + 0x4b]
mov byte [r13 + 7], al
jmp 0x180107b1e
mov eax, 0x7f
mov r9d, 0xff
test cl, cl
cmovne eax, r9d
mov byte [rdx + 1], al
mov rax, r15
shr rax, 0x38
mov byte [rdx + 2], al
mov rax, r15
shr rax, 0x30
mov byte [rdx + 3], al
mov rax, r15
shr rax, 0x28
mov byte [rdx + 4], al
mov rax, r15
shr rax, 0x20
mov byte [rdx + 5], al
mov rax, r15
shr rax, 0x18
mov byte [rdx + 6], al
mov rax, r15
shr rax, 0x10
mov byte [rdx + 7], al
mov byte [rdx + 8], r8b
mov byte [rdx + 9], r15b
movzx eax, byte [r12 + 0x20]
nop
test al, al
je 0x180107b1a
mov r13, qword [rbp - 0x20]
movzx eax, byte [rbp + 0x48]
mov byte [r13 + 0xa], al
movzx eax, byte [rbp + 0x49]
mov byte [r13 + 0xb], al
movzx eax, byte [rbp + 0x4a]
mov byte [r13 + 0xc], al
movzx eax, byte [rbp + 0x4b]
mov byte [r13 + 0xd], al
jmp 0x180107b1e
mov r13, qword [rbp - 0x20]
lea rbx, [r12 + 0x70]
mov qword [rbp + 0x40], rbx
mov rcx, rbx
call sub.MSVCP140.dll__Mtx_lock
test eax, eax
jne 0x180107c1f
mov eax, dword [rbx + 0x4c]
cmp eax, 0x7fffffff
je 0x180107c0f
mov r9, qword [rbp - 0x18]
sub r9, r13
mov rdx, qword [r12 + 0x60]
mov r8, r13
lea rcx, [r12 + 0x58]
call fcn.180107250
mov r9, r14
cmp rdi, qword [rbp + 0x60]
cmovne r9, r15
mov r8, rdi
mov rdx, qword [r12 + 0x60]
lea rcx, [r12 + 0x58]
call fcn.1801074a0
movzx eax, byte [r12 + 0x20]
nop
test al, al
je 0x180107bb0
test r15, r15
je 0x180107bb0
nop dword [rax + rax]
mov rax, r14
sub rax, r15
add rax, qword [r12 + 0x60]
mov rcx, r14
and ecx, 3
movzx ecx, byte [rbp + rcx + 0x48]
xor byte [rax], cl
inc r14
cmp r14, r15
jne 0x180107b90
mov rcx, qword [rbp + 0x40]
call sub.MSVCP140.dll__Mtx_unlock
mov rcx, r12
call fcn.18010c3b0
movzx ebx, al
mov rdx, qword [rbp - 0x10]
mov rcx, qword [rbp - 0x20]
sub rdx, rcx
mov rax, rcx
cmp rdx, 0x1000
jb 0x180107bf7
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x180107bf7
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1801fcb84
movzx eax, bl
add rsp, 0x40
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rbx
pop rbp
ret
dec eax
mov dword [rbx + 0x4c], eax
mov ecx, 6
call sub.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_
int3
mov ecx, 5
call sub.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_
int3