Function at 0x18007a870
Capabilities:
Encode data using xor
Encrypt data using rc4 prga
Hash data using djb2

Disassembly:
mov r11, rsp
mov qword [r11 + 0x10], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x50
mov rbx, r8
mov r12d, edx
mov rsi, rcx
xor ebp, ebp
mov r8d, ebp
mov r15, qword [rcx + 0x498]
mov eax, dword [rcx + 0x18]
shr rax, 0x19
test al, 1
je 0x18007a913
mov r9, qword [rcx + 0x270]
movzx eax, word [r9]
mov word [r11 + 8], ax
movzx eax, byte [r9 + 2]
mov byte [r11 + 0xa], al
and r12d, 0xffffff
lea rax, [r11 + 0x20]
mov qword [r11 - 0x60], rax
lea rax, [r11 - 0x50]
mov qword [r11 - 0x68], rax
mov r9d, r12d
lea r8, [r11 + 8]
lea edx, [rbp + 0x19]
call fcn.18006f610
mov r8d, eax
test eax, eax
js 0x18007ab19
mov dword [rbx + 8], ebp
mov dword [rbx], ebp
mov edx, dword [rsp + 0xa8]
mov dword [rbx + 0x14], edx
mov dword [rbx + 0xc], edx
mov ecx, dword [rsp + 0x38]
mov dword [rbx + 0x10], ecx
sub ecx, edx
mov dword [rbx + 4], ecx
jmp 0x18007ab19
lea r14, [rbx + 0x18]
mov dword [rbx + 4], ebp
mov qword [rbx + 0xc], rbp
mov dword [rbx + 0x14], ebp
mov qword [rsp + 0x90], r14
mov eax, 4
test r15, r15
je 0x18007aa60
mov qword [r14 + 0x14], rbp
mov dword [r14 + 0x1c], ebp
mov dword [rbx + 8], 2
mov dword [rbx], 0xffffffff
mov qword [r14], rbp
mov qword [r14 + 8], rbp
mov dword [r14 + 0x10], 0x10
mov word [r14 + 0x14], ax
mov byte [r14 + 0x16], 1
mov dword [rsp + 0x30], r12d
lea rdx, [rsp + 0x30]
mov eax, 0x1505
nop dword [rax]
nop dword [rax + rax]
imul eax, eax, 0x21
movzx ecx, byte [rdx]
xor eax, ecx
inc rdx
lea rcx, [rsp + 0x34]
cmp rdx, rcx
jb 0x18007a980
xor edx, edx
div dword [r15 + 0x20]
movsxd rcx, edx
mov rax, qword [r15 + 0x18]
movsxd rdx, dword [rax + rcx*4]
cmp edx, 0xffffffff
je 0x18007ab19
lea rcx, [rdx + rdx*2]
mov rax, qword [r15]
lea rdi, [rax + rcx*4]
mov ebp, dword [rdi + 8]
test rdi, rdi
je 0x18007ab19
nop word [rax + rax]
mov rax, qword [rsi + 0xd28]
lea r8, [rsp + 0x40]
mov edx, dword [rdi]
lea rcx, [rsi + 0xd28]
mov rax, qword [rax + 0xa8]
call qword [0x180102408]
mov r8d, eax
test eax, eax
js 0x18007ab19
mov rax, qword [rsi + 0x270]
movzx ecx, byte [rax + 1]
add rcx, qword [rsp + 0x40]
cmp byte [rax + 2], 2
jne 0x18007aa18
movzx eax, word [rcx]
jmp 0x18007aa1a
mov eax, dword [rcx]
bts eax, 0x19
cmp eax, r12d
jne 0x18007aa41
mov edi, dword [rdi]
mov rcx, r14
call fcn.18008d130
test rax, rax
je 0x18007ab13
mov dword [rax], edi
inc dword [rbx + 4]
inc dword [rbx + 0x10]
xor r8d, r8d
cmp ebp, 0xffffffff
je 0x18007ab19
movsxd rax, ebp
lea rcx, [rax + rax*2]
mov rax, qword [r15]
lea rdi, [rax + rcx*4]
mov ebp, dword [rdi + 8]
jmp 0x18007a9d0
mov qword [r14 + 4], rbp
mov qword [r14 + 0x14], rbp
mov dword [r14 + 0x1c], ebp
mov dword [rbx + 8], 2
mov dword [rbx], 0xffffffff
mov qword [r14], rbp
mov dword [r14 + 0xc], ebp
mov dword [r14 + 0x10], 0x10
mov word [r14 + 0x14], ax
mov byte [r14 + 0x16], 1
mov edi, 1
cmp dword [rcx + 0x84], edi
jb 0x18007ab19
nop
mov rax, qword [rsi + 0xd28]
lea r8, [rsp + 0x40]
mov edx, edi
lea rcx, [rsi + 0xd28]
mov rax, qword [rax + 0xa8]
call qword [0x180102408]
mov r8d, eax
test eax, eax
js 0x18007ab19
mov rax, qword [rsi + 0x270]
movzx ecx, byte [rax + 1]
add rcx, qword [rsp + 0x40]
cmp byte [rax + 2], 2
jne 0x18007aae4
movzx eax, word [rcx]
jmp 0x18007aae6
mov eax, dword [rcx]
bts eax, 0x19
cmp eax, r12d
jne 0x18007ab07
mov rcx, r14
call fcn.18008d130
test rax, rax
je 0x18007ab13
mov dword [rax], edi
inc dword [rbx + 4]
inc dword [rbx + 0x10]
mov r8d, ebp
inc edi
cmp edi, dword [rsi + 0x84]
ja 0x18007ab19
jmp 0x18007aaa0
mov r8d, 0x8007000e
mov eax, r8d
mov rbx, qword [rsp + 0x98]
add rsp, 0x50
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret