Function at 0x616f91b0
Capabilities:
Encrypt data using rc4 prga
Resolve function by parsing pe exports

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x4a8
mov ebx, 0x100
mov ebp, 0x100
mov r15, qword [0x61766160]
mov r13, qword [rcx]
mov rax, qword [rcx + 0x18]
mov rcx, rbx
mov r8d, dword [r13 + 0x14]
cmp dword [r13 + 0x1c], 0x100
cmovbe ebp, dword [r13 + 0x1c]
mov qword [rsp + 0x30], rax
mov eax, r8d
mov r11d, r8d
mov edx, r8d
and eax, 0x21
lea r9, [rsp + 0xa0]
and r11d, 3
mov dword [rsp + 0x3c], 0
cmp eax, 0x21
mov dword [rsp + 0x38], eax
mov rdi, r9
mov al, 0xff
rep stosb byte [rdi], al
sete r14b
sete r10b
xor eax, eax
shr edx, 3
lea esi, [r11 + 1]
movzx r14d, r14b
movzx r10d, r10b
lea r9, [rsp + 0x1a0]
and edx, 2
mov rdi, r9
mov rbx, rcx
mov ecx, 0xc0
rep stosd dword [rdi], eax
xor eax, eax
cmp dword [rsp + 0x38], 0x21
mov rdi, r9
setne al
add r11, r11
cmp dword [rsp + 0x38], 0x21
cmovne rbx, r11
lea rax, [rax + rax*2]
mov r11d, edx
and r8d, 4
xor r11d, 2
mov qword [rsp + 0x58], rax
lea rax, [r14 + r14]
mov qword [rsp + 0x60], rax
lea eax, [r11 + r10]
add r10d, edx
movsxd r11, r11d
mov rcx, rax
add rax, rax
mov qword [rsp + 0x50], rbx
lea rbx, [r10 + r10]
mov qword [rsp + 0x68], rax
lea rax, [r14 + 1]
movsxd rcx, ecx
movsxd rdx, edx
mov qword [rsp + 0x40], rax
lea rax, [r14 + r14]
add rax, 2
mov qword [rsp + 0x70], rbx
lea rbx, [r11 + r11]
xor r11d, r11d
mov qword [rsp + 0x48], rax
mov rax, r10
cdqe
mov dword [rsp + 0x8c], r8d
mov qword [rsp + 0x98], rax
mov eax, esi
and eax, 1
mov qword [rsp + 0x90], rcx
mov dword [rsp + 0x88], eax
mov qword [rsp + 0x78], rbx
lea rbx, [rdx + rdx]
mov qword [rsp + 0x80], rbx
xor ebx, ebx
cmp ebp, r11d
jle 0x616f9568
cmp dword [rsp + 0x8c], 0
mov r10d, dword [rsp + 0x3c]
lea r9d, [r11 + 1]
je 0x616f94d8
mov r8d, dword [rsp + 0x88]
add r10, r10
add r10, qword [rsp + 0x30]
test r8d, r8d
je 0x616f9435
cmp esi, 2
jbe 0x616f93f8
mov rax, qword [rsp + 0x78]
mov rcx, qword [0x61766170]
movzx eax, word [r10 + rax]
imul eax, eax, 0xff
mov edx, eax
and eax, 0x7fff
sar edx, 0xf
movsxd rdx, edx
movzx ecx, byte [rcx + rdx]
movzx edx, word [r15 + rdx*2]
imul eax, ecx
mov rcx, qword [0x61766170]
sar eax, 0xc
add eax, edx
mov byte [rdi + 2], ah
movzx eax, word [r10 + 2]
imul eax, eax, 0xff
mov edx, eax
and eax, 0x7fff
sar edx, 0xf
movsxd rdx, edx
movzx ecx, byte [rcx + rdx]
movzx edx, word [r15 + rdx*2]
imul eax, ecx
mov rcx, qword [0x61766170]
sar eax, 0xc
add eax, edx
mov byte [rdi + 1], ah
mov rax, qword [rsp + 0x80]
movzx eax, word [r10 + rax]
imul eax, eax, 0xff
mov edx, eax
and eax, 0x7fff
sar edx, 0xf
movsxd rdx, edx
movzx ecx, byte [rcx + rdx]
movzx edx, word [r15 + rdx*2]
imul eax, ecx
sar eax, 0xc
add eax, edx
movzx eax, ah
jmp 0x616f9548
movzx eax, word [r10]
mov rcx, qword [0x61766170]
imul eax, eax, 0xff
mov edx, eax
and eax, 0x7fff
sar edx, 0xf
movsxd rdx, edx
movzx ecx, byte [rcx + rdx]
imul eax, ecx
mov rcx, qword [0x61766160]
movzx edx, word [rcx + rdx*2]
sar eax, 0xc
add eax, edx
sar eax, 8
jmp 0x616f9550
mov rax, qword [rsp + 0x50]
movzx r12d, word [r10 + rax]
imul ecx, r12d, 0xff
mov eax, r12d
add ecx, 0x807f
shr ecx, 0x10
lea edx, [rcx - 1]
cmp dl, 0xfd
ja 0x616f946c
shr ax, 1
movzx eax, ax
add eax, 0x7f7f8080
cdq
idiv r12d
mov r8d, eax
cmp ecx, 0xff
mov byte [rsp + r11 + 0xa0], cl
cmovne ebx, r9d
cmp esi, 2
jbe 0x616f94c4
mov rax, qword [rsp + 0x68]
mov edx, r12d
movzx ecx, word [r10 + rax]
call fcn.617008e0
mov edx, r12d
mov byte [rdi + 2], al
mov rax, qword [rsp + 0x48]
movzx ecx, word [r10 + rax]
call fcn.617008e0
mov edx, r12d
mov byte [rdi + 1], al
mov rax, qword [rsp + 0x70]
movzx ecx, word [r10 + rax]
call fcn.617008e0
jmp 0x616f9548
mov rax, qword [rsp + 0x60]
mov edx, r12d
movzx ecx, word [r10 + rax]
call fcn.617008e0
jmp 0x616f9550
add r10, qword [rsp + 0x30]
cmp esi, 3
je 0x616f9521
cmp esi, 4
je 0x616f950a
cmp esi, 2
jne 0x616f954c
xor eax, eax
cmp dword [rsp + 0x38], 0x21
setne al
mov al, byte [r10 + rax]
mov byte [rsp + r11 + 0xa0], al
inc al
cmovne ebx, r9d
jmp 0x616f954c
mov rax, qword [rsp + 0x58]
mov al, byte [r10 + rax]
mov byte [rsp + r11 + 0xa0], al
inc al
cmovne ebx, r9d
mov rax, qword [rsp + 0x90]
mov al, byte [r10 + rax]
mov byte [rdi + 2], al
mov rax, qword [rsp + 0x40]
mov al, byte [r10 + rax]
mov byte [rdi + 1], al
mov rax, qword [rsp + 0x98]
mov al, byte [r10 + rax]
mov byte [rdi], al
jmp 0x616f9558
mov al, byte [r10 + r14]
mov byte [rdi + 1], al
mov byte [rdi], al
mov byte [rdi + 2], al
add dword [rsp + 0x3c], esi
inc r11
add rdi, 3
jmp 0x616f930b
mov rax, qword [r13]
mov r9d, ebp
lea r8, [rsp + 0x1a0]
mov rdx, qword [rax + 8]
mov rcx, qword [rax]
call fcn.616fd370
test ebx, ebx
je 0x616f95ab
mov rax, qword [r13]
mov r9d, ebx
lea r8, [rsp + 0xa0]
mov rdx, qword [rax + 8]
mov qword [rsp + 0x20], 0
mov rcx, qword [rax]
call fcn.616ffe40
mov dword [r13 + 0x1c], ebp
add rsp, 0x4a8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret