Function at 0x409da0
Capabilities:
Encode data using xor
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0x80
mov eax, dword [ebp + 8]
mov dword [esp + 0x2c], ecx
add eax, dword [ecx + 0x60]
mov ecx, eax
mov word [esp + 0x18], 0x9395
mov byte [esp + 0x1a], 0x64
mov dword [esp + 0x1b], 0
mov word [esp + 0x1f], 0
mov dword [esp + 8], 0
mov edx, dword [esp + 8]
cmp edx, 8
ja 0x409e2f
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov edx, dword [esp + 8]
mov esi, dword [esp + 8]
movzx esi, byte [esp + esi + 0x18]
lea edi, [edx - 0x4f34056f]
add edx, 0x91
and edx, esi
or edi, esi
sub edi, edx
mov dword [esp + 0x30], edi
mov edx, dword [esp + 0x30]
add dl, 9
mov esi, dword [esp + 8]
mov byte [esp + esi + 0x18], dl
inc dword [esp + 8]
mov edx, dword [esp + 8]
cmp edx, 9
jb 0x409df0
mov dword [esp + 8], 0x786a6670
mov word [esp + 0xc], 0x4974
mov dword [esp + 0x12], 0
mov dword [esp + 0xe], 0
mov dword [esp], 0
mov edx, dword [esp]
cmp edx, 0xd
ja 0x409eb3
nop
nop
nop
mov esi, dword [esp]
mov edx, dword [esp]
movzx edi, byte [esp + edx + 8]
lea edx, [esi + edi]
add edx, 0x5e40aa0d
mov ebx, 0xa1bf55f2
sub ebx, esi
lea eax, [esi + 0xd]
and eax, edi
or ebx, edi
add ebx, esi
add eax, ebx
add eax, 0x5e40aa0e
mov esi, eax
xor esi, edx
not eax
and eax, edx
add eax, eax
sub eax, esi
mov dword [esp + 0x30], eax
mov eax, dword [esp + 0x30]
add al, 0xa5
mov edx, dword [esp]
mov byte [esp + edx + 8], al
inc dword [esp]
mov eax, dword [esp]
cmp eax, 0xe
jb 0x409e60
mov dword [esp + 0x30], 0xe6f82c2d
mov dword [esp + 0x34], 0xeaea181c
mov dword [esp + 0x38], 0xefe2e81d
mov dword [esp + 0x3c], 0x12170e1b
mov dword [esp + 0x40], 0xda171b1a
mov dword [esp + 0x44], 0x10e5bfb1
mov dword [esp + 0x48], 0x151f2d16
mov dword [esp + 0x4c], 0x6e2c830
mov dword [esp + 0x50], 0x80d090b
mov dword [esp + 0x54], 0xf390d
mov dword [esp + 0x58], 0xdd2fb06
mov dword [esp + 0x5c], 0xfa3b3f3b
mov dword [esp + 0x60], 0x2a062834
mov dword [esp + 0x64], 0x2630e5cf
mov dword [esp + 0x68], 0xe1c73c35
mov byte [esp + 0x6c], 0x9c
mov dword [esp + 0x6d], 0
mov dword [esp + 0x71], 0
mov byte [esp + 0x75], 0
mov dword [esp + 4], 0
mov eax, dword [esp + 4]
cmp eax, 0x45
ja 0x409f9e
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov edx, dword [esp + 4]
mov eax, dword [esp + 4]
movzx eax, byte [esp + eax + 0x30]
mov esi, 0x2b0b9e8b
sub esi, edx
add edx, 0x74
and edx, eax
or esi, eax
not esi
add esi, eax
sub esi, edx
mov dword [esp], esi
mov eax, dword [esp]
add al, 0xd4
mov edx, dword [esp + 4]
mov byte [esp + edx + 0x30], al
inc dword [esp + 4]
mov eax, dword [esp + 4]
cmp eax, 0x46
jb 0x409f60
mov esi, dword [ebp + 0xc]
movzx ebx, byte [esp + 0x30]
mov edx, ecx
test bl, bl
je 0x409fcb
lea edi, [esp + 0x31]
mov edx, ecx
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov byte [edx], bl
inc edx
movzx ebx, byte [edi]
inc edi
test bl, bl
jne 0x409fc0
mov byte [edx], 0
movzx ebx, byte [esi]
test bl, bl
je 0x409feb
inc esi
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov byte [edx], bl
inc edx
movzx ebx, byte [esi]
inc esi
test bl, bl
jne 0x409fe0
mov esi, dword [ebp + 0x10]
mov byte [edx], 0
movzx ebx, byte [esp + 8]
test bl, bl
je 0x40a00b
lea edi, [esp + 9]
nop
nop
mov byte [edx], bl
inc edx
movzx ebx, byte [edi]
inc edi
test bl, bl
jne 0x40a000
mov byte [edx], 0
movzx ebx, byte [esi]
test bl, bl
je 0x40a02b
inc esi
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov byte [edx], bl
inc edx
movzx ebx, byte [esi]
inc esi
test bl, bl
jne 0x40a020
mov byte [edx], 0
movzx ebx, byte [esp + 0x18]
test bl, bl
je 0x40a04b
lea esi, [esp + 0x19]
nop
nop
nop
nop
nop
mov byte [edx], bl
inc edx
movzx ebx, byte [esi]
inc esi
test bl, bl
jne 0x40a040
mov byte [edx], 0
sub edx, ecx
mov eax, dword [esp + 0x2c]
add dword [eax + 0x60], edx
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret 0xc