Function at 0x496020
Capabilities:
Encrypt data using rc4 prga

Disassembly:
mov rcx, qword gs:[0x28]
mov rcx, qword [rcx]
cmp rsp, qword [rcx + 0x10]
jbe 0x4963d5
sub rsp, 0x60
mov qword [rsp + 0x58], rbp
lea rbp, [rsp + 0x58]
mov rdx, qword [rsp + 0x68]
mov rbx, qword [rsp + 0x70]
xor eax, eax
xor ecx, ecx
xor esi, esi
xor edi, edi
xor r8d, r8d
jmp 0x496080
dec rbx
mov r10, rbx
neg rbx
sar rbx, 0x3f
and rbx, 1
add rdx, rbx
mov rbx, r10
mov rax, r9
nop dword [rax]
test rbx, rbx
jle 0x496376
mov qword [rsp + 0x70], rbx
mov qword [rsp + 0x68], rdx
mov byte [rsp + 0x46], r8b
movzx r9d, byte [rdx]
mov byte [rsp + 0x47], r9b
cmp r9b, 0x20
jbe 0x4962e4
cmp r9b, 0x22
je 0x496165
cmp r9b, 0x5c
jne 0x4960cb
lea r9, [rax + 1]
nop
cmp rbx, 1
jae 0x49605f
jmp 0x4963c7
mov qword [rsp], rdi
mov qword [rsp + 8], rsi
mov qword [rsp + 0x10], rcx
mov qword [rsp + 0x18], rax
nop
call fcn.00495f40
mov rax, qword [rsp + 0x28]
mov rcx, qword [rsp + 0x30]
mov rdx, qword [rsp + 0x20]
lea rbx, [rax + 1]
cmp rbx, rcx
ja 0x496122
movzx r10d, byte [rsp + 0x47]
mov byte [rdx + rax], r10b
mov rsi, rbx
xor r9d, r9d
mov rdi, rdx
movzx r8d, byte [rsp + 0x46]
mov rbx, qword [rsp + 0x70]
mov rdx, qword [rsp + 0x68]
jmp 0x4960c0
mov qword [rsp + 0x50], rax
lea rsi, [0x004d33c0]
mov qword [rsp], rsi
mov qword [rsp + 8], rdx
mov qword [rsp + 0x10], rax
mov qword [rsp + 0x18], rcx
mov qword [rsp + 0x20], rbx
call fcn.0044a9a0
mov rdx, qword [rsp + 0x28]
mov rax, qword [rsp + 0x30]
mov rcx, qword [rsp + 0x38]
lea rbx, [rax + 1]
mov rax, qword [rsp + 0x50]
jmp 0x4960fd
mov qword [rsp + 0x48], rax
mov qword [rsp], rdi
mov qword [rsp + 8], rsi
mov qword [rsp + 0x10], rcx
mov rcx, rax
shr rax, 0x3f
add rax, rcx
sar rax, 1
mov qword [rsp + 0x18], rax
call fcn.00495f40
mov rax, qword [rsp + 0x28]
mov qword [rsp + 0x50], rax
mov rcx, qword [rsp + 0x30]
mov rdx, qword [rsp + 0x20]
mov rbx, qword [rsp + 0x48]
bt ebx, 0
jb 0x49627a
movzx ebx, byte [rsp + 0x46]
test bl, bl
je 0x49626e
mov rsi, qword [rsp + 0x70]
cmp rsi, 1
jle 0x496267
mov rdi, qword [rsp + 0x68]
cmp byte [rdi + 1], 0x22
jne 0x496262
lea r8, [rax + 1]
cmp r8, rcx
ja 0x496215
movzx r9d, byte [rsp + 0x47]
mov byte [rdx + rax], r9b
inc rdi
dec rsi
xor ebx, 1
xor r9d, r9d
mov eax, ebx
mov rbx, rsi
mov rsi, r8
mov r8d, eax
mov r10, rdx
mov rdx, rdi
mov rdi, r10
jmp 0x4960c0
lea rbx, [0x004d33c0]
mov qword [rsp], rbx
mov qword [rsp + 8], rdx
mov qword [rsp + 0x10], rax
mov qword [rsp + 0x18], rcx
mov qword [rsp + 0x20], r8
call fcn.0044a9a0
mov rdx, qword [rsp + 0x28]
mov rax, qword [rsp + 0x30]
mov rcx, qword [rsp + 0x38]
lea r8, [rax + 1]
mov rax, qword [rsp + 0x50]
movzx ebx, byte [rsp + 0x46]
mov rsi, qword [rsp + 0x70]
mov rdi, qword [rsp + 0x68]
jmp 0x4961e6
mov r8, rax
jmp 0x4961f6
mov rdi, qword [rsp + 0x68]
jmp 0x496262
mov rsi, qword [rsp + 0x70]
mov rdi, qword [rsp + 0x68]
jmp 0x496262
lea rbx, [rax + 1]
nop
cmp rbx, rcx
ja 0x4962a6
movzx r9d, byte [rsp + 0x47]
mov byte [rdx + rax], r9b
mov rsi, qword [rsp + 0x70]
mov rdi, qword [rsp + 0x68]
mov r8, rbx
movzx ebx, byte [rsp + 0x46]
jmp 0x4961f9
lea rsi, [0x004d33c0]
mov qword [rsp], rsi
mov qword [rsp + 8], rdx
mov qword [rsp + 0x10], rax
mov qword [rsp + 0x18], rcx
mov qword [rsp + 0x20], rbx
call fcn.0044a9a0
mov rdx, qword [rsp + 0x28]
mov rax, qword [rsp + 0x30]
mov rcx, qword [rsp + 0x38]
lea rbx, [rax + 1]
mov rax, qword [rsp + 0x50]
jmp 0x496285
cmp r9b, 9
jne 0x496367
test r8b, r8b
jne 0x4960cb
mov qword [rsp], rdi
mov qword [rsp + 8], rsi
mov qword [rsp + 0x10], rcx
mov qword [rsp + 0x18], rax
call fcn.00495f40
mov rax, qword [rsp + 0x20]
mov rcx, qword [rsp + 0x28]
mov rdx, qword [rsp + 0x30]
mov qword [rsp + 0x78], rax
mov qword [rsp + 0x80], rcx
mov qword [rsp + 0x88], rdx
mov rax, qword [rsp + 0x70]
dec rax
mov rcx, rax
neg rax
sar rax, 0x3f
and rax, 1
mov rdx, qword [rsp + 0x68]
add rax, rdx
mov qword [rsp + 0x90], rax
mov qword [rsp + 0x98], rcx
mov rbp, qword [rsp + 0x58]
add rsp, 0x60
ret
cmp r9b, 0x20
je 0x4962ea
jmp 0x4960cb
mov qword [rsp], rdi
mov qword [rsp + 8], rsi
mov qword [rsp + 0x10], rcx
mov qword [rsp + 0x18], rax
call fcn.00495f40
mov rax, qword [rsp + 0x20]
mov rcx, qword [rsp + 0x28]
mov rdx, qword [rsp + 0x30]
mov qword [rsp + 0x78], rax
mov qword [rsp + 0x80], rcx
mov qword [rsp + 0x88], rdx
xorps xmm0, xmm0
movups xmmword [rsp + 0x90], xmm0
mov rbp, qword [rsp + 0x58]
add rsp, 0x60
ret
mov eax, 1
mov rcx, rbx
call fcn.00466b80
nop
call fcn.004649c0
jmp fcn.00496020