Function at 0x41f750
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0xc
mov edx, dword [ebp + 0x10]
mov ecx, dword [ebp + 0x14]
mov eax, dword [ebp + 0xc]
mov edx, dword [edx]
mov ecx, dword [ecx]
mov edi, dword [eax]
mov dword [ebp - 0x14], edx
mov dword [ebp - 0x10], ecx
test edx, edx
je 0x41f7f8
mov al, byte [edi]
mov ebx, 2
and eax, 0xff
mov esi, eax
cmp eax, 0x7f
ja 0x41f7c5
mov eax, edx
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
dec eax
mov dword [edx], eax
mov eax, dword [ecx]
inc eax
mov dword [ecx], eax
cmp esi, 0xfffe
ja 0x41f8e0
mov eax, dword [ebp + 0x18]
cmp dword [eax], 1
ja 0x41f8ff
mov ecx, dword [ebp + 0x10]
mov eax, dword [ebp - 0x14]
mov edx, dword [ebp + 0xc]
mov dword [ecx], eax
mov eax, 7
mov dword [edx], edi
jmp 0x41f7fd
xor ecx, ecx
xor edx, edx
mov cl, byte [ebx + 0x44fd91]
mov dl, byte [ebx + 0x44fd8b]
mov eax, ecx
xor eax, 0xffffffff
and eax, esi
cmp eax, edx
je 0x41f7f3
inc ebx
cmp ebx, 7
jne 0x41f7c5
mov eax, 0x2a
add esp, 0xc
pop ebx
pop esi
pop edi
pop ebp
ret
cmp dword [ebp - 0x14], ebx
jae 0x41f805
mov eax, 0x16
add esp, 0xc
pop ebx
pop esi
pop edi
pop ebp
ret
and esi, ecx
lea ecx, [edi + 1]
cmp ebx, 1
jbe 0x41f851
xor edx, edx
mov dl, byte [edi + 1]
mov eax, edx
and eax, 0xc0
add eax, 0xffffff80
jne 0x41f7e6
lea eax, [ebx + edi]
lea ecx, [edi + 2]
mov dword [ebp - 0x18], eax
jmp 0x41f841
xor edx, edx
mov dl, byte [ecx]
mov eax, edx
and eax, 0xc0
add eax, 0xffffff80
jne 0x41f7e6
inc ecx
mov eax, esi
and edx, 0x3f
shl eax, 6
cmp ecx, dword [ebp - 0x18]
lea esi, [edx + eax]
jne 0x41f830
cmp esi, 0x7f
jbe 0x41f7e6
cmp esi, 0x7ff
ja 0x41f863
cmp ebx, 2
ja 0x41f7e6
cmp esi, 0xffff
ja 0x41f874
cmp ebx, 3
ja 0x41f7e6
cmp esi, 0x1fffff
ja 0x41f885
cmp ebx, 4
ja 0x41f7e6
cmp esi, 0x3ffffff
ja 0x41f896
cmp ebx, 5
ja 0x41f7e6
test esi, esi
js 0x41f7e6
lea eax, [esi - 0xd800]
cmp eax, 0x7ff
jbe 0x41f7e6
mov edx, dword [ebp + 0xc]
mov dword [edx], ecx
mov ecx, dword [ebp + 0x10]
mov eax, dword [ecx]
sub eax, ebx
cmp esi, 0x10ffff
mov dword [ecx], eax
jbe 0x41f799
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
mov ecx, dword [ebp - 0x14]
mov dword [eax], edi
mov eax, 0x2a
mov dword [edx], ecx
jmp 0x41f7eb
mov ecx, dword [ebp + 0x18]
cmp dword [ecx], 3
ja 0x41f944
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
mov ecx, dword [ebp - 0x14]
mov dword [eax], edi
mov eax, 7
mov dword [edx], ecx
jmp 0x41f7fd
mov eax, dword [ebp + 8]
test eax, eax
je 0x41f936
mov ecx, dword [ebp - 0x10]
mov edx, esi
mov byte [ecx + 1], dl
xor edx, edx
mov ecx, esi
movzx eax, ch
mov ecx, dword [ebp - 0x10]
mov byte [edx + ecx], al
mov eax, dword [ebp + 0x14]
mov edx, dword [ebp + 0x18]
mov edi, dword [eax]
mov esi, dword [edx]
add edi, 2
sub esi, 2
mov dword [eax], edi
xor eax, eax
mov dword [edx], esi
jmp 0x41f7fd
mov eax, dword [ebp - 0x10]
mov ecx, esi
mov edx, 1
mov byte [eax], cl
jmp 0x41f910
lea eax, [esi - 0x10000]
mov ebx, dword [ebp + 8]
mov edx, eax
and eax, 0x3ff
shr edx, 0xa
add edx, 0xd800
lea ecx, [eax + 0xdc00]
test ebx, ebx
je 0x41f9a1
mov eax, dword [ebp - 0x10]
mov byte [eax + 1], dl
movzx eax, dh
mov edx, dword [ebp - 0x10]
mov byte [edx], al
mov byte [edx + 3], cl
mov edx, 2
movzx eax, ch
mov ecx, dword [ebp - 0x10]
mov byte [edx + ecx], al
mov eax, dword [ebp + 0x14]
mov edx, dword [eax]
add edx, 4
mov dword [eax], edx
mov edx, dword [ebp + 0x18]
mov eax, dword [edx]
sub eax, 4
mov dword [edx], eax
xor eax, eax
jmp 0x41f7fd
mov eax, dword [ebp - 0x10]
mov byte [eax], dl
movzx eax, dh
mov edx, dword [ebp - 0x10]
mov byte [edx + 1], al
mov byte [edx + 2], cl
mov edx, 3
jmp 0x41f97d