Function at 0x140005c95
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x58
mov r15d, r9d
mov rsi, r8
mov qword [rsp + 0x50], rdx
mov rbx, rcx
mov rbp, qword [rsp + 0xc8]
mov rax, qword [rsp + 0xc0]
mov qword [rsp + 0x48], rax
mov rax, qword [rcx + 0x38]
mov ecx, dword [rax + 0xd4]
mov edx, dword [rax + 0xf4]
mov qword [rsp + 0x38], rbx
call qword [rbx + 0x90]
mov rbx, rax
mov r12, rax
lea rdx, [rbp + 0xe8]
mov rcx, rax
mov r8d, 4
call fcn.140004af5
mov rcx, rbx
call fcn.140005375
mov eax, eax
add rax, rbx
xor ecx, ecx
nop dword [rax + rax]
movzx edx, byte [rbp + rcx + 0x84]
mov byte [rax + rcx], dl
inc rcx
cmp rcx, 4
jne 0x140005d15
mov byte [r12 + 8], 0x25
mov rcx, r12
call fcn.140005375
movsxd rdi, eax
lea r13, [rbx + rdi]
inc r13
mov rcx, r12
call fcn.140005375
test eax, eax
je 0x140005d7a
add rbx, rdi
mov eax, eax
dec rax
mov rcx, rax
nop word cs:[rax + rax]
movsx edx, byte [r12 + rax + 1]
mov word [rbx + rax*2 + 3], dx
dec rcx
test eax, eax
mov rax, rcx
jne 0x140005d65
movsx eax, byte [r12]
mov word [r13], ax
mov rcx, r13
mov rdx, rsi
mov r8d, 0x104
mov rdi, qword [rsp + 0x38]
call qword [rdi + 0x70]
mov rax, qword [rdi + 0x38]
mov ecx, dword [rax + 0xd4]
mov edx, dword [rax + 0xf4]
call qword [rdi + 0x90]
mov r14, rax
mov rax, qword [rdi + 0x38]
mov ecx, dword [rax + 0xd4]
mov edx, dword [rax + 0xf4]
call qword [rdi + 0x90]
mov r13, rax
mov dword [rsp + 0x44], 0
mov r9d, dword [rbp + 0x104]
mov qword [rsp + 0x20], rbp
lea r8, [rsp + 0x44]
mov rdi, qword [rsp + 0x50]
mov rcx, rdi
mov rdx, rax
call fcn.140005b75
mov eax, 0xffffffff
nop word cs:[rax + rax]
inc eax
cmp word [rsi + rax*2], 0
jne 0x140005e05
lea ecx, [rax - 1]
xor r8d, r8d
cmp word [rsi + rcx*2], 0x5c
je 0x140005e29
mov ecx, eax
mov word [rsi + rcx*2], 0x5c
mov r8d, 1
test r13, r13
je 0x140005e61
movzx ecx, word [r13]
test cx, cx
je 0x140005e67
lea ebx, [r8 + rax]
xor edx, edx
nop dword [rax]
lea edi, [rbx + rdx]
mov word [rsi + rdi*2], cx
movzx ecx, word [r13 + rdx*2 + 2]
inc rdx
test cx, cx
jne 0x140005e45
mov rdi, qword [rsp + 0x50]
jmp 0x140005e69
inc eax
mov edx, eax
jmp 0x140005e6e
xor edx, edx
add edx, r8d
add edx, eax
mov eax, edx
mov word [rsi + rax*2], 0
mov rcx, rsi
xor edx, edx
mov rax, qword [rsp + 0x38]
call qword [rax + 0x88]
mov dword [rsp + 0x34], 0
xor r15d, dword [rbp + 0x104]
mov qword [rsp + 0x20], rbp
lea r8, [rsp + 0x34]
mov rcx, rdi
mov rdx, r14
mov r9d, r15d
call fcn.140005b75
mov eax, 0xffffffff
nop dword [rax]
inc eax
cmp word [rsi + rax*2], 0
jne 0x140005eb5
lea edx, [rax - 1]
xor ecx, ecx
cmp word [rsi + rdx*2], 0x5c
je 0x140005ed7
mov ecx, eax
mov word [rsi + rcx*2], 0x5c
mov ecx, 1
test r14, r14
je 0x140005f0c
movzx ebp, word [r14]
test bp, bp
je 0x140005f26
lea ebx, [rcx + rax]
xor edx, edx
nop word cs:[rax + rax]
lea edi, [rbx + rdx]
mov word [rsi + rdi*2], bp
movzx ebp, word [r14 + rdx*2 + 2]
inc rdx
test bp, bp
jne 0x140005ef5
jmp 0x140005f28
inc eax
mov eax, eax
mov word [rsi + rax*2], 0
mov eax, dword [rsp + 0x34]
mov rcx, qword [rsp + 0x48]
mov dword [rcx], eax
mov r14, r12
jmp 0x140005f4d
xor edx, edx
add edx, ecx
add edx, eax
mov word [rsi + rdx*2], 0
mov eax, dword [rsp + 0x34]
mov rcx, qword [rsp + 0x48]
mov dword [rcx], eax
mov rcx, r12
mov rax, qword [rsp + 0x38]
call qword [rax + 0x58]
test r14, r14
je 0x140005f58
mov rcx, r14
mov rax, qword [rsp + 0x38]
call qword [rax + 0x58]
test r13, r13
je 0x140005f79
mov rcx, r13
mov rax, qword [rsp + 0x38]
add rsp, 0x58
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
jmp qword [rax + 0x58]
nop
add rsp, 0x58
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret