Function at 0x41831c
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x6c
mov eax, dword [ebp + 8]
mov dword [ebp - 0x10], eax
lea edi, [ebp + 0xc]
mov eax, dword [ebp + 0x14]
mov dword [ebp - 0x24], eax
mov esi, dword [ebp + 0xc]
mov dword [ebp - 0x48], 0x4359dc
mov dword [ebp - 0x44], 0x438994
mov dword [ebp - 0x40], ebp
mov dword [ebp - 0x38], esp
mov dword [ebp - 0x40], 0x41858c
lea eax, [ebp - 0x64]
call fcn.00436645
mov dword [ebp - 0x20], esi
mov ebx, esi
test ebx, ebx
jne 0x4184c4
jmp 0x41850c
cmp byte [edi + 4], 0
jne 0x4183df
test ebx, ebx
je 0x4183cc
mov eax, dword [ebx + 0x1c]
mov eax, dword [eax]
test eax, eax
je 0x41839c
mov ecx, dword [ebx + 0x2c]
cmp dword [ecx], 0
jle 0x41839c
movzx eax, word [eax]
jmp 0x4183b6
xor eax, eax
cmp ecx, eax
jne 0x41836c
jmp 0x41856f
mov eax, dword [ebx]
mov eax, dword [eax + 0x1c]
mov dword [ebp - 0x5c], 3
mov dword [ebp - 0x14], ebx
mov dword [esp], ebx
call eax
lea edi, [ebp + 0xc]
mov ebx, dword [ebp - 0x14]
movzx ecx, ax
cmp ecx, 0xffff
je 0x4183cc
mov word [edi + 6], ax
jmp 0x4183db
mov dword [edi], 0
mov dword [ebp - 0x20], 0
xor ebx, ebx
mov byte [edi + 4], 1
movzx edx, word [edi + 6]
mov eax, dword [ebp - 0x10]
mov eax, dword [eax + 8]
mov ecx, dword [ebp - 0x10]
cmp eax, dword [ecx + 0xc]
jne 0x418445
mov word [ebp - 0x1c], dx
mov ecx, dword [ebp - 0x10]
sub eax, dword [ecx + 4]
sar eax, 1
lea ecx, [eax + 1]
mov edx, eax
shr edx, 1
mov edi, edx
xor edi, 0x7fffffff
xor esi, esi
cmp edi, eax
jb 0x418416
add edx, eax
mov esi, edx
mov dword [ebp - 0x14], ebx
cmp esi, ecx
jb 0x41841f
mov ecx, esi
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x5c], 4
mov dword [esp], eax
mov dword [esp + 4], ecx
call fcn.00418674
mov eax, dword [ebp - 0x10]
mov eax, dword [eax + 8]
lea edi, [ebp + 0xc]
mov ebx, dword [ebp - 0x14]
movzx edx, word [ebp - 0x1c]
mov word [eax], dx
add eax, 2
mov ecx, dword [ebp - 0x10]
mov dword [ecx + 8], eax
test ebx, ebx
je 0x4184ac
mov eax, dword [ebx + 0x1c]
mov ecx, dword [eax]
test ecx, ecx
je 0x41847c
mov edx, dword [ebx + 0x2c]
mov esi, dword [edx]
test esi, esi
jle 0x41847c
dec esi
mov dword [edx], esi
lea edx, [ecx + 2]
mov dword [eax], edx
movzx eax, word [ecx]
jmp 0x418496
mov eax, dword [ebx]
mov eax, dword [eax + 0x20]
mov dword [ebp - 0x5c], 5
mov dword [ebp - 0x14], ebx
mov dword [esp], ebx
call eax
lea edi, [ebp + 0xc]
mov ebx, dword [ebp - 0x14]
movzx eax, ax
cmp eax, 0xffff
je 0x4184ac
xor eax, eax
jmp 0x4184bd
mov dword [edi], 0
mov al, 1
mov dword [ebp - 0x20], 0
xor ebx, ebx
mov byte [edi + 4], al
test ebx, ebx
je 0x41850c
mov eax, dword [ebx + 0x1c]
mov eax, dword [eax]
test eax, eax
je 0x4184dc
mov ecx, dword [ebx + 0x2c]
cmp dword [ecx], 0
jle 0x4184dc
movzx eax, word [eax]
jmp 0x4184f9
mov eax, dword [ebp - 0x20]
mov eax, dword [eax]
mov eax, dword [eax + 0x1c]
mov dword [ebp - 0x5c], 1
mov dword [ebp - 0x14], ebx
mov dword [esp], ebx
call eax
lea edi, [ebp + 0xc]
mov ebx, dword [ebp - 0x14]
movzx eax, ax
xor ecx, ecx
cmp eax, 0xffff
setne cl
jmp 0x41850e
xor ecx, ecx
mov edx, dword [ebp - 0x24]
test edx, edx
je 0x41838c
mov dword [ebp - 0x1c], ecx
mov eax, dword [edx + 0x1c]
mov eax, dword [eax]
test eax, eax
je 0x41853c
mov ecx, dword [edx + 0x2c]
cmp dword [ecx], 0
jle 0x41853c
movzx eax, word [eax]
jmp 0x418556
mov dword [ebp - 0x14], ebx
mov eax, dword [edx]
mov eax, dword [eax + 0x1c]
mov dword [ebp - 0x5c], 2
mov dword [esp], edx
call eax
lea edi, [ebp + 0xc]
mov ebx, dword [ebp - 0x14]
movzx ecx, ax
xor eax, eax
cmp ecx, 0xffff
setne al
mov ecx, dword [ebp - 0x1c]
cmp ecx, eax
jne 0x41836c
lea eax, [ebp - 0x64]
mov dword [esp], eax
call fcn.00436666
add esp, 0x6c
pop esi
pop edi
pop ebx
pop ebp
ret