Function at 0x18005fdd0
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push rbp
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbx
sub rsp, 0x68
in al, dx
push 0x246c8d48
insb byte [rdi], dx
and al, 0x60
mov rsi, r8
mov rdi, rdx
mov qword [rbp - 0x38], rcx
enter 0x148, 0xffffffffffffffd6
mov qword [rbp - 0x30], rdx
mov qword [rbp - 0x28], rsi
mov byte [rbp - 0x20], 0x81
mov byte [rbp - 0x14], 0x81
movzx r15d, byte [rbp - 0x16]
movzx r13d, byte [rbp - 0x15]
movzx r12d, byte [rbp - 0x1f]
mov bl, 0x81
or dword [rbx + rcx*4 + 0x75], 0xd8d4ce2
jg 0x18005fe20
jg 0x18005fe20
invalid
jmp 0x18005fe40
mov r14d, r14d
shl r14, 0x10
mov r13b, 2
xor r15d, r15d
cmp bl, 0x81
je 0x18005fe5c
movzx eax, bl
cmp eax, 0x80
add byte [rax], al
invalid
je 0x18006003d
cmp r15b, r13b
jb 0x180060066
test rdi, rdi
je 0x180060099
cmp rdi, rsi
je 0x180060099
movzx edx, byte [rdi]
movzx r14d, dl
test r14b, r14b
js 0x18005fea0
invalid
inc rdi
cmp r14d, 0x27
ja 0x18005ff14
invalid
lea eax, [rax]
add byte [rax], al
mov bl, 0x5c
mov eax, r14d
movsxd rax, dword [r9 + rax*4]
add rax, r9
invalid
jmp rax
mov eax, r14d
and eax, 0x1f
movzx r8d, byte [rdi + 1]
add dword [rcx - 0x7d], eax
loopne case.0x18005e0b7.41
cmp r14b, 0xdf
jbe 0x18005fefd
movzx ecx, byte [rdi + 2]
shl r8d, 6
and ecx, 0x3f
or ecx, r8d
cmp dl, 0xf0
jb 0x18005ff76
movzx r14d, byte [rdi + 3]
and eax, 7
loopne 0x18005fedb
shl eax, 0x12
shl ecx, 6
and r14d, 0x3f
or r14d, ecx
or r14d, eax
or esi, eax
cmp r14d, 0x110000
je 0x180060099
add dword [rax], eax
invalid
add rdi, 4
cmp r14d, 0x27
jbe 0x18005fe87
jmp 0x18005ff14
add rdi, 2
shl eax, 6
or eax, r8d
mov r14d, eax
cmp r14d, 0x27
jbe 0x18005fe87
cmp r14d, 0x5c
jne 0x18005ff27
mov r12b, 0x5c
xor r14d, r14d
xor esi, esi
mov bl, 0x5c
jmp 0x18005fe33
invalid
cmp r14d, 0x2ff
jbe 0x18005ff3c
mov ecx, r14d
call fcn.180073c70
add dword [rax], eax
test al, al
jne 0x18005ff8e
mov ecx, r14d
call fcn.180072690
add dword [rax], eax
mov bl, 0x80
test al, al
je 0x18005ff8e
lea r9, [0x180097d44]
jmp 0x18005fe33
invalid
invalid
invalid
invalid
add rdi, 3
shl eax, 0xc
or ecx, eax
mov r14d, ecx
cmp r14d, 0x27
jbe 0x18005fe87
jmp 0x18005ff14
mov eax, r14d
or eax, 1
bsr eax, eax
xor eax, 0x1c
shr eax, 2
lea r15, [rax - 2]
mov byte [rbp], 0
mov word [rbp - 2], 0
mov ecx, r14d
shr ecx, 0x14
lea rdx, str.0123456789abcdef
movzx ecx, byte [rcx + rdx]
mov byte [rbp + 1], cl
mov ecx, r14d
shr ecx, 0x10
and ecx, 0xf
movzx ecx, byte [rcx + rdx]
mov byte [rbp + 2], cl
mov ecx, r14d
shr ecx, 0xc
and ecx, 0xf
movzx ecx, byte [rcx + rdx]
mov byte [rbp + 3], cl
mov ecx, r14d
shr ecx, 8
and ecx, 0xf
movzx ecx, byte [rcx + rdx]
mov byte [rbp + 4], cl
mov ecx, r14d
shr ecx, 4
and ecx, 0xf
movzx ecx, byte [rcx + rdx]
mov byte [rbp + 5], cl
and r14d, 0xf
movzx ecx, byte [r14 + rdx]
mov byte [rbp + 6], cl
mov byte [rbp + 7], 0x7d
mov word [rbp + rax - 4], 0x755c
mov byte [rbp + rax - 2], 0x7b
movzx ebx, byte [rbp - 2]
movzx r12d, byte [rbp - 1]
mov r14, qword [rbp]
mov r13b, 0xa
cmp bl, 0x81
lea r9, [0x180097d44]
jne 0x18005fe40
jmp 0x180060099
shr r14, 0x10
mov edx, r14d
lea rax, [rbp - 0x20]
mov dword [rax + 8], 0
mov qword [rax], 0
xor r14d, r14d
xor r12d, r12d
xor r13d, r13d
xor r15d, r15d
xor ebx, ebx
jmp 0x18006007d
mov byte [rbp - 0x20], bl
mov byte [rbp - 0x1f], r12b
mov qword [rbp - 0x1e], r14
movzx eax, r15b
inc r15b
movzx edx, byte [rbp + rax - 0x20]
mov rcx, qword [rbp - 0x38]
call fcn.1800701a0
test al, al
lea r9, [0x180097d44]
je 0x18005fe40
mov al, 1
jmp 0x18006009b
xor eax, eax
add rsp, 0x68
pop rbx
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
pop rbp
ret