Function at 0x1800223c0
Capabilities:
Encrypt data using rc4 prga

Disassembly:
mov dword [rsp + 0x20], r9d
mov qword [rsp + 0x18], r8
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
sub rsp, 0x58
mov rax, qword [rsp + 0x60]
mov qword [rsp + 0x40], rax
mov rax, qword [rsp + 0x70]
movsx eax, byte [rax]
test eax, eax
jne 0x1800223f5
mov byte [rsp + 0x21], 1
jmp 0x1800223fa
mov byte [rsp + 0x21], 0
movzx eax, byte [rsp + 0x21]
mov byte [rsp + 0x20], al
mov dword [rsp + 0x30], 1
cmp dword [rsp + 0x78], 0
jne 0x18002241c
mov eax, dword [rsp + 0x78]
dec eax
mov dword [rsp + 0x78], eax
mov rax, qword [rsp + 0x70]
movsx eax, byte [rax]
cmp eax, 0x52
jne 0x180022448
mov rax, qword [rsp + 0x70]
inc rax
mov qword [rsp + 0x70], rax
mov eax, dword [rsp + 0x78]
dec eax
mov dword [rsp + 0x78], eax
mov dword [rsp + 0x30], 0xffffffff
jmp 0x180022461
mov rax, qword [rsp + 0x70]
inc rax
mov qword [rsp + 0x70], rax
mov eax, dword [rsp + 0x78]
dec eax
mov dword [rsp + 0x78], eax
mov rax, qword [rsp + 0x70]
movsx eax, byte [rax]
test eax, eax
je 0x180022613
movzx eax, byte [rsp + 0x20]
test eax, eax
jne 0x180022613
cmp dword [rsp + 0x78], 2
jb 0x180022613
cmp qword [rsp + 0x68], 0
jne 0x18002249b
mov eax, 0xffffffff
jmp 0x180022632
mov rax, qword [rsp + 0x70]
movsx eax, byte [rax]
cmp eax, 0x20
jne 0x1800224aa
jmp 0x18002244a
mov rax, qword [rsp + 0x70]
movsx eax, byte [rax]
cmp eax, 0x3b
jne 0x1800224c1
mov eax, 1
jmp 0x180022632
mov rax, qword [rsp + 0x70]
movsx eax, byte [rax]
cmp eax, 0x2a
jne 0x180022557
mov dword [rsp + 0x34], 0
mov rax, qword [rsp + 0x70]
inc rax
mov qword [rsp + 0x70], rax
lea rdx, [rsp + 0x34]
mov rcx, qword [rsp + 0x70]
call fcn.180007530
mov dword [rsp + 0x24], eax
mov eax, dword [rsp + 0x68]
cmp dword [rsp + 0x24], eax
jle 0x18002250e
mov eax, 0xffffffff
jmp 0x180022632
mov eax, dword [rsp + 0x34]
mov rcx, qword [rsp + 0x70]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x70], rax
mov eax, dword [rsp + 0x24]
imul eax, dword [rsp + 0x30]
cdqe
mov rcx, qword [rsp + 0x40]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x40], rax
movsxd rax, dword [rsp + 0x24]
mov rcx, qword [rsp + 0x68]
sub rcx, rax
mov rax, rcx
mov qword [rsp + 0x68], rax
jmp 0x18002244a
mov rax, qword [rsp + 0x40]
movzx eax, byte [rax]
mov byte [rsp + 0x20], al
mov eax, 1
imul rax, rax, 0
mov rcx, qword [rsp + 0x70]
movzx ecx, byte [rcx + rax]
call fcn.180007500
mov dword [rsp + 0x28], eax
mov eax, 1
imul rax, rax, 1
mov rcx, qword [rsp + 0x70]
movzx ecx, byte [rcx + rax]
call fcn.180007500
mov dword [rsp + 0x2c], eax
cmp dword [rsp + 0x28], 0
jge 0x1800225ac
movzx eax, byte [rsp + 0x20]
sar eax, 4
mov dword [rsp + 0x28], eax
cmp dword [rsp + 0x2c], 0
jge 0x1800225bf
movzx eax, byte [rsp + 0x20]
and eax, 0xf
mov dword [rsp + 0x2c], eax
mov eax, dword [rsp + 0x28]
shl eax, 4
or eax, dword [rsp + 0x2c]
movzx ecx, byte [rsp + 0x20]
xor eax, ecx
mov byte [rsp + 0x20], al
mov rax, qword [rsp + 0x70]
inc rax
mov qword [rsp + 0x70], rax
mov eax, dword [rsp + 0x78]
dec eax
mov dword [rsp + 0x78], eax
mov rax, qword [rsp + 0x68]
dec rax
mov qword [rsp + 0x68], rax
movsxd rax, dword [rsp + 0x30]
mov rcx, qword [rsp + 0x40]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x40], rax
jmp 0x18002244a
movzx eax, byte [rsp + 0x20]
test eax, eax
jne 0x180022626
mov dword [rsp + 0x38], 1
jmp 0x18002262e
mov dword [rsp + 0x38], 0
mov eax, dword [rsp + 0x38]
add rsp, 0x58
ret