Function at 0x180006b70
Capabilities:
Encode data using xor
Encrypt data using rc4 prga

Disassembly:
mov qword [rsp + 0x18], r8
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x18
mov r14, qword [0x18002f928]
mov rsi, rdx
mov r12, qword [rsp + 0x88]
mov r13, rcx
movzx eax, word [0x18002f8dc]
xor edx, edx
movsxd rdi, dword [rsp + 0x90]
mov ecx, 0xffff
mov r15, qword [rsp + 0x80]
movzx r11d, r9b
movzx eax, byte [rax + r8]
mov ebp, r11d
or rax, r14
mov qword [rsp + 8], r11
mov qword [rsp], rax
mov r8d, 1
add dword [0x18002f8a0], r8d
movzx eax, word [0x18002f938]
add ax, cx
mov qword [rsp + 0x68], r14
mov word [0x18002f938], ax
mov ecx, 0x14b7
movzx r10d, ax
mov eax, r11d
add rax, rax
mov qword [rsp + 0x80], rcx
mov byte [rsp + 0x78], 0x7e
mov rax, qword [r12 + rax*8]
div qword [r13 + 0xa898]
mov rax, qword [0x18002f8f8]
shl rax, 5
mov rbx, rdx
xor edx, edx
mov rax, qword [rax + r12 + 0x10]
div qword [r13 + 0x2698]
sub dword [0x18002f8c4], r8d
movsxd rax, dword [r15 + rdi*4]
mov r8, qword [0x18002f908]
mov qword [rsp + 0x60], rax
mov eax, dword [0x18002f910]
imul eax, dword [rsp + 0x90]
mov qword [rsp + 0x88], rdx
xor edx, edx
mov dword [0x18002f910], eax
movsxd r9, dword [rbx]
mov eax, dword [rbx + rdi*4]
add rax, qword [0x18002f930]
and rax, rcx
movsxd rcx, dword [r8 + r9*4]
div rcx
mov eax, 0xe97
mov dword [r8 + r9*4], edx
mov edx, 1
movzx ecx, word [0x18002f940]
sub r11b, dl
mov r8, qword [rsp + 0x88]
imul ecx, eax
mov rax, qword [0x18002f8f8]
mov word [0x18002f940], cx
movzx ecx, r11b
sub rax, qword [r12 + rcx*8]
mov qword [r12 + rcx*8], rax
mov eax, dword [0x18002f914]
add eax, edx
mov dword [0x18002f914], eax
cdqe
or r8d, dword [r10 + rax*8 + 0x19bb]
mov rax, qword [0x18002f8b0]
lea rdx, [rax + rax*2]
mov eax, dword [0x18002f8a4]
lea eax, [rax*2 + 0x1d]
movsxd rcx, eax
mov eax, dword [rsi + rdx*4]
imul eax, dword [r14 + rcx*8]
mov dword [rsi + rdx*4], eax
mov rax, qword [rsp + 0x60]
movsxd r11, dword [0x18002f930]
cmp r11d, dword [rax + rdi*4]
jg 0x180006e50
mov rbp, qword [rsp + 0x68]
lea rax, [r11 + r11*2]
mov r10, rsi
lea r15, [r15 + rax*4]
sub r10, rbx
lea r14, [rbx + r11*4]
mov rax, qword [0x18002f8b8]
xor edx, edx
movzx r9d, byte [rsp + 0x78]
movsxd rcx, r8d
div rcx
lea eax, [r9 + r11]
mov ecx, edx
cdq
idiv dword [0x18002f910]
lea eax, [rcx + rcx*2]
mov qword [rsp + 0x88], rcx
movsxd r8, eax
mov rax, qword [rsp + 0x70]
mov dword [0x18002f910], edx
movzx ecx, byte [r8 + rax]
mov eax, dword [r10 + r14 + 0x20]
cdq
idiv ecx
mov rcx, qword [rsp + 0x70]
mov rdx, qword [rsp + 0x80]
mov byte [r8 + rcx], al
mov ecx, 1
mov eax, dword [0x18002f910]
sub edx, ecx
add eax, ecx
mov qword [rsp + 0x80], rdx
mov dword [0x18002f910], eax
imul eax, dword [r15]
lea r15, [r15 + 0xc]
movsxd rcx, dword [rbx]
movsxd r8, r11d
or eax, edx
cdq
idiv dword [rsi + rcx*4]
xor edx, edx
mov dword [rsi + rcx*4], eax
movzx ecx, word [0x18002f938]
mov rax, qword [rsp]
movsxd rax, dword [rax + rcx*4 + 0x58]
or rax, r8
and rax, qword [0x18002f8e8]
div rcx
mov rcx, qword [0x18002f8f8]
mov rax, r8
inc dx
mov word [0x18002f938], dx
xor edx, edx
div qword [r13 + rcx*8 + 0x110]
mov qword [r13 + rcx*8 + 0x110], rdx
xor edx, edx
mov rax, qword [0x18002f920]
add rax, rax
and qword [rbp + rax*8], r8
mov eax, r9d
movsxd rcx, dword [r14]
lea r14, [r14 + 4]
mov r8, qword [rsp + 0x88]
shl eax, 2
mov rax, qword [r12 + rax*8]
div rcx
mov eax, 1
add byte [rsp + 0x78], al
add r11d, eax
mov rax, qword [rsp + 0x60]
xor word [0x18002f938], dx
cmp r11d, dword [rax + rdi*4]
jle 0x180006d2a
mov rbp, qword [rsp + 8]
movzx eax, word [rbp + rdi*2]
add rsp, 0x18
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret