Function at 0x1400a29a0
Capabilities:
Encrypt data using rc4 prga

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rdi
mov edi, dword [rdx + 8]
mov rbx, rdx
movzx ebp, word [rcx + 8]
xor edx, edx
mov r11d, 1
lea eax, [rdi + 1]
imul eax, ebp
dec eax
div dword [rbx + 4]
movzx edx, word [rcx + 0xa]
cmp edx, eax
jbe 0x1400a29ee
nop dword [rax]
nop dword [rax + rax]
inc r11d
movzx r8d, word [rcx + r11*2 + 8]
cmp r8d, eax
ja 0x1400a29e0
mov r9d, dword [rbx]
xor edx, edx
mov r8d, r11d
lea r10d, [r9 - 1]
movzx eax, word [rcx + r8*2 + 6]
imul eax, dword [rbx + 4]
div ebp
xor edx, edx
add r10d, eax
movzx eax, word [rcx + r8*2 + 8]
imul eax, dword [rbx + 4]
div ebp
sub edi, eax
add eax, r9d
mov dword [rbx + 8], edi
mov dword [rbx], eax
mov edx, dword [rbx]
mov eax, edx
xor eax, r10d
bt eax, 0xf
jae 0x1400a2a46
bt edx, 0xe
jae 0x1400a2aa7
bt r10d, 0xe
jb 0x1400a2aa7
bts r10d, 0xe
and edx, 0x3fff
and edx, 0x7fff
and r10d, 0x7fff
add edx, edx
add r10d, r10d
mov dword [rbx], edx
or r10d, 1
mov edx, dword [rbx + 0x10]
cmp edx, 0x10000
jb 0x1400a2a8c
mov rax, qword [rbx + 0x18]
cmp rax, qword [rbx + 0x20]
jb 0x1400a2a7b
mov dl, 0xff
mov byte [rbx + 0x14], 1
jmp 0x1400a2a85
movzx edx, byte [rax]
inc rax
mov qword [rbx + 0x18], rax
movzx edx, dl
bts edx, 8
lea eax, [rdx + rdx]
shr edx, 7
mov dword [rbx + 0x10], eax
and edx, 1
mov eax, dword [rbx + 8]
add eax, eax
or edx, eax
mov dword [rbx + 8], edx
jmp 0x1400a2a21
sub r10d, edx
inc r10d
dec r11d
mov dword [rbx + 4], r10d
movzx edi, byte [r11 + rcx + 0x8a]
nop dword [rax]
add word [rcx + r11*2 + 8], 8
mov eax, r11d
dec r11d
test eax, eax
jne 0x1400a2ac0
mov eax, 0xed8
cmp word [rcx + 8], ax
jbe 0x1400a2bf8
add dword [rcx + 4], 0xffffffff
mov edx, dword [rcx]
jne 0x1400a2bcd
xor r9d, r9d
mov dword [rcx + 4], 0x32
mov r10d, r9d
test edx, edx
je 0x1400a2b26
nop dword [rax]
mov eax, r10d
inc r10d
lea r8, [rcx + rax*2]
movzx edx, word [rcx + rax*2 + 0xa]
movzx eax, word [r8 + 8]
sub eax, edx
inc eax
sar eax, 1
mov word [r8 + 8], ax
mov edx, dword [rcx]
cmp r10d, edx
jb 0x1400a2b00
lea eax, [rdx - 1]
test eax, eax
je 0x1400a2ba0
nop dword [rax]
lea ebx, [r9 + 1]
mov eax, edx
mov r8d, ebx
cmp ebx, edx
jae 0x1400a2b8d
mov r11d, r9d
movzx r9d, word [rcx + r11*2 + 8]
mov r10d, r8d
movzx eax, word [rcx + r10*2 + 8]
cmp r9w, ax
jae 0x1400a2b83
movzx edx, byte [rcx + r11 + 0x8a]
mov word [rcx + r11*2 + 8], ax
movzx eax, byte [rcx + r10 + 0x8a]
mov byte [rcx + r11 + 0x8a], al
mov word [rcx + r10*2 + 8], r9w
mov byte [rcx + r10 + 0x8a], dl
mov eax, dword [rcx]
inc r8d
cmp r8d, eax
jb 0x1400a2b40
mov edx, eax
mov r9d, ebx
dec eax
cmp ebx, eax
jb 0x1400a2b30
nop dword [rax + rax]
mov edx, r9d
lea r8, [rcx + rdx*2]
movzx edx, word [rcx + rdx*2 + 0xa]
add word [r8 + 8], dx
mov edx, r9d
dec r9d
test edx, edx
jne 0x1400a2ba0
mov eax, edi
mov rbx, qword [rsp + 8]
mov rbp, qword [rsp + 0x10]
mov rdi, qword [rsp + 0x18]
ret
lea r8d, [rdx - 1]
shr word [rcx + r8*2 + 8], 1
movzx edx, word [rcx + r8*2 + 0xa]
cmp word [rcx + r8*2 + 8], dx
ja 0x1400a2bee
inc dx
mov word [rcx + r8*2 + 8], dx
mov eax, r8d
dec r8d
test eax, eax
jne 0x1400a2bd1
mov rbx, qword [rsp + 8]
mov eax, edi
mov rdi, qword [rsp + 0x18]
mov rbp, qword [rsp + 0x10]
ret