Function at 0x140023aae
Capabilities:
Encode data using xor

Disassembly:
push rbp
push r15
push r14
push r12
push rsi
push rdi
push rbx
sub rsp, 0x70
lea rbp, [rsp + 0x70]
mov qword [rbp - 8], 0xfffffffffffffffe
mov r14, r8
mov r15, rdx
mov byte [rbp - 0x14], 8
movzx eax, byte [r8 + 2]
add rax, 2
xor edx, edx
cmp word [r8], 0
cmovne rdx, rax
mov qword [rbp - 0x20], rdx
cmp dword [rcx + 0x968], 0
je 0x140023afa
mov byte [rbp - 0x13], 1
jmp 0x140023b20
mov byte [rbp - 0x13], 3
cmp byte [rcx + 0xa09], 0
lea rax, [0x1400246bf]
lea rsi, [0x1400242b7]
cmove rsi, rax
call rsi
test eax, eax
je 0x140023b17
mov dword [rbp - 0x18], eax
lea rdx, [rbp - 0x20]
mov rcx, r15
call fcn.14002410c
movzx r12d, word [r14]
test r12w, r12w
je 0x140023d14
test byte [rbp - 0x13], 2
je 0x140023b46
mov eax, dword [rbp - 0x18]
mov dword [rbp - 0xc], eax
mov rax, qword [r15 + 0x10]
mov rbx, qword [r15 + 0x20]
mov rcx, rbx
sub rcx, rax
cmp rcx, 1
ja 0x140023b95
mov rcx, qword [r15]
mov rdx, qword [r15 + 8]
mov rdi, rax
sub rdi, rdx
sub rbx, rdi
sub rbx, rcx
cmp rbx, 1
jbe 0x140023d23
cmp rax, rdx
je 0x140023b87
mov r8, rdi
call fcn.14005a330
mov rcx, qword [r15]
mov qword [r15 + 8], rcx
add rdi, rcx
mov qword [r15 + 0x10], rdi
mov rax, rdi
rol r12w, 8
lea rcx, [rax + 2]
mov qword [r15 + 0x18], rcx
mov word [rax], r12w
test byte [rbp - 0x13], 2
je 0x140023be5
mov ecx, dword [rbp - 0xc]
mov dword [rbp - 0x38], ecx
xor ecx, ecx
mov dl, byte [rbp + rcx - 0x38]
xor byte [rax + rcx], dl
inc rcx
cmp rcx, 2
jne 0x140023bb4
mov eax, dword [rbp - 0xc]
mov dword [rbp - 0x50], eax
mov eax, 2
mov ecx, eax
and ecx, 3
mov cl, byte [rbp + rcx - 0x50]
mov byte [rbp + rax - 0xe], cl
inc rax
cmp rax, 6
jne 0x140023bcf
mov rax, qword [r15 + 0x10]
mov rcx, qword [r15 + 0x18]
sub rcx, rax
cmp rcx, 2
mov ebx, 2
cmovb rbx, rcx
add rbx, rax
mov qword [r15 + 0x10], rbx
movzx esi, byte [r14 + 2]
test rsi, rsi
je 0x140023d14
mov rax, qword [r15 + 0x20]
mov rcx, rax
sub rcx, rbx
cmp rcx, rsi
jae 0x140023c53
mov rcx, qword [r15]
mov rdx, qword [r15 + 8]
mov r12, rbx
sub r12, rdx
sub rax, r12
sub rax, rcx
cmp rax, rsi
jb 0x140023d72
cmp rbx, rdx
je 0x140023c57
mov r8, r12
call fcn.14005a330
mov rcx, qword [r15]
mov al, byte [r14 + 2]
jmp 0x140023c59
mov eax, esi
jmp 0x140023c67
mov eax, esi
mov qword [r15 + 8], rcx
add r12, rcx
mov qword [r15 + 0x10], r12
mov rbx, r12
lea rcx, [rbx + rsi]
mov qword [r15 + 0x18], rcx
movzx ecx, sil
movzx eax, al
cmp cl, al
cmovb eax, ecx
test al, al
je 0x140023c8f
movzx r8d, al
lea rdx, [r14 + 3]
mov rcx, rbx
call fcn.14002f720
test byte [rbp - 0x13], 2
je 0x140023cf6
mov eax, dword [rbp - 0xc]
mov dword [rbp - 0x38], eax
cmp sil, 4
jb 0x140023cc6
xor eax, eax
mov cl, byte [rbp + rax - 0x38]
xor byte [rbx + rax], cl
inc rax
cmp rax, 4
jne 0x140023ca3
add rbx, 4
add rsi, 0xfffffffffffffffc
cmp rsi, 3
ja 0x140023ca1
test rsi, rsi
je 0x140023cf6
xor eax, eax
mov cl, byte [rbp + rax - 0x38]
xor byte [rbx + rax], cl
inc rax
cmp rsi, rax
jne 0x140023cc8
mov eax, dword [rbp - 0xc]
mov dword [rbp - 0x50], eax
xor eax, eax
lea ecx, [rsi + rax]
and ecx, 3
mov cl, byte [rbp + rcx - 0x50]
mov byte [rbp + rax - 0xc], cl
inc rax
cmp rax, 4
jne 0x140023cdf
movzx eax, byte [r14 + 2]
mov rcx, qword [r15 + 0x10]
mov rdx, qword [r15 + 0x18]
sub rdx, rcx
cmp rdx, rax
cmovae rdx, rax
add rdx, rcx
mov qword [r15 + 0x10], rdx
add rsp, 0x70
pop rbx
pop rdi
pop rsi
pop r12
pop r14
pop r15
pop rbp
ret
lea rax, str.flat_static_buffer.ipp
lea rsi, [rbp - 0x50]
mov qword [rsi], rax
lea rax, str.prepare
mov qword [rsi + 8], rax
movabs rax, 0x1f00000035
mov qword [rsi + 0x10], rax
lea rdx, str.buffer_overflow
lea rdi, [rbp - 0x38]
mov rcx, rdi
call fcn.140007406
lea rax, vtable.std::length_error.0
mov qword [rdi], rax
mov rcx, rdi
mov rdx, rsi
call fcn.14000d96d
lea rax, str.flat_static_buffer.ipp
lea rsi, [rbp - 0x50]
mov qword [rsi], rax
lea rax, str.prepare
mov qword [rsi + 8], rax
movabs rax, 0x1f00000035
mov qword [rsi + 0x10], rax
lea rdx, str.buffer_overflow
lea rdi, [rbp - 0x38]
mov rcx, rdi
call fcn.140007406
lea rax, vtable.std::length_error.0
mov qword [rdi], rax
mov rcx, rdi
mov rdx, rsi
call fcn.14000d96d
int3