Function at 0x6016c4
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffc8
push ebx
xor ebx, ebx
mov dword [ebp - 0x38], ebx
mov dword [ebp - 0x34], ebx
mov dword [ebp - 0x14], ebx
mov byte [ebp - 9], cl
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
lea eax, [ebp - 4]
call fcn.00405880
mov eax, dword [ebp - 8]
call fcn.00404fa4
xor eax, eax
push ebp
push 0x601a2c
push dword fs:[eax]
mov dword fs:[eax], esp
mov byte [ebp - 0xa], 0
mov eax, dword [ebp - 4]
call fcn.004054d8
mov ecx, 0x50
cdq
idiv ecx
mov dword [ebp - 0x28], edx
cmp dword [ebp - 0x28], 0
je 0x60175c
mov eax, dword [ebp - 4]
call fcn.004054d8
mov ecx, 0x50
cdq
idiv ecx
mov eax, 0x50
sub eax, edx
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 0x24]
dec eax
test eax, eax
jl 0x60175c
inc eax
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x20], 0
lea eax, [ebp - 4]
mov edx, 0x601a40
call fcn.004054e4
inc dword [ebp - 0x20]
dec dword [ebp - 0x2c]
jne 0x601747
mov eax, dword [0x668f00]
xor ecx, ecx
mov edx, 0x320
call fcn.00408374
mov eax, dword [0x668f00]
mov byte [eax], 0x65
mov eax, dword [0x668f00]
mov byte [eax + 1], 0
mov eax, dword [0x668f00]
mov byte [eax + 2], 0xc
mov eax, dword [0x668f00]
mov byte [eax + 3], 0x32
mov eax, dword [0x668f00]
mov byte [eax + 4], 0
mov eax, dword [0x668f00]
mov byte [eax + 5], 0
mov eax, dword [0x668f00]
mov byte [eax + 6], 0
mov eax, dword [0x668f00]
mov byte [eax + 7], 0
mov eax, dword [0x668f00]
mov byte [eax + 8], 0
mov eax, dword [0x668f00]
mov byte [eax + 9], 0x5d
mov eax, dword [0x668f00]
mov byte [eax + 0xa], 1
mov eax, dword [0x668f00]
mov byte [eax + 0xb], 0x27
mov eax, dword [0x668f00]
mov byte [eax + 0xc], 0x2d
mov dword [ebp - 0x10], 0xd
mov eax, dword [0x668f00]
mov edx, dword [ebp - 0x10]
mov byte [eax + edx], 0xff
inc dword [ebp - 0x10]
cmp dword [ebp - 0x10], 0x21
jne 0x6017e8
mov dword [ebp - 0x10], 0x21
mov eax, dword [0x668f00]
mov edx, dword [ebp - 0x10]
mov byte [eax + edx], 0
inc dword [ebp - 0x10]
cmp dword [ebp - 0x10], 0x2d
jne 0x601804
mov eax, dword [ebp - 8]
call fcn.00404db4
test eax, eax
jl 0x60184e
inc eax
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x10], 0
mov eax, dword [ebp - 8]
mov edx, dword [ebp - 0x10]
mov al, byte [eax + edx]
mov edx, dword [0x668f00]
mov ecx, dword [ebp - 0x10]
mov byte [edx + ecx + 0x21], al
inc dword [ebp - 0x10]
dec dword [ebp - 0x2c]
jne 0x601830
mov eax, dword [0x668f00]
mov dl, byte [ebp - 9]
mov byte [eax + 0x2d], dl
mov al, byte [ebp - 9]
sub al, 1
jb 0x601864
je 0x60188d
jmp 0x601896
mov eax, dword [0x66a1cc]
mov eax, dword [eax]
mov edx, 0x601a4c
call fcn.00404f00
jne 0x601882
mov eax, dword [0x668f00]
mov byte [eax + 0x2e], 3
jmp 0x601896
mov eax, dword [0x668f00]
mov byte [eax + 0x2e], 0
jmp 0x601896
mov eax, dword [0x668f00]
mov byte [eax + 0x2e], 0
mov eax, dword [0x668f00]
mov byte [eax + 0x2f], 0
mov eax, dword [ebp - 4]
call fcn.004054d8
sar eax, 1
jns 0x6018ae
adc eax, 0
push eax
lea eax, [ebp - 0x14]
mov ecx, 1
mov edx, dword [0x6016a4]
call fcn.004063ac
add esp, 4
lea eax, [ebp - 0x34]
mov edx, dword [ebp - 4]
call fcn.00404d7c
mov eax, dword [ebp - 0x34]
mov edx, dword [ebp - 0x14]
call fcn.0049b78c
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x14]
mov edx, dword [ebp - 0x1c]
call fcn.00623384
mov word [ebp - 0x16], ax
mov eax, dword [0x668f00]
add eax, 0x30
mov dx, word [ebp - 0x16]
mov word [eax], dx
mov eax, dword [0x668f00]
add eax, 0x32
mov edx, dword [ebp - 0x1c]
mov dword [eax], edx
mov eax, dword [0x668f00]
add eax, 0x32
call fcn.0049b538
mov eax, dword [0x668f00]
mov byte [eax + 0x36], 0xff
mov eax, dword [0x668f00]
mov byte [eax + 0x37], 0xff
mov eax, dword [0x668f00]
mov byte [eax + 0x38], 0xff
mov eax, dword [0x668f00]
mov byte [eax + 0x39], 0xff
mov eax, dword [0x668f00]
mov edx, 0x3a
call fcn.005d5aa8
mov edx, dword [0x668f00]
mov byte [edx + 0x3a], al
lea eax, [ebp - 0x38]
mov edx, dword [ebp - 4]
call fcn.00404d7c
mov eax, dword [ebp - 0x38]
mov edx, dword [0x668f00]
add edx, 0x3b
call fcn.0049b78c
mov eax, dword [ebp - 0x1c]
test eax, eax
jns 0x60197a
add eax, 0xffff
sar eax, 0x10
mov edx, dword [0x668f00]
mov byte [edx + 4], al
mov eax, dword [ebp - 0x1c]
test eax, eax
jns 0x601992
add eax, 0xff
sar eax, 8
mov edx, dword [0x668f00]
mov byte [edx + 5], al
mov eax, dword [ebp - 0x1c]
and eax, 0x800000ff
jns 0x6019af
dec eax
or eax, 0xffffff00
inc eax
mov edx, dword [0x668f00]
mov byte [edx + 6], al
mov eax, dword [0x6697dc]
push eax
push 7
mov ecx, dword [ebp - 0x1c]
add ecx, 0x3b
mov edx, dword [0x668f00]
mov eax, 0x5dc
call fcn.005f68b4
mov eax, dword [0x6697dc]
cmp byte [eax + 5], 0xf0
jbe 0x6019e5
mov byte [ebp - 0xa], 1
xor eax, eax
call fcn.0060136c
xor eax, eax
call fcn.0060136c
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x601a33
lea eax, [ebp - 0x38]
mov edx, 2
call fcn.00404b08
lea eax, [ebp - 0x14]
mov edx, dword [0x6016a4]
call fcn.004064cc
lea eax, [ebp - 8]
call fcn.00404ae4
lea eax, [ebp - 4]
call fcn.0040529c
ret