Function at 0x41a319
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x6c
mov eax, dword [ebp + 0xc]
mov eax, dword [eax + 0x10]
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x10]
cmp dword [ebp - 0x1c], eax
jle 0x41a340
mov eax, 0
jmp 0x41a5cb
mov eax, dword [ebp + 0xc]
add eax, 0x14
mov dword [ebp - 0x2c], eax
sub dword [ebp - 0x1c], 1
mov eax, dword [ebp - 0x1c]
lea edx, [eax*4]
mov eax, dword [ebp - 0x2c]
add eax, edx
mov dword [ebp - 0x44], eax
mov eax, dword [ebp + 8]
add eax, 0x14
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x1c]
lea edx, [eax*4]
mov eax, dword [ebp - 0x20]
add eax, edx
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 0x24]
mov eax, dword [eax]
mov edx, dword [ebp - 0x44]
mov edx, dword [edx]
lea ebx, [edx + 1]
mov edx, 0
div ebx
mov dword [ebp - 0x28], eax
cmp dword [ebp - 0x28], 0
je 0x41a4a0
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x34], 0
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x3c], 0
mov eax, dword [ebp - 0x2c]
lea edx, [eax + 4]
mov dword [ebp - 0x2c], edx
mov eax, dword [eax]
mov ecx, eax
mov ebx, 0
mov eax, dword [ebp - 0x28]
mov edx, 0
mov edi, ebx
imul edi, eax
mov esi, edx
imul esi, ecx
add esi, edi
mul ecx
mov ecx, eax
mov ebx, edx
lea eax, [esi + ebx]
mov ebx, eax
mov eax, dword [ebp - 0x40]
mov edx, dword [ebp - 0x3c]
add eax, ecx
adc edx, ebx
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x4c], edx
mov eax, dword [ebp - 0x50]
mov edx, dword [ebp - 0x4c]
mov eax, edx
xor edx, edx
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x3c], edx
mov eax, dword [ebp - 0x20]
mov eax, dword [eax]
mov edx, 0
mov ecx, dword [ebp - 0x50]
and ch, 0xff
mov dword [ebp - 0x60], ecx
mov ecx, dword [ebp - 0x4c]
and ecx, 0
mov dword [ebp - 0x5c], ecx
sub eax, dword [ebp - 0x60]
sbb edx, dword [ebp - 0x5c]
sub eax, dword [ebp - 0x38]
sbb edx, dword [ebp - 0x34]
mov dword [ebp - 0x58], eax
mov dword [ebp - 0x54], edx
mov eax, dword [ebp - 0x58]
mov edx, dword [ebp - 0x54]
mov eax, edx
xor edx, edx
mov ecx, eax
and ecx, 1
mov dword [ebp - 0x38], ecx
mov eax, edx
and eax, 0
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 0x20]
lea edx, [eax + 4]
mov dword [ebp - 0x20], edx
mov edx, dword [ebp - 0x58]
mov dword [eax], edx
mov eax, dword [ebp - 0x2c]
cmp eax, dword [ebp - 0x44]
jbe 0x41a3b7
mov eax, dword [ebp - 0x24]
mov eax, dword [eax]
test eax, eax
jne 0x41a4a0
mov eax, dword [ebp + 8]
add eax, 0x14
mov dword [ebp - 0x20], eax
jmp 0x41a482
sub dword [ebp - 0x1c], 1
sub dword [ebp - 0x24], 4
mov eax, dword [ebp - 0x24]
cmp eax, dword [ebp - 0x20]
jbe 0x41a497
mov eax, dword [ebp - 0x24]
mov eax, dword [eax]
test eax, eax
je 0x41a47e
mov eax, dword [ebp + 8]
mov edx, dword [ebp - 0x1c]
mov dword [eax + 0x10], edx
mov eax, dword [ebp + 0xc]
mov dword [esp + 4], eax
mov eax, dword [ebp + 8]
mov dword [esp], eax
call sym.___cmp_D2A
test eax, eax
js 0x41a5c8
add dword [ebp - 0x28], 1
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x34], 0
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x3c], 0
mov eax, dword [ebp + 8]
add eax, 0x14
mov dword [ebp - 0x20], eax
mov eax, dword [ebp + 0xc]
add eax, 0x14
mov dword [ebp - 0x2c], eax
mov eax, dword [ebp - 0x2c]
lea edx, [eax + 4]
mov dword [ebp - 0x2c], edx
mov eax, dword [eax]
mov ecx, eax
mov ebx, 0
mov eax, dword [ebp - 0x40]
mov edx, dword [ebp - 0x3c]
add eax, ecx
adc edx, ebx
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x4c], edx
mov eax, dword [ebp - 0x50]
mov edx, dword [ebp - 0x4c]
mov eax, edx
xor edx, edx
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x3c], edx
mov eax, dword [ebp - 0x20]
mov eax, dword [eax]
mov edx, 0
mov ecx, dword [ebp - 0x50]
and ch, 0xff
mov dword [ebp - 0x68], ecx
mov ecx, dword [ebp - 0x4c]
and ecx, 0
mov dword [ebp - 0x64], ecx
sub eax, dword [ebp - 0x68]
sbb edx, dword [ebp - 0x64]
sub eax, dword [ebp - 0x38]
sbb edx, dword [ebp - 0x34]
mov dword [ebp - 0x58], eax
mov dword [ebp - 0x54], edx
mov eax, dword [ebp - 0x58]
mov edx, dword [ebp - 0x54]
mov eax, edx
xor edx, edx
mov ecx, eax
and ecx, 1
mov dword [ebp - 0x38], ecx
mov eax, edx
and eax, 0
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 0x20]
lea edx, [eax + 4]
mov dword [ebp - 0x20], edx
mov edx, dword [ebp - 0x58]
mov dword [eax], edx
mov eax, dword [ebp - 0x2c]
cmp eax, dword [ebp - 0x44]
jbe 0x41a4ec
mov eax, dword [ebp + 8]
add eax, 0x14
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x1c]
lea edx, [eax*4]
mov eax, dword [ebp - 0x20]
add eax, edx
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 0x24]
mov eax, dword [eax]
test eax, eax
jne 0x41a5c8
jmp 0x41a5aa
sub dword [ebp - 0x1c], 1
sub dword [ebp - 0x24], 4
mov eax, dword [ebp - 0x24]
cmp eax, dword [ebp - 0x20]
jbe 0x41a5bf
mov eax, dword [ebp - 0x24]
mov eax, dword [eax]
test eax, eax
je 0x41a5a6
mov eax, dword [ebp + 8]
mov edx, dword [ebp - 0x1c]
mov dword [eax + 0x10], edx
mov eax, dword [ebp - 0x28]
add esp, 0x6c
pop ebx
pop esi
pop edi
pop ebp
ret