Function at 0x4a6590
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x5c
push esi
xor ecx, ecx
push edi
xorps xmm0, xmm0
mov dword [ebp - 8], ecx
xor esi, esi
movzx eax, byte [ecx + 0x6e6024]
movd xmm1, eax
movzx eax, byte [ecx + 0x6e6033]
cvtdq2ps xmm1, xmm1
inc ecx
addss xmm1, xmm0
movd xmm0, eax
cvtdq2ps xmm0, xmm0
addss xmm1, xmm0
movaps xmm0, xmm1
cmp ecx, 0xf
jl 0x4a65a2
mulss xmm0, dword [0x62979c]
xor ecx, ecx
cvttss2si edx, xmm0
lea ecx, [ecx]
cmp byte [ecx + 0x6e618c], 1
movsx eax, byte [ecx + 0x6e6100]
jne 0x4a65fa
mov dword [ebp + ecx*4 - 0x5c], 0
jmp 0x4a6621
test eax, eax
jne 0x4a6606
add esi, edx
mov dword [ebp + ecx*4 - 0x5c], edx
jmp 0x4a6621
cmp eax, 1
jne 0x4a6614
movzx eax, byte [ecx + 0x6e6024]
jmp 0x4a661b
movzx eax, byte [ecx + 0x6e6033]
mov dword [ebp + ecx*4 - 0x5c], eax
add esi, eax
inc ecx
cmp ecx, 0xf
jl 0x4a65e0
movd xmm0, esi
cvtdq2ps xmm0, xmm0
mov ecx, 1
comiss xmm0, dword [0x62f664]
jbe 0x4a6643
mov esi, 0x87
jmp 0x4a6648
test esi, esi
cmovle esi, ecx
mov eax, 0x384
cdq
idiv esi
mov dword [0x7407b4], esi
mov dword [ebp - 0x1c], eax
mov eax, 0x66666667
imul esi
sar edx, 3
mov eax, edx
shr eax, 0x1f
add eax, edx
cmove eax, ecx
mov dword [ebp - 0x20], eax
lea eax, [esi + esi*2]
shl eax, 2
push eax
call fcn.004d3100
mov esi, dword [0x7407b4]
mov edi, eax
lea ecx, [esi + esi*2]
shl ecx, 2
push ecx
push 0
push edi
mov dword [0x7407a0], edi
call fcn.005c8040
add esp, 0x10
test esi, esi
jle 0x4a66af
mov eax, edi
mov ecx, esi
mov word [eax], 0x3ff
lea eax, [eax + 0xc]
dec ecx
jne 0x4a66a4
push ebx
xor ebx, ebx
mov dword [ebp - 4], ebx
jmp 0x4a66c0
cmp byte [ebx + 0x6e618c], 1
je 0x4a681a
movsx eax, byte [ebx + 0x6e6100]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp + ebx*4 - 0x5c]
mov dword [ebp - 0xc], eax
test eax, eax
jle 0x4a681a
call fcn.004b94b0
mov esi, dword [0x7407b4]
xor edx, edx
div esi
mov ecx, dword [0x7407a0]
lea eax, [edx + edx*2]
cmp byte [ecx + eax*4], 0xff
je 0x4a6735
inc edx
lea eax, [esi - 1]
xor edi, edi
cmp edx, eax
cmovge edx, edi
lea eax, [edx + edx*2]
cmp byte [ecx + eax*4], 0xff
je 0x4a6732
or ebx, 0xffffffff
jmp 0x4a6720
cmp edx, esi
cmovge edx, ebx
inc edx
lea eax, [edx + edx*2]
cmp byte [ecx + eax*4], 0xff
jne 0x4a6720
mov ebx, dword [ebp - 4]
lea eax, [edx + edx*2]
mov edi, dword [ebp - 0x10]
mov byte [ecx + eax*4], bl
test edi, edi
jne 0x4a6766
lea esi, [edx + edx*2]
mov word [ecx + esi*4 + 1], 0xff02
call fcn.004b94b0
xor edx, edx
mov ecx, 0xf
div ecx
mov edi, dword [0x7407a0]
mov byte [edi + esi*4 + 4], dl
jmp 0x4a680b
cmp edi, 1
jne 0x4a678f
lea esi, [edx + edx*2]
mov word [ecx + esi*4 + 1], 0xff01
call fcn.004b94b0
xor edx, edx
mov ecx, 0xa
div ecx
mov edi, dword [0x7407a0]
mov byte [edi + esi*4 + 4], dl
jmp 0x4a680b
lea eax, [edx + edx*2]
shl eax, 2
mov dword [ebp - 0x14], eax
mov byte [eax + ecx + 1], 0
mov byte [eax + ecx + 4], 0xff
call fcn.004b94b0
xor edx, edx
mov ecx, 0x64
div ecx
lea eax, [edi - 2]
push eax
xor esi, esi
mov ebx, edx
call fcn.0046e870
mov edx, eax
add esp, 4
mov dword [ebp - 0x18], edx
xor edi, edi
lea ecx, [edx + 0xc]
lea ebx, [ebx]
cmp esi, ebx
jg 0x4a67dc
mov eax, dword [ecx]
add eax, esi
cmp ebx, eax
jl 0x4a67e7
add esi, dword [ecx]
inc edi
add ecx, 0xc
cmp edi, 0xa
jl 0x4a67d0
mov ebx, dword [ebp - 4]
lea ecx, [edi + edi*2]
mov edi, dword [0x7407a0]
movzx eax, byte [edx + ecx*4 + 4]
mov edx, dword [ebp - 0x14]
mov byte [edx + edi + 2], al
mov eax, dword [ebp - 0x18]
movzx eax, byte [eax + ecx*4 + 8]
mov byte [edx + edi + 3], al
dec dword [ebp - 0xc]
jne 0x4a66e6
mov esi, dword [0x7407b4]
inc ebx
mov dword [ebp - 4], ebx
cmp ebx, 0xf
jl 0x4a66c0
test esi, esi
jle 0x4a683f
mov ebx, dword [ebp - 0x1c]
mov eax, ebx
lea ecx, [edi + 8]
mov edx, esi
mov dword [ecx], eax
add eax, ebx
add ecx, 0xc
dec edx
jne 0x4a6835
xor eax, eax
pop ebx
test esi, esi
jle 0x4a687b
mov edx, dword [ebp - 0x20]
add edi, 5
lea esp, [esp]
mov cl, byte [eax + 0x6e618c]
cmp cl, 1
je 0x4a6873
cmp cl, 2
je 0x4a6873
mov ecx, dword [ebp - 8]
inc ecx
mov dword [ebp - 8], ecx
cmp ecx, edx
jl 0x4a6873
xor ecx, ecx
mov byte [edi], 1
mov dword [ebp - 8], ecx
inc eax
add edi, 0xc
cmp eax, esi
jl 0x4a6850
xor eax, eax
pop edi
mov word [0x7407b8], ax
pop esi
mov esp, ebp
pop ebp
ret