Function at 0x1801fa000
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push r15
push r14
push rdi
push rsi
push rbp
push rbx
sub rsp, 0x78
movaps xmmword [rsp + 0x60], xmm6
movaps xmmword [rsp + 0x50], xmm7
movaps xmmword [rsp + 0x40], xmm8
mov rbx, rcx
mov esi, edx
mov rdi, r8
mov rbp, r9
mov edx, esi
mov rcx, rbx
call fcn.1801ec9a0
mov ecx, eax
lea rbx, [rbx + rcx*2]
sub esi, eax
jne 0x1801fa063
xor eax, eax
mov qword [rdi], rax
mov dword [rbp], eax
mov rax, rbx
movaps xmm6, xmmword [rsp + 0x60]
movaps xmm7, xmmword [rsp + 0x50]
movaps xmm8, xmmword [rsp + 0x40]
add rsp, 0x78
pop rbx
pop rbp
pop rsi
pop rdi
pop r14
pop r15
ret
xor eax, eax
xor ecx, ecx
mov edx, esi
lea rdx, [rbx + rdx*2]
mov r8d, dword [0x1806e69e0]
test r8b, 0x10
je 0x1801fa1e8
cmp esi, 8
jl 0x1801fa32f
movups xmm0, xmmword [0x18056c860]
movups xmm1, xmmword [0x18056c870]
movups xmm2, xmmword [0x18056c880]
lea r10, [rdx - 0x10]
movups xmm3, xmmword [rbx]
add rbx, 0x10
movaps xmm4, xmm3
pminuw xmm4, xmm0
movaps xmm5, xmm3
paddusw xmm5, xmm1
por xmm4, xmm5
pmovmskb r9d, xmm4
mov r11d, r8d
and r11d, 0x40
je 0x1801fa0d1
xor esi, esi
popcnt esi, r9d
jmp 0x1801fa10e
mov esi, r9d
shr esi, 1
and esi, 0x55555555
sub r9d, esi
mov esi, r9d
and esi, 0x33333333
shr r9d, 2
and r9d, 0x33333333
add r9d, esi
mov esi, r9d
shr esi, 4
add esi, r9d
and esi, 0xf0f0f0f
imul esi, esi, 0x1010101
shr esi, 0x18
mov r9d, esi
movaps xmm4, xmm3
paddw xmm4, xmm2
movaps xmm5, xmm1
pcmpgtw xmm5, xmm4
pmovmskb esi, xmm5
cmp esi, 0xffff
jne 0x1801fa13c
add rax, r9
cmp rbx, r10
jbe 0x1801fa0a0
jmp 0x1801fa32f
not esi
psrlw xmm3, 3
pmovmskb r14d, xmm3
mov r15d, r14d
and r15d, esi
xor r14d, 0x5555
and r14d, esi
shl r14d, 2
movzx esi, r14w
cmp esi, r15d
jne 0x1801fa1df
cmp r14d, 0xffff
jbe 0x1801fa17a
movzx r14d, r14w
add r9, 0xfffffffffffffffe
add rbx, 0xfffffffffffffffe
test r11d, r11d
je 0x1801fa189
xor r11d, r11d
popcnt r11d, r14d
jmp 0x1801fa1ce
mov r11d, r14d
shr r11d, 1
and r11d, 0x55555555
mov esi, r14d
sub esi, r11d
mov r11d, esi
and r11d, 0x33333333
shr esi, 2
and esi, 0x33333333
add esi, r11d
mov r11d, esi
shr r11d, 4
add r11d, esi
and r11d, 0xf0f0f0f
imul r11d, r11d, 0x1010101
shr r11d, 0x18
mov r11d, r11d
sub ecx, r11d
sub rax, r11
sub rax, r11
jmp 0x1801fa12b
add rbx, 0xfffffffffffffff0
jmp 0x1801fa32f
cmp esi, 8
jl 0x1801fa32f
movups xmm0, xmmword [0x18056c860]
movups xmm1, xmmword [0x18056c890]
movups xmm2, xmmword [0x18056c8a0]
lea r8, [rdx - 0x10]
movups xmm3, xmmword [0x18056c8b0]
movups xmm4, xmmword [rbx]
movaps xmm5, xmm4
psubw xmm5, xmm3
movups xmm6, xmmword [0x18056c8c0]
movaps xmm7, xmm5
pcmpgtw xmm7, xmm6
movaps xmm6, xmm4
pcmpeqw xmm6, xmm0
por xmm6, xmm7
xorps xmm7, xmm7
psubw xmm7, xmm6
movaps xmm6, xmm4
pcmpeqw xmm6, xmm1
movups xmm8, xmmword [0x18056c8d0]
pcmpgtw xmm5, xmm8
por xmm5, xmm6
psubw xmm7, xmm5
movaps xmmword [rsp + 0x30], xmm7
mov r10, qword [rsp + 0x30]
movaps xmmword [rsp + 0x30], xmm7
add r10, qword [rsp + 0x38]
mov r9d, r10d
shr r10, 0x20
add r9d, r10d
movzx r10d, r9w
shr r9d, 0x10
add r9d, r10d
psubw xmm4, xmm2
psubw xmm4, xmm3
movups xmm5, xmmword [0x18056c8d0]
pcmpgtw xmm5, xmm4
xorps xmm6, xmm6
pcmpeqw xmm6, xmm5
pmovmskb r10d, xmm6
cmp r10d, 0xffff
je 0x1801fa31c
movups xmm6, xmmword [0x18056c8e0]
pcmpgtw xmm6, xmm4
movaps xmm4, xmm6
pandn xmm4, xmm5
movd r10d, xmm4
movzx r10d, r10w
test r10d, r10d
jne 0x1801fa392
xor r10d, r10d
xor r11d, r11d
movaps xmmword [rsp + 0x20], xmm6
movzx esi, word [rsp + r11*2 + 0x20]
sub r10d, esi
movzx r10d, r10w
inc r11d
movaps xmmword [rsp + 0x20], xmm4
movzx r14d, word [rsp + r11*2 + 0x20]
cmp r14d, esi
jne 0x1801fa32f
cmp r11d, 7
jl 0x1801fa2d2
pextrw r11d, xmm6, 7
test r11d, r11d
je 0x1801fa310
add rbx, 0xfffffffffffffffe
add r9d, 0xfffffffe
mov r10d, r10d
sub ecx, r10d
sub rax, r10
sub rax, r10
mov r10d, r9d
add rax, r10
add rbx, 0x10
cmp rbx, r8
jbe 0x1801fa211
cmp rbx, rdx
jae 0x1801fa392
movzx r8d, word [rbx]
cmp r8d, 0x7f
jbe 0x1801fa389
lea r10d, [r8 + 0x1f800]
shr r10d, 0x10
add rax, r10
add r8d, 0xffff2800
cmp r8d, 0x7ff
ja 0x1801fa389
add rax, 0xfffffffffffffffe
mov r8, rdx
sub r8, rbx
cmp r8, 4
jb 0x1801fa392
mov r8d, dword [rbx]
add r8d, 0x23ff2800
test r8d, 0xfc00fc00
jne 0x1801fa392
dec ecx
add rax, 2
add rbx, 2
add rbx, 2
cmp rbx, rdx
jb 0x1801fa334
mov qword [rdi], rax
mov dword [rbp], ecx
mov rax, rbx
movaps xmm6, xmmword [rsp + 0x60]
movaps xmm7, xmmword [rsp + 0x50]
movaps xmm8, xmmword [rsp + 0x40]
add rsp, 0x78
pop rbx
pop rbp
pop rsi
pop rdi
pop r14
pop r15
ret