Function at 0x414a00
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
sub esp, 0x450
mov edx, ecx
mov cl, byte [edx + 0x22]
xor eax, eax
push ebx
mov bl, byte [edx + 0x12]
push ebp
xor ebp, ebp
test cl, cl
sete al
xor ecx, ecx
test bl, bl
sete cl
push esi
push edi
lea edi, [esp + 0x60]
mov dword [esp + 0x3c], edx
mov dword [esp + 0x28], ebp
mov dword [esp + 0x14], ebp
cmp ecx, eax
movzx eax, word [edx + 0x24]
movzx ecx, word [edx + 0x26]
mov dword [esp + 0x44], ecx
movzx ecx, byte [edx + 0x2a]
mov dword [esp + 0x40], eax
movzx eax, word [edx + 0x28]
mov dword [esp + 0x30], ecx
movzx ecx, byte [edx + 0x2c]
mov dword [esp + 0x48], eax
movzx eax, byte [edx + 0x2b]
setne byte [esp + 0x13]
mov dword [esp + 0x38], ecx
mov dword [esp + 0x34], eax
xor eax, eax
mov ecx, 0x100
rep stosd dword es:[edi], eax
mov edi, dword [esp + 0x468]
xor ebx, ebx
cmp edi, ebp
mov dword [esp + 0x18], ebx
jle 0x414c5b
jmp 0x414a90
mov ebp, dword [esp + 0x14]
lea ecx, [ecx]
mov esi, dword [esp + 0x464]
cmp ebp, esi
jge 0x414c5b
mov eax, edi
sub eax, ebx
xor ecx, ecx
test eax, eax
mov dword [esp + 0x24], ecx
mov dword [esp + 0x4c], eax
jle 0x414c2b
mov eax, esi
sub eax, ebp
add eax, 0xfffffff9
mov dword [esp + 0x5c], eax
mov eax, ebx
imul eax, esi
mov dword [esp + 0x20], eax
jmp 0x414ad3
mov ecx, dword [esp + 0x24]
mov eax, dword [esp + 0x20]
cmp ecx, dword [esp + 0x5c]
jge 0x414c2b
mov esi, dword [esp + 0x14]
add eax, ecx
mov ecx, dword [edx + 0x1974]
add eax, esi
lea esi, [ecx + eax*2]
mov cl, byte [esp + 0x13]
test cl, cl
mov ax, word [esi]
je 0x414b01
movzx dx, ah
mov dh, al
mov eax, edx
movzx ecx, word [esp + 0x30]
mov ebp, dword [esp + 0x40]
movzx eax, ax
mov ebx, eax
shr ebx, cl
movzx ecx, word [esp + 0x34]
mov edx, eax
shr edx, cl
movzx ecx, word [esp + 0x38]
and ebx, ebp
mov ebp, dword [esp + 0x44]
shr eax, cl
mov ecx, dword [esp + 0x28]
and edx, ebp
mov dword [esp + 0x54], edx
and eax, dword [esp + 0x48]
mov dword [esp + 0x58], eax
mov eax, 7
add esi, 2
add ecx, eax
mov dword [esp + 0x1c], esi
mov dword [esp + 0x2c], eax
mov dword [esp + 0x28], ecx
nop
mov cl, byte [esp + 0x13]
test cl, cl
mov eax, dword [esp + 0x1c]
mov ax, word [eax]
je 0x414b67
movzx cx, ah
mov ch, al
mov eax, ecx
movzx ecx, word [esp + 0x30]
mov edx, dword [esp + 0x40]
movzx edi, ax
mov ebp, edi
shr ebp, cl
movzx ecx, word [esp + 0x34]
and ebp, edx
mov eax, ebp
sub eax, ebx
cdq
mov esi, eax
mov eax, dword [esp + 0x44]
mov ebx, ebp
xor esi, edx
mov ebp, edi
shr ebp, cl
movzx ecx, word [esp + 0x38]
and ebp, eax
sub esi, edx
mov edx, dword [esp + 0x54]
mov eax, ebp
sub eax, edx
cdq
xor eax, edx
sub eax, edx
mov edx, dword [esp + 0x58]
shr edi, cl
add esi, eax
mov dword [esp + 0x54], ebp
and edi, dword [esp + 0x48]
mov eax, edi
sub eax, edx
cdq
xor eax, edx
sub eax, edx
add esi, eax
cmp esi, 0xff
mov dword [esp + 0x58], edi
jle 0x414bd3
mov esi, 0xff
mov edx, dword [esp + esi*4 + 0x60]
mov ecx, dword [esp + 0x1c]
mov eax, dword [esp + 0x2c]
lea esi, [esp + esi*4 + 0x60]
inc edx
add ecx, 2
dec eax
mov dword [esi], edx
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x2c], eax
jne 0x414b50
mov edx, dword [esp + 0x464]
mov esi, dword [esp + 0x20]
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x4c]
mov edi, dword [esp + 0x468]
add esi, edx
inc eax
cmp eax, ecx
mov dword [esp + 0x20], esi
mov esi, edx
mov edx, dword [esp + 0x3c]
mov dword [esp + 0x24], eax
jl 0x414acb
cmp esi, edi
jle 0x414c3d
add dword [esp + 0x14], edi
mov dword [esp + 0x18], 0
jmp 0x414c4f
mov eax, dword [esp + 0x18]
add eax, esi
mov dword [esp + 0x14], 0
mov dword [esp + 0x18], eax
mov ebx, dword [esp + 0x18]
cmp ebx, edi
jl 0x414a89
mov esi, dword [esp + 0x60]
mov eax, dword [esp + 0x64]
mov edi, dword [esp + 0x28]
add eax, esi
imul eax, eax, 0x64
cdq
idiv edi
cmp eax, 0x5a
jge 0x414cd8
xor eax, eax
mov ecx, 1
jmp 0x414c80
mov edx, dword [esp + ecx*4 + 0x60]
mov ebx, edx
imul ebx, ecx
imul ebx, ecx
add eax, ebx
test edx, edx
je 0x414cd8
mov ebx, dword [esp + ecx*4 + 0x5c]
shl ebx, 1
cmp edx, ebx
jg 0x414cd8
inc ecx
cmp ecx, 8
jl 0x414c80
cmp ecx, 0x100
jge 0x414cc5
lea ebx, [ebx]
mov edx, dword [esp + ecx*4 + 0x60]
imul edx, ecx
imul edx, ecx
add eax, edx
inc ecx
cmp ecx, 0x100
jl 0x414cb0
sub edi, esi
xor edx, edx
div edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x450
ret 8
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x450
ret 8