Function at 0x14009e718
Capabilities:
Encode data using xor

Disassembly:
push rbp
mov rbp, rsp
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x58
mov rax, qword [0x14017dc10]
test rax, rax
je 0x14009ec0a
mov r13, qword [0x14017dc10]
xor eax, eax
test byte [r13 + 8], 1
mov qword [rsp + 0x40], r13
mov qword [rbp + 0x10], rax
je 0x14009eb8e
xor r12d, r12d
mov qword [rbp + 0x28], r12
cmp dword [r13 + 4], eax
jbe 0x14009eb8e
lea rsi, [r13 + 0x10]
lea r11, [0x140000000]
mov edi, 0x7fffffff
mov qword [rsp + 0x20], rsi
mov r10d, dword [rsi]
mov rax, qword [0x14010bb18]
mov r8d, dword [rsi - 4]
shr r8, 1
and r10d, 0xfffffff
mov rcx, r11
and r8d, 0xfffffff
add r10, r11
sub rcx, rax
mov qword [rbp + 0x18], rcx
jne 0x14009e837
xor r11d, r11d
test r8, r8
je 0x14009eb66
mov eax, dword [rbp + 0x14]
mov r9d, dword [rbp + 0x10]
movzx ecx, byte [r11 + r10]
inc r11
add ecx, 0x5434ea14
add r9d, ecx
add ecx, eax
mov eax, ecx
ror ecx, 4
imul eax, eax, 0x1ed8
rol eax, 4
xor eax, ecx
imul rax, rax, 0x5434ea14
mov qword [rbp + 0x18], rax
shr rax, 0x20
add eax, dword [rbp + 0x18]
imul rax, rax, 0x5434ea14
mov qword [rbp + 0x18], rax
mov ecx, dword [rbp + 0x18]
shr rax, 0x20
lea edx, [rcx - 0x7fffffff]
sar ecx, 0x1f
lea edx, [rdx + rax*2]
and ecx, edi
sub edx, ecx
mov eax, edx
sar eax, 0x1f
and eax, edi
add eax, edx
add r9d, eax
cmp r11, r8
jb 0x14009e7c3
mov dword [rbp + 0x14], eax
mov dword [rbp + 0x10], r9d
jmp 0x14009eb66
movsxd rdx, dword [0x14000003c]
lea rax, [r10 + r8]
mov qword [rsp + 0x38], rax
lea rax, [0x1400000b0]
add rdx, rax
mov eax, r10d
mov r14d, dword [rdx + 4]
sub eax, r11d
lea rsi, [rax + r8]
mov r8d, dword [rdx]
mov r9d, eax
mov rdi, rsi
and r9, 0xfffffffffffff000
mov ebx, eax
and rdi, 0xfffffffffffff000
add r8, r11
sub rbx, r9
sub rsi, rdi
mov qword [rsp + 0x28], rdi
add r14, r8
mov qword [rsp + 0x30], rsi
jmp 0x14009e89f
mov eax, dword [r8]
cmp rax, r9
jae 0x14009e8a4
mov eax, dword [r8 + 4]
add r8, rax
cmp r8, r14
jne 0x14009e890
xor r11d, r11d
cmp r8, r14
je 0x14009e8de
mov eax, dword [r8]
cmp rax, r9
jne 0x14009e8de
mov ecx, dword [r8 + 4]
sub rcx, 8
shr rcx, 1
je 0x14009e8de
lea rdx, [r8 + 8]
movzx eax, word [rdx]
and eax, 0xfff
cmp rax, rbx
jae 0x14009e8de
inc r11
add rdx, 2
cmp r11, rcx
jne 0x14009e8c5
mov ebx, dword [rbp + 0x14]
mov r15d, dword [rbp + 0x10]
mov r13, qword [rbp + 0x18]
cmp r8, r14
je 0x14009ead7
mov eax, dword [r8]
cmp rax, rdi
ja 0x14009ead7
mov ecx, dword [r8 + 4]
lea rax, [rcx - 8]
shr rax, 1
cmp r11, rax
jne 0x14009e92b
add r8, rcx
cmp r8, r14
je 0x14009ead7
mov eax, dword [r8]
cmp rax, rdi
ja 0x14009ead7
xor r11d, r11d
jmp 0x14009e8fe
mov eax, dword [r8]
cmp rax, rdi
jne 0x14009e947
movzx eax, word [r8 + r11*2 + 8]
and eax, 0xfff
cmp rax, rsi
jae 0x14009ead7
mov rax, r11
mov ecx, 0xf000
inc r11
test word [r8 + rax*2 + 8], cx
je 0x14009e8e9
movzx r9d, word [r8 + rax*2 + 8]
lea rax, [0x140000000]
xor r12d, r12d
mov edi, r9d
and edi, 0xfff
add edi, dword [r8]
add rdi, rax
mov rsi, rdi
sub rsi, r10
je 0x14009e9f5
movzx ecx, byte [r12 + r10]
inc r12
add ecx, 0x5434ea14
add r15d, ecx
add ecx, ebx
mov eax, ecx
ror ecx, 4
imul eax, eax, 0x1ed8
rol eax, 4
xor eax, ecx
imul rax, rax, 0x5434ea14
mov qword [rbp + 0x18], rax
shr rax, 0x20
add eax, dword [rbp + 0x18]
imul rax, rax, 0x5434ea14
mov qword [rbp + 0x18], rax
mov ecx, dword [rbp + 0x18]
shr rax, 0x20
lea edx, [rcx - 0x7fffffff]
sar ecx, 0x1f
lea edx, [rdx + rax*2]
mov eax, 0x7fffffff
and ecx, eax
sub edx, ecx
mov ebx, edx
sar ebx, 0x1f
and ebx, eax
add ebx, edx
add r15d, ebx
cmp r12, rsi
jb 0x14009e981
mov dword [rbp + 0x14], ebx
mov dword [rbp + 0x10], r15d
shr r9d, 0xc
cmp r9d, 3
je 0x14009ea0d
sub r9d, 0xa
neg r9d
sbb edx, edx
add edx, 3
jmp 0x14009ea12
mov edx, 2
mov rax, qword [rdi]
mov r9, r13
neg r9
mov qword [rbp + 0x18], rax
sub edx, 2
je 0x14009ea3d
dec edx
je 0x14009ea2e
or r9, 0xffffffffffffffff
jmp 0x14009ea47
add rax, r9
mov r9d, 8
mov qword [rbp + 0x18], rax
jmp 0x14009ea47
add dword [rbp + 0x18], r9d
mov r9d, 4
xor r10d, r10d
test r9, r9
je 0x14009eac4
movzx ecx, byte [rbp + r10 + 0x18]
inc r10
add ecx, 0x5434ea14
add r15d, ecx
add ecx, ebx
mov eax, ecx
ror ecx, 4
imul eax, eax, 0x1ed8
rol eax, 4
xor eax, ecx
imul rax, rax, 0x5434ea14
mov qword [rbp + 0x20], rax
shr rax, 0x20
add eax, dword [rbp + 0x20]
imul rax, rax, 0x5434ea14
mov qword [rbp + 0x20], rax
shr rax, 0x20
mov ecx, dword [rbp + 0x20]
lea edx, [rcx - 0x7fffffff]
sar ecx, 0x1f
lea edx, [rdx + rax*2]
mov eax, 0x7fffffff
and ecx, eax
sub edx, ecx
mov ebx, edx
sar ebx, 0x1f
and ebx, eax
add ebx, edx
add r15d, ebx
cmp r10, r9
jb 0x14009ea4f
mov dword [rbp + 0x14], ebx
mov dword [rbp + 0x10], r15d
mov rsi, qword [rsp + 0x30]
lea r10, [r9 + rdi]
mov rdi, qword [rsp + 0x28]
jmp 0x14009e8e9
mov r12, qword [rsp + 0x38]
mov r13, qword [rsp + 0x40]
xor r8d, r8d
mov edi, 0x7fffffff
sub r12, r10
je 0x14009eb5d
movzx ecx, byte [r8 + r10]
inc r8
add ecx, 0x5434ea14
add r15d, ecx
add ecx, ebx
mov eax, ecx
ror ecx, 4
imul eax, eax, 0x1ed8
rol eax, 4
xor eax, ecx
imul rax, rax, 0x5434ea14
mov qword [rbp + 0x18], rax
shr rax, 0x20
add eax, dword [rbp + 0x18]
imul rax, rax, 0x5434ea14
mov qword [rbp + 0x18], rax
mov ecx, dword [rbp + 0x18]
shr rax, 0x20
lea edx, [rcx - 0x7fffffff]
sar ecx, 0x1f
and ecx, edi
lea edx, [rdx + rax*2]
sub edx, ecx
mov ebx, edx
sar ebx, 0x1f
and ebx, edi
add ebx, edx
add r15d, ebx
cmp r8, r12
jb 0x14009eaee
mov dword [rbp + 0x14], ebx
mov dword [rbp + 0x10], r15d
mov r12, qword [rbp + 0x28]
mov rsi, qword [rsp + 0x20]
mov eax, dword [r13 + 4]
inc r12
add rsi, 8
mov qword [rbp + 0x28], r12
mov qword [rsp + 0x20], rsi
lea r11, [0x140000000]
cmp r12, rax
jb 0x14009e77e
mov rax, qword [rbp + 0x10]
cmp rax, qword [0x14017dc18]
je 0x14009ec0a
mov rax, qword [0x14017dbb0]
xor ebx, ebx
mov r8d, 0xffff
imul rax, rax, 0x343fd
shl rbx, 0x10
shr r8, 0x10
add rax, 0x269ec3
mov rcx, rax
shr rcx, 0x10
movzx edx, cx
or rbx, rdx
test r8, r8
jne 0x14009eba6
mov qword [0x14017dbb0], rax
call fcn.14009eca8
mov r11, rax
movabs rax, 0x8000800080008001
and r11, 0xfffffffffffff000
mul rbx
shr rdx, 0xf
imul rdx, rdx, 0xffff
sub rbx, rdx
mov rdx, r11
lea rcx, [rbx + 1]
call fcn.1400bd550
add rsp, 0x58
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret