Function at 0x418cd0
Capabilities:
Encrypt data using rc4 ksa
Resolve function by parsing pe exports

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x7c
mov dword [esp], eax
mov ebx, edx
mov ebp, ecx
mov esi, dword [esp + 0x90]
mov eax, dword [esp + 0x94]
test al, 8
jne 0x418d20
mov dword [esp + 0x94], eax
mov dword [esp + 0x90], esi
test al, 0x40
mov eax, dword [esp]
jne 0x418f40
add esp, 0x7c
pop ebx
pop esi
pop edi
pop ebp
jmp fcn.004171e0
mov ecx, dword [esp]
mov edx, dword [ecx + 8]
mov ecx, dword [ecx + 0xc]
test al, 1
jne 0x418f59
test ebx, ebx
je 0x418f50
mov dword [esp + 0x40], 0
mov dword [esp + 0x44], 0
mov dword [esp + 0x48], edx
mov dword [esp + 0x4c], ecx
mov eax, dword [esi + 8]
mov dword [esp + 4], eax
test eax, eax
je 0x418f37
mov ecx, dword [esi + 0xc]
mov dword [esp + 8], ecx
test ecx, ecx
je 0x418f37
mov dword [esp + 0x50], 0
mov dword [esp + 0x54], 0
mov eax, dword [ebp + 8]
mov edx, dword [ebp + 0xc]
mov dword [esp + 0x58], eax
mov dword [esp + 0x5c], edx
lea edi, [esp + 0x60]
mov ecx, 4
xor eax, eax
rep stosd dword es:[edi], eax
lea edi, [esp + 0x60]
mov ecx, edi
lea edx, [esp + 0x50]
mov eax, esi
call fcn.00416af0
mov esi, dword [esp]
mov edi, dword [esi]
mov edx, dword [ebp]
mov dword [esp + 0x34], edx
mov esi, dword [esi + 4]
mov dword [esp + 0x24], esi
imul esi, dword [ebx + 4]
mov edx, dword [ebx]
lea esi, [esi + edx*4]
mov dword [esp + 0x28], esi
mov ecx, dword [ebp + 4]
mov esi, dword [esp + 0x64]
imul esi, ecx
mov edx, dword [esp + 0x60]
lea esi, [esi + edx*4]
mov edx, dword [ebx + 8]
shl edx, 0x10
mov eax, edx
cdq
idiv dword [esp + 4]
mov dword [esp + 0x10], eax
mov eax, dword [ebx + 0xc]
shl eax, 0x10
cdq
idiv dword [esp + 8]
mov dword [esp + 0x30], eax
mov ebx, dword [esp + 0x6c]
mov dword [esp + 0x2c], ebx
test ebx, ebx
jle 0x418f37
mov ebp, eax
shr ebp, 1
mov ebx, dword [esp + 0x68]
mov dword [esp + 0x38], ebx
mov eax, dword [esp + 0x10]
shr eax, 1
mov dword [esp + 0x3c], eax
mov eax, dword [esp + 0x34]
lea eax, [eax + ebx*4]
add eax, esi
mov dword [esp + 8], eax
xor ebx, ebx
mov edx, ecx
mov dword [esp + 0x14], ebx
mov dword [esp + 0x18], ebp
mov ebp, edi
lea esi, [esi]
mov eax, dword [esp + 0x18]
shr eax, 0x10
mov ecx, dword [esp + 0x24]
imul eax, ecx
mov ecx, dword [esp + 0x28]
add eax, ecx
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x38]
test eax, eax
jle 0x418f15
mov eax, dword [esp + 0x34]
lea ecx, [eax + esi]
mov eax, dword [esp + 0x3c]
mov dword [esp], eax
mov dword [esp + 0x1c], esi
mov dword [esp + 0x20], edx
lea esi, [esi]
mov eax, dword [esp]
shr eax, 0x10
mov edi, dword [esp + 0xc]
lea ebx, [edi + eax*4]
movzx esi, byte [ebp + ebx + 3]
and esi, 0xff
mov edi, 0x100
sub edi, esi
lea edx, [esi + 1]
mov eax, edx
mov edx, dword [ebp + ebx]
and edx, 0xff00ff
mov dword [esp + 4], eax
imul edx, eax
mov eax, dword [ecx]
and eax, 0xff00ff
imul eax, edi
add edx, eax
shr edx, 8
and edx, 0xff00ff
xor eax, eax
mov al, byte [ecx + 3]
imul eax, edi
sar eax, 8
add eax, esi
shl eax, 0x18
or eax, edx
xor edx, edx
mov dl, byte [ebp + ebx + 1]
mov ebx, dword [esp + 4]
imul edx, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
imul ebx, edi
add edx, ebx
xor dl, dl
or eax, edx
mov dword [ecx], eax
mov edi, dword [esp + 0x10]
add dword [esp], edi
add ecx, 4
cmp dword [esp + 8], ecx
jne 0x418e80
mov esi, dword [esp + 0x1c]
mov edx, dword [esp + 0x20]
add esi, edx
inc dword [esp + 0x14]
mov eax, dword [esp + 0x14]
mov ebx, dword [esp + 0x30]
add dword [esp + 0x18], ebx
add dword [esp + 8], edx
mov ecx, dword [esp + 0x2c]
cmp eax, ecx
jne 0x418e40
add esp, 0x7c
pop ebx
pop esi
pop edi
pop ebp
ret
add esp, 0x7c
pop ebx
pop esi
pop edi
pop ebp
jmp fcn.004177d0
lea ebx, [esp + 0x40]
jmp 0x418d39
test ebx, ebx
je 0x4190db
mov dword [esp + 0x40], 0
mov dword [esp + 0x44], 0
mov dword [esp + 0x48], edx
mov dword [esp + 0x4c], ecx
mov eax, dword [esi + 8]
mov dword [esp + 4], eax
test eax, eax
je 0x418f37
mov edi, dword [esi + 0xc]
mov dword [esp + 8], edi
test edi, edi
je 0x418f37
mov dword [esp + 0x50], 0
mov dword [esp + 0x54], 0
mov eax, dword [ebp + 8]
mov edx, dword [ebp + 0xc]
mov dword [esp + 0x58], eax
mov dword [esp + 0x5c], edx
lea edi, [esp + 0x60]
mov ecx, 4
xor eax, eax
rep stosd dword es:[edi], eax
lea ecx, [esp + 0x60]
lea edx, [esp + 0x50]
mov eax, esi
call fcn.00416af0
mov ecx, dword [esp]
mov ecx, dword [ecx + 4]
mov dword [esp + 0x14], ecx
imul ecx, dword [ebx + 4]
mov edx, dword [ebx]
lea ecx, [ecx + edx*4]
mov dword [esp + 0x18], ecx
mov ecx, dword [ebp + 4]
mov dword [esp + 0x1c], ecx
imul ecx, dword [esp + 0x64]
mov edx, dword [esp + 0x60]
lea ecx, [ecx + edx*4]
mov edx, dword [ebx + 8]
shl edx, 0x10
mov eax, edx
cdq
idiv dword [esp + 4]
mov dword [esp + 4], eax
mov eax, dword [ebx + 0xc]
shl eax, 0x10
cdq
idiv dword [esp + 8]
mov dword [esp + 0x24], eax
mov esi, dword [esp + 0x6c]
mov dword [esp + 0x10], esi
test esi, esi
jle 0x418f37
mov esi, eax
shr esi, 1
mov dword [esp + 8], esi
mov edi, dword [esp + 0x68]
mov dword [esp + 0x20], edi
mov eax, dword [esp + 4]
mov esi, eax
shr esi, 1
mov dword [esp + 0x28], esi
lea esi, [edi*4]
mov dword [esp + 0x2c], esi
mov dword [esp + 4], 0
mov dword [esp + 0x30], ebp
mov ebp, eax
lea esi, [esi]
nop
mov esi, dword [esp + 8]
shr esi, 0x10
mov eax, dword [esp + 0x14]
imul esi, eax
mov eax, dword [esp + 0x18]
add esi, eax
mov edx, dword [esp + 0x20]
test edx, edx
jle 0x4190ba
mov eax, dword [esp]
mov edi, dword [eax]
mov eax, dword [esp + 0x30]
mov ebx, dword [eax]
lea eax, [ebx + ecx]
mov edx, dword [esp + 0x2c]
add ebx, edx
add ebx, ecx
mov edx, dword [esp + 0x28]
mov dword [esp + 0xc], ecx
lea esi, [esi]
mov ecx, edx
shr ecx, 0x10
lea ecx, [edi + ecx*4]
mov ecx, dword [ecx + esi]
mov dword [eax], ecx
add edx, ebp
add eax, 4
cmp ebx, eax
jne 0x4190a0
mov ecx, dword [esp + 0xc]
mov eax, dword [esp + 0x1c]
add ecx, eax
inc dword [esp + 4]
mov eax, dword [esp + 4]
mov ebx, dword [esp + 0x24]
add dword [esp + 8], ebx
cmp dword [esp + 0x10], eax
jne 0x419060
jmp 0x418f37
lea ebx, [esp + 0x40]
jmp 0x418f61