Function at 0x496210
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffd8
push ebx
mov dword [ebp - 4], eax
mov edx, 0x4959c0
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xc]
call fcn.0050a7c8
mov eax, dword [ebp - 4]
cmp byte [eax + 0x314], 0
je 0x49623f
mov dword [ebp - 0x1c], 0xff
jmp 0x496246
mov dword [ebp - 0x1c], 0x100
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xc]
mov eax, dword [eax + 8]
mov edx, dword [ebp - 4]
mov dword [edx + 0x310], eax
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x310]
dec eax
test eax, eax
jl 0x4962a2
inc eax
mov dword [ebp - 0x20], eax
mov dword [ebp - 8], 0
mov eax, dword [ebp - 8]
cmp eax, dword [ebp - 0x1c]
jge 0x49628c
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xc]
call fcn.0050a4e0
cmp dword [eax], 0
jne 0x49629a
mov eax, dword [ebp - 8]
mov edx, dword [ebp - 4]
mov dword [edx + 0x310], eax
jmp 0x4962a2
inc dword [ebp - 8]
dec dword [ebp - 0x20]
jne 0x496271
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x310]
dec eax
test eax, eax
jl 0x4962fe
inc eax
mov dword [ebp - 0x20], eax
mov dword [ebp - 8], 0
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xc]
call fcn.0050a4e0
mov edx, dword [ebp - 8]
mov dword [eax + 8], edx
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xc]
call fcn.0050a4e0
mov edx, dword [ebp - 8]
lea edx, [edx + edx*2]
mov ecx, dword [ebp - 4]
mov bx, word [eax + 0xc]
mov word [ecx + edx + 0x10], bx
mov bl, byte [eax + 0xe]
mov byte [ecx + edx + 0x12], bl
inc dword [ebp - 8]
dec dword [ebp - 0x20]
jne 0x4962bb
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x310]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0xc]
mov edx, dword [edx + 8]
dec edx
sub edx, eax
jl 0x496415
inc edx
mov dword [ebp - 0x20], edx
mov dword [ebp - 8], eax
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xc]
call fcn.0050a4e0
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 0x24]
cmp dword [eax], 0
jne 0x49634d
mov eax, dword [ebp - 0x24]
mov eax, dword [eax + 0xc]
mov eax, dword [eax + 8]
mov edx, dword [ebp - 0x24]
mov dword [edx + 8], eax
jmp 0x496409
xor eax, eax
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x14], 0x2fd
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x310]
dec eax
test eax, eax
jl 0x4963f2
inc eax
mov dword [ebp - 0x28], eax
mov dword [ebp - 0xc], 0
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xc]
call fcn.0050a4e0
xor ebx, ebx
mov bl, byte [eax + 0xc]
mov eax, dword [ebp - 0x24]
movzx eax, byte [eax + 0xc]
sub ebx, eax
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xc]
call fcn.0050a4e0
movzx eax, byte [eax + 0xd]
mov edx, dword [ebp - 0x24]
movzx edx, byte [edx + 0xd]
sub eax, edx
add ebx, eax
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xc]
call fcn.0050a4e0
movzx eax, byte [eax + 0xe]
mov edx, dword [ebp - 0x24]
movzx edx, byte [edx + 0xe]
sub eax, edx
add ebx, eax
mov eax, ebx
cdq
xor eax, edx
sub eax, edx
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
cmp eax, dword [ebp - 0x14]
jge 0x4963ea
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x18], eax
inc dword [ebp - 0xc]
dec dword [ebp - 0x28]
jne 0x496376
mov edx, dword [ebp - 0x18]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xc]
call fcn.0050a4e0
mov eax, dword [eax + 8]
mov edx, dword [ebp - 0x24]
mov dword [edx + 8], eax
inc dword [ebp - 8]
dec dword [ebp - 0x20]
jne 0x496320
mov eax, dword [ebp - 4]
cmp byte [eax + 0x314], 0
je 0x496478
mov eax, dword [ebp - 4]
mov al, byte [eax + 0x310]
mov edx, dword [ebp - 4]
mov byte [edx + 0x315], al
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x310]
lea eax, [eax + eax*2]
mov edx, dword [ebp - 4]
mov byte [edx + eax + 0x10], 0
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x310]
lea eax, [eax + eax*2]
mov edx, dword [ebp - 4]
mov byte [edx + eax + 0x11], 0
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x310]
lea eax, [eax + eax*2]
mov edx, dword [ebp - 4]
mov byte [edx + eax + 0x12], 0
mov eax, dword [ebp - 4]
inc dword [eax + 0x310]
pop ebx
mov esp, ebp
pop ebp
ret