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

Disassembly:
pushal
push ebp
mov ebp, esp
sub esp, 0x108
mov dword [ebp - 8], 1
mov eax, 0xd
xor ecx, ecx
inc ecx
mov dword [ebp - 0x14], eax
mov dword [ebp - 0xc], 6
mov dword [ebp - 0x34], 0xc
mov eax, 0x6c
mov ecx, 0xc
mov edx, 0x2aaaaaab
push ecx
mov ecx, eax
imul edx
sar edx, 1
sar ecx, 0x1f
sub edx, ecx
mov eax, edx
pop ecx
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x54], 0x7eb7
mov dword [ebp - 0x44], 0x87b605c8
mov eax, 0x84
mul dword [ebp - 0x54]
mov dword [ebp - 0x84], eax
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x1c], 0x5bb2
add dword [ebp - 0x1c], 0x34b1
add dword [ebp - 0x1c], 0x2f99d
mov dword [ebp - 0x48], __current_exception
dec dword [ebp - 0x44]
add dword [ebp - 0x18], 0x2ea6
mov eax, dword [ebp - 0x38]
add eax, dword [ebp - 0xc]
sub eax, 0xf
mov dword [ebp - 0x3c], eax
mov eax, dword [ebp - 0x48]
sub dword [ebp - 0x18], eax
mov dword [ebp - 4], 0x418902
mov eax, dword [ebp - 0x3c]
mov dword [ebp - 0x88], eax
mov eax, 0x24
mov ecx, dword [ebp - 0x38]
cdq
idiv ecx
mov ecx, eax
mov eax, dword [ebp - 0x88]
xor edx, edx
div ecx
mov dword [ebp - 0x8c], eax
mov dword [ebp - 0x58], eax
mov eax, 0x27
mov ecx, dword [ebp - 0x14]
cdq
idiv ecx
mov edi, eax
add edi, dword [ebp - 0x48]
mov dword [ebp - 0x24], edi
mov eax, dword [ebp - 0x24]
mov edx, dword [ebp - 0x18]
mov al, byte [edx + eax]
mov byte [ebp - 0x1d], al
movzx eax, byte [ebp - 0x1d]
mov edx, dword [ebp - 0x44]
add edx, dword [ebp - 0x58]
and edx, 0xff
xor eax, edx
mov byte [ebp - 0x1d], al
mov eax, dword [ebp - 0x24]
mov edx, dword [ebp - 0x18]
mov cl, byte [ebp - 0x1d]
mov byte [edx + eax], cl
inc dword [ebp - 0x24]
mov eax, dword [ebp - 0x1c]
add eax, dword [ebp - 0x48]
cmp dword [ebp - 0x24], eax
jb 0x401344
inc dword [ebp - 0x3c]
mov ebx, 0x4a4000
mov eax, dword [ebp - 0xc]
sub eax, 2
cmp dword [ebp - 0x3c], eax
jbe 0x401301
mov dword [ebp - 0x5c], 0x43fd02
mov esi, dword [ebp - 0x14]
sub esi, 0xd
cmp esi, 0x2731c
jae 0x4013b7
mov eax, dword [ebp - 4]
mov al, byte [eax + esi]
mov byte [ebx + esi], al
inc esi
jmp 0x4013a3
mov dword [ebp - 0x60], 0x5b7000
mov eax, dword [ebp - 0xc]
sub eax, 6
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0x28]
mov edx, dword [ebp - 0x5c]
mov al, byte [edx + eax]
add cl, byte [eax + 0x458be345]
fmul dword [ebx + 0x4d8aa055]
jecxz 0x401365
or al, 2
inc dword [ebp - 0x28]
cmp dword [ebp - 0x28], 0xd5d0
jb 0x4013c7
mov dword [ebp - 0x64], 0x450b82
mov dword [ebp - 0x68], 0x10000000
mov dword [ebp - 0x10], 0x44d702
mov dword [ebp - 0x80], 0x114000
mov dword [ebp - 0x2c], 0x53f
mov eax, dword [ebp - 0x10]
mov eax, dword [eax]
mov dword [ebp - 0x74], eax
mov eax, dword [ebp - 0x38]
sub eax, 9
mov dword [ebp - 0x30], eax
mov eax, 3
mul dword [ebp - 0x2c]
mov dword [ebp - 0x90], eax
mov dword [ebp - 0x2c], eax
add dword [ebp - 0x2c], 0x43
mov eax, ebx
sub eax, dword [ebp - 0x2c]
inc ebp
aam 0x89
inc ebp
mov al, 0x8b
jge fcn.0040143a
shl edi, 3
add edi, dword [ebp - 0x10]
add edi, dword [ebp - 0x30]
mov dword [ebp - 0x6c], edi
mov eax, edi
mov ax, word [eax]
mov word [ebp - 0x4a], ax
movzx edi, word [ebp - 0x4a]
mov edx, dword [ebp - 0xc]
shl edx, 1
mov ecx, edx
sar edi, cl
mov word [ebp - 0x6e], di
mov eax, dword [ebp - 0x34]
add eax, dword [ebp - 8]
sub eax, 0xd
movzx edx, word [ebp - 0x4a]
cmp eax, edx
je 0x401517
movzx edi, word [ebp - 0x4a]
mov ecx, dword [ebp - 0x14]
sub ecx, 9
shl edi, cl
mov word [ebp - 0x3e], di
movzx edi, word [ebp - 0x3e]
mov ecx, dword [ebp - 8]
add ecx, 3
sar edi, cl
mov word [ebp - 0x3e], di
mov eax, dword [ebp - 0xc]
add eax, dword [ebp - 8]
sub eax, 7
cmp dword [ebp - 0x30], eax
je 0x4014b9
mov eax, dword [ebp - 0x34]
sub eax, 0xc
movzx edx, word [ebp - 0x3e]
cmp eax, edx
je 0x401517
mov eax, dword [ebp - 0x50]
sub eax, dword [ebp - 0x68]
mov dword [ebp - 0x7c], eax
test byte [edi], cl
mov bh, 0x45
xchg edx, eax
mov edx, dword [ebp - 0xc]
add edx, dword [ebp - 0x38]
sub edx, 0xc
cmp eax, edx
jne 0x4014f2
mov eax, dword [ebp - 0x74]
movzx edx, word [ebp - 0x3e]
add eax, edx
add eax, dword [ebp - 0x50]
mov dword [ebp - 0x78], eax
mov edi, eax
mov edx, dword [ebp - 0x14]
sub edx, 0xd
mov ecx, dword [ebp - 0x7c]
add ecx, dword [edi]
mov dword [edi + edx*4], ecx
mov eax, 2
mov ecx, dword [ebp - 8]
cdq
idiv ecx
add dword [ebp - 0x30], eax
mov edi, dword [ebp - 0x34]
add edi, ecx
sub edi, 0xc
mov edx, dword [ebp - 0x10]
mov ecx, dword [ebp - 0x30]
cmp dword [edx + edi*4], ecx
ja 0x401437
mov eax, dword [ebp - 0x10]
mov edi, dword [ebp - 0xc]
add edi, dword [ebp - 0x14]
sub edi, 0x12
mov edx, eax
add edx, dword [eax + edi*4]
mov dword [ebp - 0x10], edx
mov eax, edx
cmp dword [ebp - 0x64], eax
jbe 0x40154e
mov edx, dword [ebp - 0x14]
mov ecx, edx
add ecx, dword [ebp - 8]
sub ecx, 0xe
mov edi, edx
add edi, dword [ebp - 0xc]
sub edi, 0x12
cmp ecx, dword [eax + edi*4]
jne 0x401400
leave
mov eax, 0x4af2e0
invalid