Function at 0x1400098ee
Capabilities:
Encode data using xor

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x158
mov rax, rcx
mov rsi, qword [rsp + 0x1d0]
mov r12, qword [rsp + 0x1c0]
xorps xmm0, xmm0
movaps xmmword [rsp + 0x60], xmm0
movaps xmmword [rsp + 0x70], xmm0
movaps xmmword [rsp + 0x80], xmm0
movaps xmmword [rsp + 0x90], xmm0
mov ecx, edx
xor r11d, r11d
mov r10d, dword [rax + r11*4]
inc dword [rsp + r10*4 + 0x60]
inc r11
cmp ecx, r11d
jne 0x140009936
cmp dword [rsp + 0x60], ecx
jne 0x140009969
mov rax, qword [rsp + 0x1c8]
mov qword [rax], 0
mov dword [rsi], 0
xor eax, eax
jmp 0x140009dac
mov ebx, dword [rsi]
mov ecx, 1
cmp dword [rsp + rcx*4 + 0x60], 0
jne 0x140009985
inc rcx
cmp rcx, 0x10
jne 0x140009970
mov ecx, 0x10
cmp ebx, ecx
cmovbe ebx, ecx
mov r15d, 0xf
mov r10d, r15d
cmp dword [rsp + r10*4 + 0x60], 0
jne 0x1400099a3
dec r15d
jne 0x140009990
xor r15d, r15d
cmp ebx, r15d
cmovae ebx, r15d
mov dword [rsi], ebx
mov esi, 1
shl esi, cl
cmp ecx, r15d
jae 0x1400099d5
mov r10d, ecx
mov r11d, r15d
sub esi, dword [rsp + r10*4 + 0x60]
js 0x140009da7
inc r10
add esi, esi
cmp r11, r10
jne 0x1400099be
jmp 0x1400099d8
mov r11d, r15d
mov r10d, dword [rsp + r11*4 + 0x60]
cmp esi, r10d
js 0x140009da7
mov dword [rsp + 0x20], r10d
mov dword [rsp + 0x1c], esi
mov dword [rsp + r11*4 + 0x60], esi
mov dword [rsp + 0xa4], 0
cmp r15d, 1
je 0x140009a26
mov esi, r15d
dec rsi
xor r11d, r11d
xor r10d, r10d
add r10d, dword [rsp + r11*4 + 0x64]
mov dword [rsp + r11*4 + 0xa8], r10d
inc r11
cmp esi, r11d
jne 0x140009a11
cmp edx, 2
mov edi, 1
cmovae edi, edx
xor edx, edx
lea r13, [0x140040bd0]
mov esi, dword [rax + rdx*4]
test rsi, rsi
je 0x140009a5b
mov r10d, dword [rsp + rsi*4 + 0xa0]
lea r11d, [r10 + 1]
mov dword [rsp + rsi*4 + 0xa0], r11d
mov dword [r13 + r10*4], edx
inc rdx
cmp edi, edx
jne 0x140009a3a
mov qword [rsp + 8], r13
movsxd rax, r15d
mov eax, dword [rsp + rax*4 + 0xa0]
mov dword [rsp + 0xa0], 0
mov qword [rsp + 0xe0], 0
cmp ecx, r15d
jle 0x140009aab
mov eax, dword [rsp + 0x1c]
cmp eax, dword [rsp + 0x20]
setne al
cmp r15d, 1
setne cl
and cl, al
movzx eax, cl
neg eax
jmp 0x140009dac
mov esi, ebx
neg esi
lea rdx, [0x140040bd0]
lea rax, [rdx + rax*4]
mov qword [rsp + 0x58], rax
mov r10d, ecx
lea eax, [r15 + 1]
mov qword [rsp + 0x48], rax
lea rax, [rsp + r10*4]
add rax, 0x64
mov qword [rsp + 0x38], rax
mov edi, 0xffffffff
xor r11d, r11d
mov eax, esi
xor r13d, r13d
xor ecx, ecx
mov qword [rsp + 0x30], rcx
xor ebp, ebp
mov qword [rsp + 0x10], rbx
mov dword [rsp + 0x18], r8d
mov qword [rsp + 0x50], r9
mov qword [rsp + 0x28], rsi
mov edx, dword [rsp + r10*4 + 0x60]
lea ecx, [r10 - 1]
mov r14d, 1
shl r14d, cl
mov dword [rsp + 0x24], r14d
mov dword [rsp], edx
test edx, edx
je 0x140009d8e
mov qword [rsp + 0x40], r10
lea ecx, [rax + rbx]
movsxd rdx, ecx
cmp r10, rdx
jle 0x140009c8b
mov dword [rsp + 4], r13d
mov r8, rbx
mov ebx, r15d
sub ebx, ecx
movsxd r12, edi
mov r14, qword [rsp + 0x1e0]
mov esi, ecx
cmp r8d, ebx
mov r11d, ebx
cmovb r11d, r8d
mov edi, r15d
sub edi, ecx
cmp edi, r8d
cmovae edi, r8d
mov edx, r10d
sub edx, ecx
mov r13d, 1
mov ecx, edx
shl r13d, cl
mov r10d, edx
sub r13d, dword [rsp]
jbe 0x140009bad
mov r10d, edx
cmp edx, edi
jae 0x140009bad
lea r10d, [rdx + 1]
cmp r10d, edi
jae 0x140009bad
mov rcx, qword [rsp + 0x38]
add r13d, r13d
sub r13d, dword [rcx]
jbe 0x140009bad
inc r10d
add rcx, 4
cmp r10d, edi
jb 0x140009b96
mov r10d, r11d
mov r11d, 1
mov ecx, r10d
shl r11d, cl
mov ecx, dword [r14]
mov r8, r14
lea r14d, [rcx + r11]
cmp r14d, 0x5a0
ja 0x140009da7
lea rdi, [r12 + 1]
mov r13, qword [rsp + 0x1d8]
lea r9, [rcx*4]
add r9, r13
mov qword [rsp + rdi*8 + 0xe0], r9
mov dword [r8], r14d
test edi, edi
je 0x140009c3b
mov dword [rsp + rdi*4 + 0xa0], ebp
mov r14d, ebp
mov ecx, eax
shr r14d, cl
mov rax, qword [rsp + r12*8 + 0xe0]
mov ecx, r9d
sub ecx, eax
shr ecx, 2
sub ecx, r14d
mov byte [rax + r14*4], r10b
mov r8, qword [rsp + 0x10]
mov byte [rax + r14*4 + 1], r8b
mov dword [rsp + 4], ecx
mov word [rax + r14*4 + 2], cx
mov r14, qword [rsp + 0x1e0]
jmp 0x140009c4e
mov r14, r8
mov rax, qword [rsp + 0x1c8]
mov qword [rax], r9
mov r8, qword [rsp + 0x10]
lea ecx, [rsi + r8]
movsxd r13, ecx
sub ebx, r8d
mov r12, rdi
mov eax, esi
mov r10, qword [rsp + 0x40]
cmp r10, r13
jg 0x140009b50
mov qword [rsp + 0x30], r9
mov eax, esi
mov r9, qword [rsp + 0x50]
mov r8d, dword [rsp + 0x18]
mov r12, qword [rsp + 0x1c0]
mov r13d, dword [rsp + 4]
jmp 0x140009c90
mov edx, r10d
sub edx, eax
mov r10b, 0xc0
mov rsi, qword [rsp + 8]
cmp rsi, qword [rsp + 0x58]
jae 0x140009ce1
mov r13d, dword [rsi]
mov ecx, r13d
sub ecx, r8d
jae 0x140009ccb
cmp r13d, 0x100
mov r10d, 0x60
mov ecx, 0
cmovb r10d, ecx
add rsi, 4
mov qword [rsp + 8], rsi
jmp 0x140009ce1
mov r10b, byte [r12 + rcx*2]
add r10b, 0x50
add rsi, 4
mov qword [rsp + 8], rsi
movzx r13d, word [r9 + rcx*2]
mov esi, 1
mov ecx, edx
shl esi, cl
mov ebx, ebp
mov ecx, eax
shr ebx, cl
cmp ebx, r11d
mov r14, qword [rsp + 0x30]
jae 0x140009d12
mov ecx, ebx
mov byte [r14 + rcx*4], r10b
mov byte [r14 + rcx*4 + 1], dl
mov word [r14 + rcx*4 + 2], r13w
add ebx, esi
cmp ebx, r11d
jb 0x140009cfa
mov ecx, dword [rsp + 0x24]
test ecx, ebp
mov rbx, qword [rsp + 0x10]
je 0x140009d2e
mov rsi, qword [rsp + 0x28]
xor ebp, ecx
shr ecx, 1
test ecx, ebp
jne 0x140009d24
jmp 0x140009d33
mov rsi, qword [rsp + 0x28]
xor ebp, ecx
dec dword [rsp]
mov edx, 0xffffffff
mov ecx, eax
shl edx, cl
not edx
and edx, ebp
movsxd rcx, edi
cmp edx, dword [rsp + rcx*4 + 0xa0]
je 0x140009d7f
lea rdx, [rsp + 0x9c]
lea rdx, [rdx + rcx*4]
lea ecx, [rsi + rax]
mov r10d, 0xffffffff
shl r10d, cl
sub eax, ebx
not r10d
and r10d, ebp
dec edi
lea rcx, [rdx - 4]
cmp r10d, dword [rdx]
mov rdx, rcx
jne 0x140009d5d
cmp dword [rsp], 0
mov r10, qword [rsp + 0x40]
jne 0x140009b29
inc r10
add qword [rsp + 0x38], 4
cmp r10, qword [rsp + 0x48]
jne 0x140009b02
jmp 0x140009a8d
mov eax, 0xffffffff
add rsp, 0x158
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret