Function at 0x140012580
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push r15
push r14
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x48
mov rbx, r8
mov rdi, rdx
mov rsi, rcx
mov ecx, dword [rsp + 0xa0]
test ecx, ecx
mov eax, 6
cmovns eax, ecx
movd r15d, xmm3
mov ecx, r15d
and ecx, 0x7fffff
lea edx, [rcx + rcx]
cmp r15d, 0x7fffff
ja 0x1400125ce
test ecx, ecx
mov r15d, 0xffffff82
cmove r15d, ecx
jmp 0x1400125dc
shr r15d, 0x17
or edx, 0x1000000
add r15d, 0xffffff81
mov ebp, r15d
neg ebp
cmovs ebp, r15d
mov rcx, rbx
sub rcx, rdi
mov r8d, eax
sub rcx, r8
jl 0x14001261e
xor r8d, r8d
cmp ebp, 0x64
setb r8b
xor r8, 3
cmp ebp, 0xa
mov r9d, 1
cmovae r9, r8
cmp eax, 1
sbb r9, 0
add r9, 4
cmp rcx, r9
jge 0x14001262d
mov qword [rsi], rbx
mov dword [rsi + 8], 0x84
jmp 0x140012831
shr r15d, 0x1f
add r15b, r15b
add r15b, 0x2b
cmp eax, 5
ja 0x1400126aa
lea r8d, [rax*4]
lea r9d, [rdx + rdx]
lea r10d, [rdx + rdx]
dec r10d
or r10d, edx
mov cl, 0x18
sub cl, r8b
mov r8d, 1
shl r8d, cl
and r10d, r9d
and r8d, r10d
add r8d, edx
mov ecx, r8d
shr ecx, 0x18
or cl, 0x30
mov byte [rdi], cl
test eax, eax
je 0x14001274b
mov byte [rdi + 1], 0x2e
mov edx, r8d
shr edx, 0x14
and edx, 0xf
lea rcx, str.0123456789abcdefghijklmnopqrstuvwxyz
movzx edx, byte [rdx + rcx]
mov byte [rdi + 2], dl
cmp eax, 1
jne 0x140012750
add rdi, 3
jmp 0x1400127b5
mov ecx, edx
shr ecx, 0x18
or cl, 0x30
mov byte [rdi], cl
mov byte [rdi + 1], 0x2e
mov r8d, edx
shr r8d, 0x14
and r8d, 0xf
lea rcx, str.0123456789abcdefghijklmnopqrstuvwxyz
movzx r8d, byte [r8 + rcx]
mov byte [rdi + 2], r8b
mov r8d, edx
shr r8d, 0x10
and r8d, 0xf
movzx r8d, byte [r8 + rcx]
mov byte [rdi + 3], r8b
mov r8d, edx
shr r8d, 0xc
and r8d, 0xf
movzx r8d, byte [r8 + rcx]
mov byte [rdi + 4], r8b
mov r8d, edx
shr r8d, 8
and r8d, 0xf
movzx r8d, byte [r8 + rcx]
mov byte [rdi + 5], r8b
mov r8d, edx
shr r8d, 4
and r8d, 0xf
movzx r8d, byte [r8 + rcx]
mov byte [rdi + 6], r8b
and edx, 0xf
movzx ecx, byte [rdx + rcx]
mov byte [rdi + 7], cl
add rdi, 8
add eax, 0xfffffffa
je 0x1400127b5
mov r14d, eax
mov rcx, rdi
mov dl, 0x30
mov r8, r14
call sub.VCRUNTIME140.dll_memset
add rdi, r14
jmp 0x1400127b5
inc rdi
jmp 0x1400127b5
mov edx, r8d
shr edx, 0x10
and edx, 0xf
movzx edx, byte [rdx + rcx]
mov byte [rdi + 3], dl
cmp eax, 2
jne 0x14001276b
add rdi, 4
jmp 0x1400127b5
mov edx, r8d
shr edx, 0xc
and edx, 0xf
movzx edx, byte [rdx + rcx]
mov byte [rdi + 4], dl
cmp eax, 3
jne 0x140012786
add rdi, 5
jmp 0x1400127b5
mov edx, r8d
shr edx, 8
and edx, 0xf
movzx edx, byte [rdx + rcx]
mov byte [rdi + 5], dl
cmp eax, 4
jne 0x1400127a1
add rdi, 6
jmp 0x1400127b5
shr r8d, 4
and r8d, 0xf
movzx eax, byte [r8 + rcx]
mov byte [rdi + 6], al
add rdi, 7
mov byte [rdi], 0x70
mov byte [rdi + 1], r15b
xor r14d, r14d
mov eax, 0xcccccccd
nop word cs:[rax + rax]
mov ecx, ebp
imul rcx, rax
shr rcx, 0x23
lea edx, [rcx + rcx]
lea edx, [rdx + rdx*4]
mov r8d, ebp
sub r8d, edx
or r8b, 0x30
mov byte [rsp + r14 + 0x3f], r8b
dec r14
cmp ebp, 9
mov ebp, ecx
ja 0x1400127d0
add rdi, 2
mov r8, r14
neg r8
mov rcx, rbx
sub rcx, rdi
mov eax, 0x84
cmp rcx, r8
jl 0x14001282b
lea rdx, [rsp + r14]
add rdx, 0x40
mov rcx, rdi
call sub.VCRUNTIME140.dll_memcpy
sub rdi, r14
xor eax, eax
mov rbx, rdi
mov qword [rsi], rbx
mov dword [rsi + 8], eax
mov rax, rsi
add rsp, 0x48
pop rbx
pop rbp
pop rdi
pop rsi
pop r14
pop r15
ret