Function at 0x8251e0
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
sub esp, 0xc
push ebx
push ebp
push esi
push edi
xor edi, edi
mov dword [esp + 0x18], edi
call fcn.007fa050
mov esi, eax
mov dword [esp + 0x14], esi
jmp 0x825200
lea ebx, [esi + edi + 0x10]
lea ebp, [esi + edi + 0x12]
call fcn.00804590
push 0x1000
mov dword [esp + 0x14], eax
call fcn.008013f0
add esp, 4
test eax, eax
je 0x825234
call fcn.00825160
mov dword [esp + 0x18], 1
jmp 0x8254b1
push 0x2000
call fcn.008013f0
add esp, 4
test eax, eax
je 0x8252a0
call fcn.00816400
push 0x6c008504
mov ebx, eax
call fcn.005617c0
mov eax, dword [ebx + 0x14]
add esp, 4
cmp eax, 4
jne 0x82526a
mov dword [ebx + 8], 2
jmp 0x82527b
mov edx, dword [ebx + 0x18]
xor eax, eax
cmp edx, 2
setne al
add eax, 3
mov dword [ebx + 8], eax
push 0x14
mov dword [ebx + 0x28], 0x10
call fcn.00801010
push 0x1a
call fcn.00801010
add esp, 8
mov dword [esp + 0x18], 1
jmp 0x8254b1
push 0x4000
call fcn.008013f0
add esp, 4
test eax, eax
je 0x8252e5
mov dl, byte [edi + esi + 0x14]
mov cl, byte [edi + esi + 0x16]
add dl, cl
dec dl
movzx eax, dl
movzx ecx, cl
cdq
idiv ecx
push edx
mov byte [edi + esi + 0x14], dl
call fcn.00824c20
mov esi, dword [esp + 0x14]
add esp, 4
mov edx, ebp
mov ecx, ebx
call fcn.007fba70
jmp 0x82549c
push 0x20000
call fcn.008013f0
add esp, 4
test eax, eax
je 0x825326
mov dl, byte [edi + esi + 0x14]
movzx ecx, byte [edi + esi + 0x16]
inc dl
movzx eax, dl
cdq
idiv ecx
push edx
mov byte [edi + esi + 0x14], dl
call fcn.00824c20
mov esi, dword [esp + 0x14]
add esp, 4
mov edx, ebp
mov ecx, ebx
call fcn.007fba70
jmp 0x82549c
mov esi, edi
call fcn.00824b00
test eax, eax
jne 0x8254ad
push 1
xor esi, esi
call fcn.008013f0
add esp, 4
test eax, eax
je 0x825378
mov al, byte [ebp]
add al, 7
movzx eax, al
and eax, 0x80000007
jns 0x825359
dec eax
or eax, 0xfffffff8
inc eax
cmp al, 8
mov byte [ebp], al
je 0x8253b7
mov ecx, dword [esp + 0x10]
movzx eax, al
lea edx, [eax + ecx]
movzx ecx, byte [ebx]
lea edx, [edx + eax*4]
cmp byte [ecx + edx], 0xff
je 0x825345
jmp 0x8253b7
push 8
call fcn.008013f0
add esp, 4
test eax, eax
je 0x8253bc
mov al, byte [ebp]
inc al
movzx eax, al
and eax, 0x80000007
jns 0x82539a
dec eax
or eax, 0xfffffff8
inc eax
cmp al, 8
mov byte [ebp], al
je 0x8253b7
mov ecx, dword [esp + 0x10]
movzx eax, al
lea edx, [eax + ecx]
movzx ecx, byte [ebx]
lea edx, [edx + eax*4]
cmp byte [ecx + edx], 0xff
je 0x825386
mov esi, 1
push 0x80
call fcn.008013f0
add esp, 4
test eax, eax
je 0x8253f9
lea ecx, [ecx]
mov al, byte [ebx]
add al, 4
movzx eax, al
cdq
mov ecx, 5
idiv ecx
mov ecx, dword [esp + 0x10]
mov byte [ebx], dl
movzx eax, byte [ebp]
add ecx, eax
movzx edx, dl
lea eax, [ecx + eax*4]
cmp byte [edx + eax], 0xff
je 0x8253d0
jmp 0x825437
push 0x400
call fcn.008013f0
add esp, 4
test eax, eax
je 0x82543c
lea ebx, [ebx]
mov cl, byte [ebx]
inc cl
movzx eax, cl
cdq
mov ecx, 5
idiv ecx
mov ecx, dword [esp + 0x10]
mov byte [ebx], dl
movzx eax, byte [ebp]
add ecx, eax
movzx edx, dl
lea eax, [ecx + eax*4]
cmp byte [edx + eax], 0xff
je 0x825410
mov esi, 1
movzx eax, byte [ebp]
mov ecx, dword [esp + 0x10]
mov ebp, dword [esp + 0x14]
lea edx, [eax + ecx]
movzx ecx, byte [ebx]
lea edx, [edx + eax*4]
movzx eax, byte [ecx + edx]
push 0
push eax
mov dword [ebp + edi*4], eax
call fcn.007f8960
mov byte [edi + ebp + 0x1a], al
mov eax, edi
call fcn.00824ba0
mov bl, byte [ebp + edi*4]
push 0
mov eax, edi
call fcn.00824e90
xor eax, eax
mov al, byte [ebp + edi*4]
push 1
push eax
push edi
call fcn.00824d80
mov al, byte [ebp + edi*4]
push 1
push edi
call fcn.00824e10
add esp, 0x20
cmp esi, 1
jne 0x8254ad
test edi, edi
jne 0x8254ad
push 0x6c00850c
call fcn.005617c0
add esp, 4
mov esi, dword [esp + 0x14]
inc edi
cmp edi, 2
jl 0x825200
mov eax, dword [esp + 0x18]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret