Function at 0x180197970
Capabilities:
Encode data using xor

Disassembly:
mov r11, rsp
push rbx
push rdi
push r12
push r13
sub rsp, 0x98
mov rax, qword [0x18029e198]
xor rax, rsp
mov qword [rsp + 0x68], rax
mov rbx, qword [rsp + 0xe0]
lea rax, [rdx + 0xf]
mov r13, rdx
shr rax, 4
and r13d, 0xf
mov qword [rsp + 0x30], r8
mov qword [rsp + 0x38], rcx
mov r12, r9
mov qword [rsp + 0x20], r13
mov rdi, r8
test rax, rax
je 0x180197cb1
mov qword [r11 - 0x30], rsi
xor esi, esi
sub rax, 1
mov qword [r11 - 0x40], r15
mov qword [rsp + 0x40], rax
mov r15d, esi
je 0x180197b7d
mov qword [r11 - 0x28], rbp
mov r13, r8
mov qword [r11 - 0x38], r14
nop dword [rax + rax]
movzx r10d, byte [r12]
mov r9, r15
add r9, r9
lea eax, [r10 + r10]
mov rdi, qword [rbx + rax*8 + 0x38]
lea edx, [r10*2 + 6]
and rdi, qword [rbx + rax*8 + 0x28]
xor rdi, qword [rbx + rax*8 + 0x48]
xor rdi, qword [rbx + rax*8 + 0x18]
movups xmm1, xmmword [rcx + r9*8]
mov r8, qword [rbx + rdx*8]
mov r11d, eax
lea eax, [r10*2 + 4]
and r8, qword [rbx + rax*8]
movdqa xmm0, xmm1
lea eax, [r10*2 + 8]
psrldq xmm0, 8
xor r8, qword [rbx + rax*8]
movq rbp, xmm1
xor r8, qword [rbx + r11*8 + 0x10]
movq r14, xmm0
xor r8, rbp
xor rdi, r14
movups xmmword [rsp + 0x48], xmm1
mov qword [r13 + r9*8], r8
mov qword [r13 + r9*8 + 8], rdi
movzx ecx, byte [r12]
movzx eax, cl
shr al, 3
dec al
lea rdx, [rcx + 4]
and al, 1
add rcx, 3
shl al, 3
movzx esi, al
shl rdx, 4
shl rcx, 4
add rdx, rbx
add rcx, rbx
lea r8, [rsi + 4]
shl r8, 4
add r8, rbx
call fcn.180198b60
movzx ecx, byte [r12]
mov edi, esi
shl rdi, 4
add rdi, rbx
lea rdx, [rcx + 3]
add rcx, 2
shl rcx, 4
shl rdx, 4
lea r8, [rdi + 0x30]
add rcx, rbx
add rdx, rbx
call fcn.180198b60
movzx eax, byte [r12]
lea r8, [rdi + 0x20]
lea r9d, [rax + rax]
lea eax, [r9 + 4]
lea rdx, [rbx + rax*8]
lea eax, [r9 + 2]
lea rcx, [rbx + rax*8]
call fcn.180198b60
movzx r9d, byte [r12]
lea r8, [rdi + 0x10]
lea eax, [r9*2 + 2]
lea rdx, [rbx + rax*8]
lea eax, [r9 + r9]
lea rcx, [rbx + rax*8]
call fcn.180198b60
movzx edx, byte [r12]
mov r8, rdi
lea eax, [rdx + rdx]
xor rbp, qword [rbx + rax*8]
lea ecx, [rdx + rdx]
xor r14, qword [rbx + rcx*8 + 8]
lea eax, [rcx + 8]
mov qword [rsp + 0x60], r14
lea rcx, [rbx + rax*8]
mov qword [rsp + 0x58], rbp
lea rdx, [rsp + 0x58]
call fcn.180198b60
mov rcx, qword [rsp + 0x38]
inc r15
mov byte [r12], sil
cmp r15, qword [rsp + 0x40]
jb 0x1801979f0
mov r13, qword [rsp + 0x20]
xor esi, esi
mov rdi, qword [rsp + 0x30]
mov r14, qword [rsp + 0x80]
mov rbp, qword [rsp + 0x90]
add r15, r15
lea rax, [rcx + r15*8]
test r13, r13
je 0x180197c14
mov r8, r13
mov qword [rsp + 0x48], rsi
mov rdx, rax
mov qword [rsp + 0x50], rsi
lea rcx, [rsp + 0x48]
call fcn.18020b760
movzx r8d, byte [r12]
lea rcx, [rdi + r15*8]
lea r10d, [r8 + r8]
lea eax, [r8*2 + 4]
lea edx, [r8*2 + 6]
mov r9, qword [rbx + rdx*8]
lea rdx, [rsp + 0x20]
and r9, qword [rbx + rax*8]
lea eax, [r8*2 + 8]
xor r9, qword [rbx + rax*8]
mov r8, r13
mov rax, qword [rbx + r10*8 + 0x38]
and rax, qword [rbx + r10*8 + 0x28]
xor rax, qword [rbx + r10*8 + 0x48]
xor rax, qword [rbx + r10*8 + 0x18]
xor r9, qword [rbx + r10*8 + 0x10]
xor rax, qword [rsp + 0x50]
xor r9, qword [rsp + 0x48]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r9
call fcn.18020b760
jmp 0x180197c8a
movups xmm0, xmmword [rax]
movzx r8d, byte [r12]
movups xmmword [rsp + 0x48], xmm0
lea r9d, [r8 + r8]
lea eax, [r8*2 + 4]
lea edx, [r8*2 + 6]
mov r10, qword [rbx + rdx*8]
and r10, qword [rbx + rax*8]
lea eax, [r8*2 + 8]
xor r10, qword [rbx + rax*8]
movq rax, xmm0
xor r10, qword [rbx + r9*8 + 0x10]
mov rdx, qword [rbx + r9*8 + 0x38]
xor r10, rax
and rdx, qword [rbx + r9*8 + 0x28]
xor rdx, qword [rbx + r9*8 + 0x48]
xor rdx, qword [rbx + r9*8 + 0x18]
mov qword [rsp + 0x20], r10
psrldq xmm0, 8
movq rax, xmm0
xor rdx, rax
mov qword [rsp + 0x28], rdx
mov qword [rdi + r15*8], r10
mov qword [rdi + r15*8 + 8], rdx
lea r8, [rsp + 0x48]
mov rdx, rbx
mov rcx, r12
call fcn.1801986a0
mov r15, qword [rsp + 0x78]
mov qword [rsp + 0x48], rsi
mov qword [rsp + 0x50], rsi
mov rsi, qword [rsp + 0x88]
mov rcx, qword [rsp + 0x68]
xor rcx, rsp
call fcn.1801e67e0
add rsp, 0x98
pop r13
pop r12
pop rdi
pop rbx
ret