Function at 0x4012d7
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffe8
push ebx
push esi
push edi
mov esi, dword [ebp + 8]
xor eax, eax
mov dword [ebp - 0x10], eax
xor edx, edx
mov dword [ebp - 0x14], edx
call fcn.00409558
mov ebx, eax
call fcn.00409558
imul ebx, eax
mov dword [ebp - 8], ebx
call fcn.00409558
and eax, 7
inc eax
mov dword [ebp - 4], eax
mov eax, dword [ebp - 8]
xor ebx, ebx
cmp ebx, dword [ebp + 0x14]
jge 0x4015cc
mov edx, dword [ebp + 0x10]
movzx edi, byte [edx + ebx]
mov edx, edi
mov ecx, eax
and cl, 0xff
xor dl, cl
mov ecx, dword [ebp + 0x10]
mov byte [ecx + ebx], dl
mov ecx, dword [ebp - 4]
mov edx, eax
shl edx, cl
and edx, 0xffffffff
mov dword [ebp - 0xc], edx
mov ecx, 0x20
sub ecx, dword [ebp - 4]
shr eax, cl
and eax, 0xffffffff
or eax, dword [ebp - 0xc]
add eax, edi
sar edi, 1
jns 0x401355
adc edi, 0
lea edx, [edi + edi*2]
add eax, edx
inc ebx
cmp ebx, dword [ebp + 0x14]
jl 0x401319
jmp 0x4015cc
mov eax, dword [ebp - 0x14]
cmp eax, 0x15
ja case.default.0x401371
jmp dword [eax*4 + 0x401378]
call fcn.00409558
test al, 1
je 0x4013e2
mov byte [esi], 0x55
inc esi
jmp case.default.0x401371
mov byte [esi], 0x8b
inc esi
mov byte [esi], 0xc5
inc esi
mov byte [esi], 0x50
inc esi
jmp case.default.0x401371
mov byte [esi], 0x8b
inc esi
mov byte [esi], 0xec
inc esi
jmp case.default.0x401371
call fcn.00409558
test al, 1
je 0x401426
mov byte [esi], 0x83
inc esi
mov byte [esi], 0xec
inc esi
mov byte [esi], 4
inc esi
mov byte [esi], 0x89
inc esi
mov byte [esi], 0x5d
inc esi
mov byte [esi], 0xfc
inc esi
jmp case.default.0x401371
mov byte [esi], 0x53
inc esi
jmp case.default.0x401371
mov byte [esi], 0x51
inc esi
jmp case.default.0x401371
mov byte [esi], 0x52
inc esi
jmp case.default.0x401371
mov byte [esi], 0x8b
inc esi
mov byte [esi], 0x5d
inc esi
mov byte [esi], 8
inc esi
jmp case.default.0x401371
call fcn.00409558
test al, 1
je 0x40146c
mov byte [esi], 0xb9
inc esi
mov eax, dword [ebp + 0x14]
mov dword [esi], eax
add esi, 4
jmp case.default.0x401371
mov byte [esi], 0x68
inc esi
mov edx, dword [ebp + 0x14]
mov dword [esi], edx
add esi, 4
mov byte [esi], 0x59
inc esi
jmp case.default.0x401371
call fcn.00409558
test al, 1
je 0x40149f
mov byte [esi], 0x68
inc esi
mov ecx, dword [ebp - 8]
mov dword [esi], ecx
add esi, 4
mov byte [esi], 0x5a
inc esi
jmp case.default.0x401371
mov byte [esi], 0xba
inc esi
mov eax, dword [ebp - 8]
mov dword [esi], eax
add esi, 4
jmp case.default.0x401371
mov dword [ebp - 0x18], esi
mov byte [esi], 0xf
inc esi
mov byte [esi], 0xb6
inc esi
mov byte [esi], 3
inc esi
jmp case.default.0x401371
call fcn.00409558
test al, 1
je 0x4014de
mov byte [esi], 0x83
inc esi
mov byte [esi], 0xc3
inc esi
mov byte [esi], 1
inc esi
jmp case.default.0x401371
mov byte [esi], 0x43
inc esi
jmp case.default.0x401371
mov byte [esi], 0x32
inc esi
mov byte [esi], 0xc2
inc esi
jmp case.default.0x401371
mov byte [esi], 0xc1
inc esi
mov byte [esi], 0xc2
inc esi
mov dl, byte [ebp - 4]
mov byte [esi], dl
inc esi
jmp case.default.0x401371
mov byte [esi], 3
inc esi
mov byte [esi], 0xd0
inc esi
jmp case.default.0x401371
mov byte [esi], 0x88
inc esi
mov byte [esi], 0x43
inc esi
mov byte [esi], 0xff
inc esi
jmp case.default.0x401371
mov byte [esi], 0xd1
inc esi
mov byte [esi], 0xe8
inc esi
mov byte [esi], 0x6b
inc esi
mov byte [esi], 0xc0
inc esi
mov byte [esi], 3
inc esi
mov byte [esi], 3
inc esi
mov byte [esi], 0xd0
inc esi
jmp case.default.0x401371
mov ebx, esi
sub ebx, dword [ebp - 0x18]
call fcn.00409558
test al, 1
je 0x401563
mov byte [esi], 0x49
inc esi
mov byte [esi], 0x75
inc esi
add bl, 3
neg bl
mov byte [esi], bl
inc esi
jmp case.default.0x401371
mov byte [esi], 0xe2
inc esi
add bl, 2
neg bl
mov byte [esi], bl
inc esi
jmp case.default.0x401371
mov byte [esi], 0x5a
inc esi
jmp case.default.0x401371
mov byte [esi], 0x59
inc esi
jmp case.default.0x401371
mov byte [esi], 0x5b
inc esi
jmp case.default.0x401371
mov byte [esi], 0x5d
inc esi
jmp case.default.0x401371
call fcn.00409558
test al, 1
je 0x401598
mov byte [esi], 0xc3
inc esi
jmp case.default.0x401371
mov byte [esi], 0x58
inc esi
mov byte [esi], 0xff
inc esi
mov byte [esi], 0xe0
inc esi
jmp case.default.0x401371
mov dword [ebp - 0x10], 1
inc dword [ebp - 0x14]
call fcn.00409558
mov ebx, eax
and ebx, 3
test ebx, ebx
je 0x4015cc
push esi
call fcn.004011cd
pop ecx
mov esi, eax
dec ebx
test ebx, ebx
jne 0x4015be
cmp dword [ebp - 0x10], 0
je 0x401365
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret