Function at 0x409d70
Capabilities:
Encode data using xor
Encrypt data using rc4 prga
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0xb0
mov edi, dword [ebp + 8]
mov dword [esp + 0x74], ecx
add edi, dword [ecx + 0x60]
mov dword [esp + 0x78], 0xafb6b09b
mov dword [esp + 0x7c], 0xc8908bbd
mov dword [esp + 0x80], 0x848892b2
mov dword [esp + 0x84], 0x9bb7f5d0
mov dword [esp + 0x88], 0x8b8db29a
mov dword [esp + 0x8c], 0x839a9285
mov dword [esp + 0x90], 0x9adf81df
mov dword [esp + 0x94], 0x9a9b9fa8
mov dword [esp + 0x98], 0xf4faf68a
mov word [esp + 0x9c], 0xfdf8
mov dword [esp + 0x9e], 0
mov word [esp + 0xa2], 0
mov dword [esp + 8], 0
mov eax, dword [esp + 8]
cmp eax, 0x2b
ja 0x409e60
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov eax, dword [esp + 8]
mov ecx, dword [esp + 8]
movzx ecx, byte [esp + ecx + 0x78]
lea edx, [eax + 0x5b]
and edx, ecx
mov esi, 0x52ce40a4
sub esi, eax
or esi, ecx
not esi
add esi, ecx
sub esi, edx
mov dword [esp + 0x18], esi
mov eax, dword [esp + 0x18]
add al, 0x83
mov ecx, dword [esp + 8]
mov byte [esp + ecx + 0x78], al
inc dword [esp + 8]
mov eax, dword [esp + 8]
cmp eax, 0x2c
jb 0x409e20
mov dword [esp + 8], 0xa3bcb08a
mov dword [esp + 0xc], 0
mov dword [esp + 0x10], 0
mov word [esp + 0x14], 0
mov dword [esp], 0
mov eax, dword [esp]
cmp eax, 0xd
ja 0x409ed9
nop
nop
mov eax, dword [esp]
mov ecx, dword [esp]
movzx ecx, byte [esp + ecx + 8]
lea edx, [eax + ecx]
add edx, 0xeb17d6e6
add eax, 0xeb17d6e6
and eax, ecx
add eax, eax
sub edx, eax
mov dword [esp + 0x18], edx
mov eax, dword [esp + 0x18]
mov ecx, eax
xor ecx, 0xb5
and eax, 0x35
lea eax, [ecx + eax*2]
inc al
mov ecx, dword [esp]
mov byte [esp + ecx + 8], al
inc dword [esp]
mov eax, dword [esp]
cmp eax, 0xe
jb 0x409e90
mov dword [esp + 0x18], 0xc8ca3635
mov dword [esp + 0x1c], 0xc4cc3a3a
mov dword [esp + 0x20], 0xc7fcfa35
mov dword [esp + 0x24], 0xfcffc4fb
mov dword [esp + 0x28], 0xcffcbc8
mov dword [esp + 0x2c], 0xce1d2721
mov dword [esp + 0x30], 0xc9f7c1cc
mov dword [esp + 0x34], 0xd0140ac6
mov dword [esp + 0x38], 0xded5d5db
mov dword [esp + 0x3c], 0xded7ddd5
mov dword [esp + 0x40], 0xe12c0bdc
mov dword [esp + 0x44], 0xe4dbd7db
mov dword [esp + 0x48], 0x1c281a1a
mov dword [esp + 0x4c], 0x1022d1f7
mov dword [esp + 0x50], 0xd5ff162d
mov dword [esp + 0x54], 0xc2c2e10
mov dword [esp + 0x58], 0x9c4e0c8
mov dword [esp + 0x5c], 0x3d0b3535
mov dword [esp + 0x60], 0xe8073e01
mov word [esp + 0x64], 0xa9c4
mov word [esp + 0x6e], 0
mov dword [esp + 0x6a], 0
mov dword [esp + 0x66], 0
mov dword [esp + 4], 0
mov eax, dword [esp + 4]
cmp eax, 0x57
ja 0x409fe9
mov eax, dword [esp + 4]
mov ecx, dword [esp + 4]
movzx ecx, byte [esp + ecx + 0x18]
lea edx, [eax + 0x51]
and edx, ecx
add eax, ecx
add edx, edx
sub eax, edx
add eax, 0x3679851
mov dword [esp], eax
mov eax, dword [esp]
mov ecx, eax
or ecx, 0xc8
and eax, 0xc8
add eax, ecx
inc al
mov ecx, dword [esp + 4]
mov byte [esp + ecx + 0x18], al
inc dword [esp + 4]
mov eax, dword [esp + 4]
cmp eax, 0x58
jb 0x409fa0
mov eax, dword [ebp + 0xc]
movzx ecx, byte [esp + 0x18]
mov edx, edi
test cl, cl
je 0x40a00b
lea esi, [esp + 0x19]
mov edx, edi
nop
nop
nop
mov byte [edx], cl
inc edx
movzx ecx, byte [esi]
inc esi
test cl, cl
jne 0x40a000
mov byte [edx], 0
movzx ecx, byte [eax]
test cl, cl
je 0x40a02b
inc eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov byte [edx], cl
inc edx
movzx ecx, byte [eax]
inc eax
test cl, cl
jne 0x40a020
mov byte [edx], 0
movzx eax, byte [esp + 8]
test al, al
je 0x40a04b
lea ecx, [esp + 9]
nop
nop
nop
nop
nop
mov byte [edx], al
inc edx
movzx eax, byte [ecx]
inc ecx
test al, al
jne 0x40a040
mov ebx, dword [ebp + 0x14]
mov esi, dword [ebp + 0x10]
mov byte [edx], 0
movzx eax, byte [esp + 0x78]
test al, al
mov dword [esp + 0x70], edi
je 0x40a07b
lea ecx, [esp + 0x79]
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov byte [edx], al
inc edx
movzx eax, byte [ecx]
inc ecx
test al, al
jne 0x40a070
mov byte [edx], 0
mov ecx, ebx
shr ecx, 2
mov eax, esi
mov edi, edx
xchg esi, eax
rep movsd dword es:[edi], dword [esi]
xchg esi, eax
mov eax, ebx
and eax, 0xfffffffc
mov ecx, esi
lea esi, [edx + eax]
add eax, ecx
mov ecx, ebx
shr ecx, 1
and ecx, 1
mov ebx, eax
mov edi, esi
xchg esi, ebx
rep movsw word es:[edi], word [esi]
xchg esi, ebx
mov ebx, dword [ebp + 0x14]
test bl, 1
je 0x40a0bd
mov ecx, ebx
and ecx, 2
movzx eax, byte [eax + ecx]
mov byte [esi + ecx], al
mov dword [esp + 0x18], 0xdedf3331
mov dword [esp + 0x1c], 0xd2cee4e6
mov dword [esp + 0x20], 0xa2efe0e0
mov dword [esp + 0x24], 0xd8addda8
mov dword [esp + 0x28], 0xa5a4d8a5
mov dword [esp + 0x2c], 0x90be0d5
mov word [esp + 0x30], 0xb09
mov byte [esp + 0x32], 0x2a
mov dword [esp + 0x33], 0
mov word [esp + 0x37], 0
mov dword [esp + 8], 0
mov eax, dword [esp + 8]
cmp eax, 0x20
mov edi, dword [esp + 0x70]
ja 0x40a15d
nop
nop
nop
mov eax, dword [esp + 8]
mov ecx, dword [esp + 8]
movzx ecx, byte [esp + ecx + 0x18]
lea esi, [eax + 0x104bbfd6]
add eax, 0xd6
and eax, ecx
or esi, ecx
sub esi, eax
mov dword [esp + 0x78], esi
mov eax, dword [esp + 0x78]
add al, 0x26
mov ecx, dword [esp + 8]
mov byte [esp + ecx + 0x18], al
inc dword [esp + 8]
mov eax, dword [esp + 8]
cmp eax, 0x21
jb 0x40a120
add edx, ebx
movzx eax, byte [esp + 0x18]
test al, al
je 0x40a17b
lea ecx, [esp + 0x19]
nop
nop
nop
nop
mov byte [edx], al
inc edx
movzx eax, byte [ecx]
inc ecx
test al, al
jne 0x40a170
mov byte [edx], 0
sub edx, edi
mov eax, dword [esp + 0x74]
add dword [eax + 0x60], edx
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret 0x10