Function at 0x1400baca4
Capabilities:
Encode data using xor

Disassembly:
mov rax, rsp
push rbp
push r14
push r15
mov rbp, rsp
sub rsp, 0x50
mov qword [rbp - 0x20], 0xfffffffffffffffe
mov qword [rax + 8], rbx
mov qword [rax + 0x18], rdi
mov qword [rax + 0x20], r12
mov ebx, r9d
mov r15, r8
mov r14d, edx
mov rdi, rcx
mov ecx, edx
sub ecx, 0xe
je 0x1400bae87
sub ecx, 1
je 0x1400baddb
sub ecx, 1
je 0x1400bad36
cmp ecx, 1
je 0x1400bad0f
test r9d, r9d
je 0x1400baf32
mov edx, r14d
mov rcx, r15
call fcn.14008e548
add ebx, 0xffffffff
jne 0x1400bacfa
jmp 0x1400baf32
mov qword [rbp - 0x10], r15
mov byte [rbp - 8], 0
test r9d, r9d
je 0x1400bad31
mov byte [rbp - 8], 0
lea rdx, [rbp - 0x18]
mov rcx, r15
call fcn.140095ad0
add ebx, 0xffffffff
jne 0x1400bad1c
jmp 0x1400baf32
mov qword [rbp - 0x10], r15
mov byte [rbp - 8], 0
and dword [rbp + 0x28], 0
mov r9, rbx
mov rbx, qword [rdi + 8]
mov r14, qword [rdi]
mov rax, rbx
sub rax, r14
sar rax, 2
cmp r9, rax
jae 0x1400bad7b
lea rax, [r14 + r9*4]
cmp rax, r14
jne 0x1400bad6d
mov qword [rdi + 8], r14
mov rbx, r14
jmp 0x1400bad9f
cmp rax, rbx
je 0x1400bad9f
mov rbx, rax
mov qword [rdi + 8], rax
jmp 0x1400bad9f
jbe 0x1400bad9f
sub r9, rax
lea rax, [rbp + 0x28]
mov qword [rsp + 0x20], rax
mov r8, rbx
lea rdx, [rbp - 0x18]
mov rcx, rdi
call fcn.1400bd570
mov rbx, qword [rdi + 8]
mov r14, qword [rdi]
cmp r14, rbx
je 0x1400badd6
mov r12d, 1
mov rdi, r14
add r14, 4
mov byte [rbp - 8], 0
lea rdx, [rbp + 0x28]
mov rcx, r15
call fcn.140089188
mov eax, dword [rbp + 0x28]
mov ecx, eax
shr ecx, 1
and eax, r12d
neg eax
xor ecx, eax
mov dword [rdi], ecx
cmp r14, rbx
jne 0x1400badaa
jmp 0x1400baf32
mov qword [rbp - 0x10], r15
mov byte [rbp - 8], 0
and dword [rbp + 0x28], 0
mov r9, rbx
mov rbx, qword [rdi + 8]
mov r14, qword [rdi]
mov rax, rbx
sub rax, r14
sar rax, 2
cmp r9, rax
jae 0x1400bae20
lea rax, [r14 + r9*4]
cmp rax, r14
jne 0x1400bae12
mov qword [rdi + 8], r14
mov rbx, r14
jmp 0x1400bae44
cmp rax, rbx
je 0x1400bae44
mov rbx, rax
mov qword [rdi + 8], rax
jmp 0x1400bae44
jbe 0x1400bae44
sub r9, rax
lea rax, [rbp + 0x28]
mov qword [rsp + 0x20], rax
mov r8, rbx
lea rdx, [rbp - 0x18]
mov rcx, rdi
call fcn.1400bd570
mov rbx, qword [rdi + 8]
mov r14, qword [rdi]
cmp r14, rbx
je 0x1400bae82
mov r12d, 1
mov rdi, r14
add r14, 4
mov byte [rbp - 8], 0
lea rdx, [rbp + 0x28]
mov rcx, r15
call fcn.14009de40
movzx eax, word [rbp + 0x28]
movzx ecx, ax
shr cx, 1
and ax, r12w
neg ax
xor ax, cx
cwde
mov dword [rdi], eax
cmp r14, rbx
jne 0x1400bae4f
jmp 0x1400baf32
mov qword [rbp - 0x10], r15
mov byte [rbp - 8], 0
and dword [rbp + 0x28], 0
mov rdx, rbx
mov rax, qword [rdi + 8]
mov r9, qword [rdi]
mov rcx, rax
sub rcx, r9
sar rcx, 2
cmp rbx, rcx
jae 0x1400baecc
lea rcx, [r9 + rbx*4]
cmp rcx, r9
jne 0x1400baebe
mov qword [rdi + 8], r9
mov rax, r9
jmp 0x1400baef3
cmp rcx, rax
je 0x1400baef3
mov rax, rcx
mov qword [rdi + 8], rcx
jmp 0x1400baef3
jbe 0x1400baef3
sub rdx, rcx
lea rcx, [rbp + 0x28]
mov qword [rsp + 0x20], rcx
mov r9, rdx
mov r8, rax
lea rdx, [rbp - 0x18]
mov rcx, rdi
call fcn.1400bd570
mov rax, qword [rdi + 8]
mov r9, qword [rdi]
cmp r9, rax
je 0x1400baf32
mov r12d, 1
mov r11, r9
add r9, 4
mov byte [rbp - 8], 0
mov ecx, dword [r15 + 0x18]
mov r10d, dword [r15 + 0x20]
sub ecx, r10d
cmp ecx, r12d
jb 0x1400baf4d
mov rdx, qword [r15 + 0x10]
movsx r8d, byte [r10 + rdx]
lea ecx, [r10 + 1]
mov dword [r15 + 0x20], ecx
mov dword [r11], r8d
cmp r9, rax
jne 0x1400baefe
lea r11, [rsp + 0x50]
mov rbx, qword [r11 + 0x20]
mov rdi, qword [r11 + 0x30]
mov r12, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop rbp
ret
mov edx, r12d
mov rcx, r15
call fcn.14006dad0
int3