Function at 0x14001ca80
Capabilities:
Encode data using xor

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
push rbp
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x58]
sub rsp, 0x158
xor esi, esi
mov rbx, r8
mov r14, rcx
lea rcx, [rbp - 0x1c]
lea r8d, [rsi + 0x60]
xor edx, edx
mov rdi, r9
mov byte [rbp + 0xb0], 0
mov dword [rbp - 0x20], esi
call fcn.14010ec60
mov r10d, dword [rbx]
mov r11d, dword [rbx + 4]
mov ebx, dword [rdi + 4]
mov eax, dword [rdi]
or r12d, 0xffffffff
sub ebx, r11d
sub eax, r10d
mov dword [rbp + 0xb8], r12d
mov dword [rsp + 0x58], ebx
mov r13d, esi
mov dword [rsp + 0x50], eax
cmp byte [r14 + 0x19], sil
je 0x14001d0a4
cmp qword [rbp + 0xc0], rsi
je 0x14001d0a4
cmp eax, 2
jl 0x14001d0a4
cmp ebx, 5
jl 0x14001d0a4
mov r8d, esi
mov r9d, esi
mov r15d, eax
cmp esi, 5
jne 0x14001cb2b
lea edx, [r15 - 1]
jmp 0x14001cb42
mov ecx, r8d
mov eax, 0x66666667
imul ecx, r15d
imul ecx
sar edx, 1
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [r10 + rdx]
mov dword [rbp + r9 - 0x50], eax
cmp r8d, 5
jne 0x14001cb56
lea edx, [rbx - 1]
jmp 0x14001cb6c
mov ecx, r8d
mov eax, 0x66666667
imul ecx, ebx
imul ecx
sar edx, 1
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [r11 + rdx]
inc r8d
add r9, 4
mov dword [rbp + r9 - 0x3c], eax
cmp r8d, 5
jle 0x14001cb23
mov r15, qword [rbp + 0xa8]
lea rax, [rbp - 0x20]
lea rcx, [rbp - 0x4c]
lea rdx, [rbp - 0x38]
sub rax, rcx
mov qword [rsp + 0x60], 5
mov qword [rbp - 0x60], rax
mov qword [rbp - 0x68], rdx
nop dword [rax]
lea rax, [rdx + 4]
mov ecx, 5
lea rdi, [rbp - 0x50]
mov qword [rbp - 0x78], rax
movsxd rax, dword [rax]
mov qword [rbp - 0x58], rcx
mov dword [rsp + 0x54], eax
mov r9, rax
mov qword [rbp - 0x70], rax
mov ebx, esi
mov r8d, esi
cmp eax, dword [rdx]
jl 0x14001cc2d
movsxd r10, dword [rdi + 4]
mov r12d, dword [rdi]
imul r9, r9, 0x64
sub eax, dword [rdx]
lea r11d, [rax + 1]
nop dword [rax]
cmp r10d, r12d
jl 0x14001cc1c
mov eax, r10d
lea rcx, [r9 + r10]
sub eax, r12d
add rcx, r15
inc eax
mov edx, eax
add ebx, eax
cmp byte [rcx], sil
jne 0x14001cc14
add r8d, 0x400
dec rcx
dec rdx
jne 0x14001cc08
sub r9, 0x64
dec r11
jne 0x14001cbf0
mov rcx, qword [rbp - 0x58]
mov r9, qword [rbp - 0x70]
mov eax, r8d
mov r8, qword [rbp - 0x60]
add rdi, 4
cdq
idiv ebx
mov rdx, qword [rbp - 0x68]
cmp r13d, eax
mov dword [r8 + rdi], eax
cmovl r13d, eax
mov eax, dword [rsp + 0x54]
dec rcx
mov qword [rbp - 0x58], rcx
jne 0x14001cbd3
mov rdx, qword [rbp - 0x78]
add r8, 0x14
dec qword [rsp + 0x60]
mov qword [rbp - 0x68], rdx
mov qword [rbp - 0x60], r8
jne 0x14001cbb0
mov eax, 1
test r13d, r13d
lea rcx, [rbp - 0x1c]
lea r8d, [rax + 4]
cmove r13d, eax
nop word [rax + rax]
mov eax, dword [rcx - 4]
add rcx, 0x14
shl eax, 0xa
cdq
idiv r13d
mov dword [rcx - 0x18], eax
mov eax, dword [rcx - 0x14]
shl eax, 0xa
cdq
idiv r13d
mov dword [rcx - 0x14], eax
mov eax, dword [rcx - 0x10]
shl eax, 0xa
cdq
idiv r13d
mov dword [rcx - 0x10], eax
mov eax, dword [rcx - 0xc]
shl eax, 0xa
cdq
idiv r13d
mov dword [rcx - 0xc], eax
mov eax, dword [rcx - 8]
shl eax, 0xa
cdq
idiv r13d
dec r8
mov dword [rcx - 8], eax
jne 0x14001cc90
mov rdi, qword [rbp + 0xc0]
mov r13, qword [rbp + 0xa0]
mov eax, 0x7fffffff
mov dword [rsp + 0x54], eax
mov eax, dword [rsp + 0x50]
mov r10d, esi
mov r11, rsi
mov r14, rsi
lea r9, [rbp - 0x1c]
imul eax, eax, 0x64
cdq
idiv dword [rsp + 0x58]
add rdi, 0x2c
mov qword [rbp - 0x70], rdi
mov dword [rsp + 0x50], eax
nop word [rax + rax]
mov rax, qword [r13]
mov rbx, r9
mov r13, r9
mov r12, r9
mov r8d, esi
sub r13, rax
sub rbx, rax
lea r15, [r14 + rax + 8]
sub r12, rax
mov esi, 5
nop word [rax + rax]
mov eax, dword [r15 + r13 + 4]
add r15, 0x14
sub eax, dword [r15 - 0xc]
cdq
mov ecx, eax
mov eax, dword [r15 + rbx - 0x1c]
sub eax, dword [r15 - 0x18]
xor ecx, edx
sub ecx, edx
cdq
xor eax, edx
sub eax, edx
add ecx, eax
mov eax, dword [r15 + rbx - 0x14]
sub eax, dword [r15 - 0x10]
cdq
xor eax, edx
sub eax, edx
add ecx, eax
mov eax, dword [r15 + r12 - 0x20]
sub eax, dword [r15 - 0x1c]
cdq
xor eax, edx
sub eax, edx
add ecx, eax
mov eax, dword [r15 + r12 - 0x18]
sub eax, dword [r15 - 0x14]
cdq
xor eax, edx
sub eax, edx
add r8d, eax
add r8d, ecx
dec rsi
jne 0x14001cd50
mov r13, qword [rbp + 0xa0]
mov ebx, dword [rsp + 0x50]
mov rax, qword [r13 + 8]
mov ecx, ebx
sub ecx, dword [r11 + rax]
mov eax, ecx
cdq
xor eax, edx
sub eax, edx
imul eax, eax, 0x12c
add r8d, eax
cmp dword [rsp + 0x54], r8d
jle 0x14001cdea
mov dword [rsp + 0x54], r8d
mov r12d, r10d
mov dword [rbp + 0xb8], r10d
jmp 0x14001cdf1
mov r12d, dword [rbp + 0xb8]
inc r10d
mov dword [r11 + rdi], r8d
add r14, 0x64
sub r9, 0x64
add r11, 4
cmp r10d, 0xa
jl 0x14001cd20
cmp byte [r13 + 0x18], sil
je 0x14001d04b
mov rax, qword [rbp + 0xc0]
mov r8, qword [rbp + 0xa8]
mov dword [rsp + 0x60], 0x64
mov ebx, dword [rax + 0x80]
mov eax, 0x28
mov dword [rsp + 0x64], 0x64
test ebx, ebx
lea r9, [rbp - 0x78]
lea rdx, [rsp + 0x58]
cmovle ebx, eax
xor eax, eax
lea rcx, [rsp + 0x68]
mov qword [rsp + 0x68], rax
mov qword [rsp + 0x70], rax
mov qword [rsp + 0x78], rax
mov qword [rbp - 0x80], rax
mov qword [rsp + 0x58], rax
mov rax, qword [rsp + 0x60]
mov qword [rbp - 0x78], rax
mov rax, qword [rbp + 0xc8]
mov qword [rsp + 0x40], rax
mov eax, dword [rbp - 0x24]
mov dword [rsp + 0x38], eax
mov eax, dword [rbp - 0x3c]
mov dword [rsp + 0x30], eax
mov eax, dword [rbp - 0x38]
mov dword [rsp + 0x28], eax
mov eax, dword [rbp - 0x50]
mov dword [rsp + 0x20], eax
call fcn.14001df50
test al, al
je 0x14001d0a4
mov eax, dword [rsp + 0x5c]
cmp eax, 2
jne 0x14001cecc
mov rcx, qword [rbp + 0xc0]
mov eax, dword [rcx + 0x4c]
sub eax, 0xbb8
cmovs eax, esi
mov dword [rcx + 0x4c], eax
jmp 0x14001cf10
cmp dword [rsp + 0x58], 0x37
jl 0x14001cee1
mov eax, dword [rdi]
sub eax, 0xbb8
cmovs eax, esi
mov dword [rdi], eax
jmp 0x14001cf10
cmp eax, 1
jne 0x14001cf10
mov rcx, qword [rbp + 0xc0]
add dword [rcx + 0x30], 0x1770
add dword [rcx + 0x34], 0x1770
add dword [rcx + 0x38], 0x1770
add dword [rcx + 0x40], 0x1770
add dword [rcx + 0x48], 0x1770
cmp dword [rsp + 0x7c], ebx
mov r14d, dword [rbp - 0x7c]
mov r15d, dword [rbp - 0x80]
mov r11d, 0x7fffffff
mov r13d, esi
mov r9, rdi
mov rdi, qword [rbp + 0xa0]
mov r10d, esi
mov rdx, rsi
setg r13b
mov r12d, r11d
nop dword [rax]
mov r8, qword [rdi + 0x10]
mov eax, esi
cmp dword [r8 + rdx + 0x14], ebx
setg al
cmp r13d, eax
jne 0x14001d013
mov ecx, esi
mov eax, esi
cmp dword [r8 + rdx + 0x10], ecx
setle cl
cmp dword [rsp + 0x78], eax
setle al
cmp eax, ecx
jne 0x14001d013
cmp dword [r8 + rdx + 0x1c], ebx
mov ecx, esi
mov eax, esi
setg cl
cmp r14d, ebx
setg al
cmp eax, ecx
jne 0x14001d013
mov ecx, esi
mov eax, esi
cmp dword [r8 + rdx + 0x18], ecx
setle cl
test r15d, r15d
setle al
cmp eax, ecx
jne 0x14001d013
cmp dword [r8 + rdx + 4], ebx
mov ecx, esi
mov eax, esi
setg cl
cmp dword [rsp + 0x6c], ebx
setg al
cmp eax, ecx
jne 0x14001d013
mov ecx, esi
mov eax, esi
cmp dword [r8 + rdx], ecx
setle cl
cmp dword [rsp + 0x68], eax
setle al
cmp eax, ecx
jne 0x14001d013
cmp dword [r8 + rdx + 0xc], ebx
mov ecx, esi
mov eax, esi
setg cl
cmp dword [rsp + 0x74], ebx
setg al
cmp eax, ecx
jne 0x14001d013
mov ecx, esi
mov eax, esi
cmp dword [r8 + rdx + 8], ecx
setle cl
cmp dword [rsp + 0x70], eax
setle al
cmp eax, ecx
jne 0x14001d013
mov eax, dword [r9]
mov dword [r9 - 0x28], 1
sub eax, 0x7d0
cmovs eax, esi
mov dword [r9], eax
mov eax, dword [r9]
cmp r12d, eax
jle 0x14001d025
mov r12d, eax
mov dword [rbp + 0xb8], r10d
inc r10d
add rdx, 0x20
add r9, 4
cmp r10d, 0xa
jl 0x14001cf40
mov rdi, qword [rbp - 0x70]
mov ebx, dword [rsp + 0x50]
mov r12d, dword [rbp + 0xb8]
jmp 0x14001d051
mov r11d, 0x7fffffff
cmp r12d, 1
je 0x14001d06e
cmp ebx, 0x25
jge 0x14001d09d
mov rax, qword [rbp + 0xc0]
mov r12d, 1
mov dword [rax + 0x30], esi
jmp 0x14001d09d
cmp ebx, 0x35
jle 0x14001d09d
mov rax, qword [rbp + 0xc0]
mov dword [rax + 0x30], r11d
nop
cmp esi, 1
je 0x14001d092
mov eax, dword [rdi]
cmp r11d, eax
jle 0x14001d092
mov r11d, eax
mov r12d, esi
inc esi
add rdi, 4
cmp esi, 0xa
jl 0x14001d080
mov byte [rbp + 0xb0], 1
mov rax, qword [rbp + 0xc0]
mov dword [rax], r12d
movzx eax, byte [rbp + 0xb0]
add rsp, 0x158
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret