Function at 0xcd2d30
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x18
mov edi, dword [ecx]
xor esi, esi
cmp byte [edi], 0x22
jne 0xcd2fe3
mov eax, edi
jmp 0xcd2d5f
lea eax, [ebx + 2]
mov dword [ecx], eax
cmp byte [ebx + 2], 0
je 0xcd2fe3
mov ebx, eax
inc eax
mov dword [ecx], eax
movzx ebp, byte [ebx + 1]
cmp ebp, 0x5c
je 0xcd2d50
test ebp, ebp
je 0xcd2fe3
cmp ebp, 0x22
jne 0xcd2d5f
mov dword [esp + 0xc], edx
add ebx, 2
mov dword [ecx], ebx
sub ebx, edi
mov ebp, ebx
xor ebp, 0xfffffffd
and ebx, 0xfffffffd
lea eax, [ebx*2 + 2]
add eax, ebp
push eax
call dword [0xd10420]
add esp, 4
mov dword [esp + 4], eax
test eax, eax
je case.0xcd2df8.35
lea eax, [ebx*2 + 1]
add eax, ebp
mov ebx, dword [esp + 4]
mov dword [esp + 0x10], eax
test eax, eax
je 0xcd2f9a
movzx ecx, byte [edi + 1]
mov ebx, dword [esp + 4]
test cl, cl
je 0xcd2f9a
inc edi
mov ebx, dword [esp + 4]
mov ebp, edi
nop dword [eax]
cmp cl, 0x5c
jne 0xcd2e10
movsx ecx, byte [ebp + 1]
add ecx, 0xffffffde
cmp ecx, 0x53
ja case.0xcd2df8.35
lea eax, [ebp + 1]
jmp dword [ecx*4 + 0xd0c7f8]
mov byte [ebx], 0x22
jmp 0xcd2e1d
cmp cl, 0x20
jb case.0xcd2df8.35
mov byte [ebx], cl
mov eax, ebp
inc ebx
movzx ecx, byte [eax + 1]
test cl, cl
je 0xcd2f9a
inc eax
mov edx, eax
sub edx, edi
mov ebp, eax
cmp edx, dword [esp + 0x10]
jb 0xcd2de0
jmp 0xcd2f9a
mov byte [ebx], 0x2f
jmp 0xcd2e1d
mov byte [ebx], 0x5c
jmp 0xcd2e1d
mov byte [ebx], 8
jmp 0xcd2e1d
mov byte [ebx], 0xc
jmp 0xcd2e1d
mov byte [ebx], 0xa
jmp 0xcd2e1d
mov byte [ebx], 0xd
jmp 0xcd2e1d
mov byte [ebx], 9
jmp 0xcd2e1d
lea ecx, [ebp + 2]
mov edx, esp
call fcn.00cd2ff0
test eax, eax
jne case.0xcd2df8.35
mov edx, dword [esp]
cmp edx, 0x7f
ja 0xcd2e7d
mov byte [ebx], dl
jmp 0xcd2ece
cmp edx, 0x7ff
ja 0xcd2e9b
shr edx, 6
or dl, 0xc0
mov byte [ebx], dl
movzx eax, byte [esp]
and al, 0x3f
or al, 0x80
mov byte [ebx + 1], al
inc ebx
jmp 0xcd2ece
lea eax, [edx - 0xe000]
cmp eax, 0xfffff7ff
ja 0xcd2edd
shr edx, 0xc
and dl, 0xf
or dl, 0xe0
mov byte [ebx], dl
mov eax, dword [esp]
shr eax, 6
and al, 0x3f
or al, 0x80
mov byte [ebx + 1], al
movzx eax, byte [esp]
and al, 0x3f
or al, 0x80
mov byte [ebx + 2], al
add ebx, 2
mov eax, 1
add eax, ebp
add eax, 4
jmp 0xcd2e1d
cmp edx, 0xdbff
ja case.0xcd2df8.35
cmp byte [ebp + 6], 0x5c
jne case.0xcd2df8.35
cmp byte [ebp + 7], 0x75
jne case.0xcd2df8.35
lea ecx, [ebp + 8]
mov dword [esp + 8], edx
lea edx, [esp + 0x14]
call fcn.00cd2ff0
mov edx, dword [esp + 8]
test eax, eax
jne case.0xcd2df8.35
mov ecx, dword [esp + 0x14]
cmp ecx, 0xdc00
jb case.0xcd2df8.35
cmp ecx, 0xdfff
ja case.0xcd2df8.35
mov eax, 0xd7ff
sub eax, edx
or eax, 0x3ff
add eax, edx
shl eax, 0xa
and ecx, 0x3ff
add ecx, eax
add ecx, 0xfca10400
add eax, 0xfca10400
mov dword [esp], ecx
shr eax, 0x12
or al, 0xf0
mov byte [ebx], al
mov eax, dword [esp]
shr eax, 0xc
and al, 0x3f
or al, 0x80
mov byte [ebx + 1], al
mov eax, dword [esp]
shr eax, 6
and al, 0x3f
or al, 0x80
mov byte [ebx + 2], al
movzx eax, byte [esp]
and al, 0x3f
or al, 0x80
mov byte [ebx + 3], al
add ebx, 3
mov eax, 7
add eax, ebp
add eax, 4
jmp 0xcd2e1d
mov byte [ebx], 0
sub ebx, dword [esp + 4]
inc ebx
push ebx
call dword [0xd10420]
add esp, 4
test eax, eax
je case.0xcd2df8.35
mov ebp, eax
push ebx
mov esi, dword [esp + 8]
push esi
push eax
call fcn.00cd8c30
add esp, 0xc
dec ebx
mov eax, dword [esp + 0xc]
mov dword [eax], ebx
push esi
call dword [0xd1041c]
add esp, 4
mov esi, ebp
jmp 0xcd2fe3
push dword [esp + 4]
call dword [0xd1041c]
add esp, 4
mov eax, esi
add esp, 0x18
pop esi
pop edi
pop ebx
pop ebp
ret