Function at 0x6f8480
Capabilities:
Encrypt data using rc4 prga

Disassembly:
sub esp, 0x20
push ebx
push ebp
mov ebp, ecx
movzx eax, byte [ebp + 0x34]
mov ecx, dword [ebp + 0x3c]
imul eax, eax, 0x1c
movsx edx, word [eax + ecx - 0x10]
lea ecx, [eax + ecx - 0x1c]
movsx eax, word [ecx + 8]
add edx, eax
movzx ax, byte [ecx + 0x12]
mov dword [esp + 0x1c], edx
xor edx, edx
mov dx, word [ecx + 0x10]
fild dword [esp + 0x1c]
push esi
push edi
sar edx, 4
and edx, 0xf00
or edx, eax
movsx edx, dx
mov dword [esp + 0x24], edx
fisub dword [esp + 0x24]
fcomp dword [esp + 0x34]
fnstsw ax
test ah, 5
jp 0x6f850c
movsx edx, word [ecx + 8]
movsx eax, word [ecx + 0xc]
add eax, edx
mov dword [esp + 0x34], eax
xor eax, eax
mov ax, word [ecx + 0x10]
movzx cx, byte [ecx + 0x12]
fild dword [esp + 0x34]
sar eax, 4
and eax, 0xf00
or eax, ecx
movsx edx, ax
mov dword [esp + 0x34], edx
fisub dword [esp + 0x34]
fstp dword [esp + 0x34]
mov eax, dword [esp + 0x34]
push eax
mov ecx, ebp
call fcn.006f8040
mov cl, byte [esp + 0x38]
xor ebx, ebx
cmp cl, bl
mov dword [esp + 0x20], eax
mov dword [esp + 0x10], 0
mov dword [esp + 0x24], 0xbf800000
jne 0x6f853e
mov dword [esp + 0x24], 0x3f800000
cmp eax, ebx
mov dword [esp + 0x1c], ebx
jl 0x6f8639
lea ebx, [ebx]
mov ecx, dword [esp + 0x1c]
mov esi, dword [ebp + 0x3c]
cmp ecx, eax
sete cl
lea edx, [esp + 0x18]
lea eax, [esp + 0x14]
add esi, ebx
mov dword [esp + 0x14], 0
mov dword [esp + 0x18], 0
push ecx
mov ecx, dword [esp + 0x38]
push edx
push eax
push ecx
sub esp, 0x1c
mov edi, esp
mov ecx, 7
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
call fcn.006f81a0
mov edx, dword [ebp + 0x3c]
movsx ecx, word [ebx + edx + 0x14]
lea eax, [ebx + edx]
mov dl, byte [eax + 0x13]
mov esi, dword [eax + 4]
mov dword [esp + 0x28], ecx
mov cl, byte [esp + 0x38]
shr dl, 4
fild dword [esp + 0x28]
and dl, 1
xor dl, cl
mov byte [esp + 0x2c], dl
fmul dword [esp + 0x24]
fmul dword [0x87dedc]
fadd dword [esp + 0x10]
fstp dword [esp + 0x10]
fld dword [0x84669c]
fld dword [esp + 0x18]
fld dword [esp + 0x14]
fucompp
fnstsw ax
test ah, 0x44
jnp 0x6f8617
mov eax, dword [esp + 0x14]
fstp st(0)
mov edi, dword [esp + 0x2c]
push eax
push edi
push esi
call fcn.006fecb0
mov ecx, eax
call fcn.006fed70
fstp dword [esp + 0x28]
mov ecx, dword [esp + 0x18]
push ecx
push edi
push esi
call fcn.006fecb0
mov ecx, eax
call fcn.006fed70
fsub dword [esp + 0x28]
mov eax, dword [esp + 0x1c]
fadd dword [esp + 0x10]
mov ecx, dword [esp + 0x20]
inc eax
add ebx, 0x1c
fstp dword [esp + 0x10]
mov dword [esp + 0x1c], eax
cmp eax, ecx
mov eax, ecx
jle 0x6f8550
movzx ecx, byte [ebp + 0x34]
lea edx, [ecx - 1]
cmp eax, edx
jne 0x6f86a2
mov eax, dword [ebp + 0x3c]
imul ecx, ecx, 0x1c
movsx edx, word [ecx + eax - 0x14]
lea eax, [ecx + eax - 0x1c]
movsx ecx, word [eax + 0xc]
add ecx, edx
movzx dx, byte [eax + 0x12]
mov dword [esp + 0x38], ecx
xor ecx, ecx
mov cx, word [eax + 0x10]
fild dword [esp + 0x38]
sar ecx, 4
and ecx, 0xf00
or ecx, edx
movsx eax, cx
mov dword [esp + 0x38], eax
fisub dword [esp + 0x38]
fcomp dword [esp + 0x34]
fnstsw ax
test ah, 0x41
jp 0x6f86a2
fld dword [esp + 0x24]
fmul dword [ebp + 0x2c]
fadd dword [esp + 0x10]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret 8
fld dword [esp + 0x10]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret 8