Function at 0x464230
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff0
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
sub esp, 0x68
mov eax, dword [0x4f8008]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebx + 0x10]
push esi
push edi
mov edi, dword [ebx + 0xc]
mov esi, ecx
movd xmm0, eax
pshufd xmm0, xmm0, 0
mov dword [ebp - 0x48], esi
cmp word [edi], 0x20
mov dword [ebp - 0x30], eax
movaps xmmword [ebp - 0x60], xmm0
jne 0x464298
cmp word [edi + 2], 0x18
jne 0x464298
mov ecx, 0xff
cmp word [edi + 4], cx
jne 0x464298
cmp word [edi + 6], cx
jne 0x464298
mov byte [ebp - 0x25], 1
cmp word [edi + 8], cx
je 0x46429c
mov byte [ebp - 0x25], 0
mov edx, dword [esi + 8]
mov dword [esi + 0x34], eax
mov eax, dword [ebx + 0x14]
mov dword [esi + 0x38], eax
cmp edx, dword [esi + 4]
je 0x4642bf
push ecx
lea ecx, [esi + 0x18]
call fcn.0047b4b0
mov eax, dword [esi + 8]
add esp, 4
mov dword [esi + 4], eax
add esi, 0x18
mov dword [ebp - 0x50], esi
cmp dword [esi + 0x14], 0x64
je 0x4642e6
mov eax, dword [esi]
push esi
mov dword [eax + 0x14], 0x15
mov ecx, dword [esi]
mov eax, dword [esi + 0x14]
mov dword [ecx + 0x18], eax
mov eax, dword [esi]
mov eax, dword [eax]
call eax
add esp, 4
mov eax, dword [esi + 0x58]
test eax, eax
je 0x4642f4
mov byte [eax + 0x80], 0
mov eax, dword [esi + 0x5c]
test eax, eax
je 0x464302
mov byte [eax + 0x80], 0
mov eax, dword [esi + 0x60]
test eax, eax
je 0x464310
mov byte [eax + 0x80], 0
mov eax, dword [esi + 0x64]
test eax, eax
je 0x46431e
mov byte [eax + 0x80], 0
mov eax, dword [esi + 0x78]
test eax, eax
je 0x46432c
mov byte [eax + 0x111], 0
mov eax, dword [esi + 0x88]
test eax, eax
je 0x46433d
mov byte [eax + 0x111], 0
mov eax, dword [esi + 0x7c]
test eax, eax
je 0x46434b
mov byte [eax + 0x111], 0
mov eax, dword [esi + 0x8c]
test eax, eax
je 0x46435c
mov byte [eax + 0x111], 0
mov eax, dword [esi + 0x80]
test eax, eax
je 0x46436d
mov byte [eax + 0x111], 0
mov eax, dword [esi + 0x90]
test eax, eax
je 0x46437e
mov byte [eax + 0x111], 0
mov eax, dword [esi + 0x84]
test eax, eax
je 0x46438f
mov byte [eax + 0x111], 0
mov eax, dword [esi + 0x94]
test eax, eax
je 0x4643a0
mov byte [eax + 0x111], 0
mov eax, dword [esi]
push esi
mov eax, dword [eax + 0x10]
call eax
mov eax, dword [esi + 0x18]
push esi
mov eax, dword [eax + 8]
call eax
mov ecx, esi
call fcn.0047e600
mov eax, dword [esi + 0x178]
push esi
mov eax, dword [eax]
call eax
xor eax, eax
mov dword [esi + 0xf8], 0
cmp byte [esi + 0xd0], al
setne al
add eax, 0x65
mov dword [esi + 0x14], eax
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*2]
shl eax, 3
push eax
call fcn.00496f72
add esp, 0x10
mov dword [ebp - 0x3c], eax
xor ecx, ecx
cmp dword [0x4fc534], 2
movd xmm0, eax
pshufd xmm4, xmm0, 0
jl 0x464450
movaps xmm2, xmmword [0x4dfdb0]
movaps xmm3, xmmword [0x4dfdc0]
movaps xmm5, xmmword [ebp - 0x60]
nop dword [eax]
movd xmm0, ecx
movaps xmm1, xmm5
pshufd xmm0, xmm0, 0
paddd xmm0, xmm2
pmulld xmm1, xmm0
pmulld xmm1, xmm3
paddd xmm1, xmm4
movups xmmword [ebp + ecx*4 - 0x24], xmm1
add ecx, 4
cmp ecx, 8
jl 0x464420
mov edx, dword [ebp - 0x30]
jmp 0x46446d
mov edx, dword [ebp - 0x30]
lea eax, [edx + edx*2]
mov dword [ebp - 0x40], eax
mov eax, dword [ebp - 0x3c]
nop dword [eax]
mov dword [ebp + ecx*4 - 0x24], eax
inc ecx
add eax, dword [ebp - 0x40]
cmp ecx, 8
jl 0x464460
mov eax, dword [ebp - 0x48]
mov ecx, dword [eax + 0x110]
mov eax, dword [eax + 0x38]
cmp ecx, eax
jae 0x464700
sub eax, ecx
mov dword [ebp - 0x44], 0
mov ecx, eax
mov dword [ebp - 0x2c], eax
cmp ecx, 8
mov eax, 8
cmovg ecx, eax
mov dword [ebp - 0x2c], ecx
test ecx, ecx
jle 0x464636
mov ecx, dword [ebx + 8]
mov esi, dword [ebp - 0x44]
mov eax, dword [ebp - 0x2c]
nop
cmp byte [ebp - 0x25], 0
mov esi, dword [ebp + esi*4 - 0x24]
je 0x464501
mov eax, edx
test edx, edx
je 0x464618
mov edx, dword [ecx]
lea esi, [esi + 3]
dec eax
add ecx, 4
mov dword [ebp - 0x38], eax
mov eax, edx
mov dword [ebp - 0x34], ecx
movzx ecx, byte [edi + 0xa]
shr eax, cl
mov byte [esi - 3], al
mov eax, edx
movzx ecx, byte [edi + 0xc]
shr eax, cl
mov byte [esi - 2], al
movzx ecx, byte [edi + 0xe]
mov eax, dword [ebp - 0x38]
shr edx, cl
mov ecx, dword [ebp - 0x34]
mov byte [esi - 1], dl
test eax, eax
jne 0x4644c4
jmp 0x464615
cmp word [edi], 0x20
jne 0x46458f
test edx, edx
jle 0x46461b
mov dword [ebp - 0x38], edx
mov eax, dword [ecx]
lea esi, [esi + 3]
movzx edi, word [edi + 4]
add ecx, 4
mov dword [ebp - 0x34], eax
xor edx, edx
mov dword [ebp - 0x4c], ecx
mov ecx, dword [ebx + 0xc]
movzx ecx, byte [ecx + 0xa]
shr eax, cl
and eax, edi
mov ecx, dword [ebx + 0xc]
imul eax, eax, 0xff
div edi
xor edx, edx
mov byte [esi - 3], al
movzx edi, word [ecx + 6]
movzx ecx, byte [ecx + 0xc]
mov eax, dword [ebp - 0x34]
shr eax, cl
and eax, edi
imul eax, eax, 0xff
div edi
xor edx, edx
mov byte [esi - 2], al
mov eax, dword [ebx + 0xc]
movzx edi, word [eax + 8]
movzx ecx, byte [eax + 0xe]
mov eax, dword [ebp - 0x34]
shr eax, cl
and eax, edi
mov ecx, dword [ebp - 0x4c]
imul eax, eax, 0xff
div edi
sub dword [ebp - 0x38], 1
mov edi, dword [ebx + 0xc]
mov byte [esi - 1], al
jne 0x464516
jmp 0x464615
test edx, edx
jle 0x46461b
mov dword [ebp - 0x34], edx
nop word [eax + eax]
movzx eax, word [ecx]
lea esi, [esi + 3]
movzx edi, word [edi + 4]
add ecx, 2
mov dword [ebp - 0x38], eax
xor edx, edx
mov dword [ebp - 0x4c], ecx
mov ecx, dword [ebx + 0xc]
movzx ecx, byte [ecx + 0xa]
shr eax, cl
and eax, edi
mov ecx, dword [ebx + 0xc]
imul eax, eax, 0xff
div edi
xor edx, edx
mov byte [esi - 3], al
movzx edi, word [ecx + 6]
movzx ecx, byte [ecx + 0xc]
mov eax, dword [ebp - 0x38]
shr eax, cl
and eax, edi
imul eax, eax, 0xff
div edi
xor edx, edx
mov byte [esi - 2], al
mov eax, dword [ebx + 0xc]
movzx edi, word [eax + 8]
movzx ecx, byte [eax + 0xe]
mov eax, dword [ebp - 0x38]
shr eax, cl
and eax, edi
mov ecx, dword [ebp - 0x4c]
imul eax, eax, 0xff
div edi
sub dword [ebp - 0x34], 1
mov edi, dword [ebx + 0xc]
mov byte [esi - 1], al
jne 0x4645a0
mov edx, dword [ebp - 0x30]
mov eax, dword [ebp - 0x2c]
mov esi, dword [ebp - 0x44]
mov ecx, dword [ebx + 8]
inc esi
add ecx, dword [ebx + 0x18]
mov dword [ebx + 8], ecx
mov dword [ebp - 0x44], esi
cmp esi, eax
jl 0x4644b0
mov esi, dword [ebp - 0x50]
cmp dword [esi + 0x14], 0x65
je 0x464657
mov eax, dword [esi]
push esi
mov dword [eax + 0x14], 0x15
mov ecx, dword [esi]
mov eax, dword [esi + 0x14]
mov dword [ecx + 0x18], eax
mov eax, dword [esi]
mov eax, dword [eax]
call eax
add esp, 4
mov eax, dword [esi + 0xf8]
cmp eax, dword [esi + 0x20]
jb 0x46467e
mov eax, dword [esi]
push 0xffffffffffffffff
push esi
mov dword [eax + 0x14], 0x7e
mov eax, dword [esi]
mov eax, dword [eax + 4]
call eax
mov eax, dword [esi + 0xf8]
add esp, 8
mov ecx, dword [esi + 8]
test ecx, ecx
je 0x46469c
mov dword [ecx + 4], eax
mov ecx, dword [esi + 8]
mov eax, dword [esi + 0x20]
push esi
mov dword [ecx + 8], eax
mov eax, dword [esi + 8]
mov eax, dword [eax]
call eax
add esp, 4
mov eax, dword [esi + 0x178]
cmp byte [eax + 0xc], 0
je 0x4646b1
mov eax, dword [eax + 4]
push esi
call eax
add esp, 4
mov eax, dword [esi + 0x20]
sub eax, dword [esi + 0xf8]
cmp dword [ebp - 0x2c], eax
mov ecx, dword [esi + 0x17c]
cmovbe eax, dword [ebp - 0x2c]
push eax
lea eax, [ebp - 0x40]
mov dword [ebp - 0x40], 0
push eax
lea eax, [ebp - 0x24]
push eax
mov eax, dword [ecx + 4]
push esi
call eax
mov eax, dword [ebp - 0x40]
add esp, 0x10
add dword [esi + 0xf8], eax
mov eax, dword [ebp - 0x48]
mov edx, dword [ebp - 0x30]
mov ecx, dword [eax + 0x110]
mov eax, dword [eax + 0x38]
cmp ecx, eax
jb 0x464481
push dword [ebp - 0x3c]
call fcn.00496f6d
mov edi, dword [ebp - 0x48]
add esp, 4
mov eax, dword [edi + 0x2c]
cmp eax, 0x65
je 0x464737
cmp eax, 0x66
je 0x464737
cmp eax, 0x67
je 0x464764
mov eax, dword [esi]
mov dword [eax + 0x14], 0x15
mov ecx, dword [esi]
mov eax, dword [edi + 0x2c]
mov dword [ecx + 0x18], eax
mov eax, dword [esi]
mov eax, dword [eax]
jmp 0x46475e
mov eax, dword [edi + 0x110]
cmp eax, dword [edi + 0x38]
jae 0x464755
mov eax, dword [esi]
push esi
mov dword [eax + 0x14], 0x45
mov eax, dword [esi]
mov eax, dword [eax]
call eax
add esp, 4
mov eax, dword [edi + 0x190]
mov eax, dword [eax + 8]
push esi
call eax
add esp, 4
mov eax, dword [edi + 0x190]
cmp byte [eax + 0xd], 0
jne 0x464807
mov eax, dword [eax]
push esi
call eax
xor eax, eax
add esp, 4
mov dword [ebp - 0x3c], eax
cmp dword [edi + 0x128], eax
jbe 0x4647e8
nop dword [eax]
mov ecx, dword [edi + 0x20]
test ecx, ecx
je 0x4647b1
mov dword [ecx + 4], eax
mov ecx, dword [edi + 0x20]
mov eax, dword [edi + 0x128]
push esi
mov dword [ecx + 8], eax
mov eax, dword [edi + 0x20]
mov eax, dword [eax]
call eax
add esp, 4
mov eax, dword [edi + 0x19c]
push 0
push esi
mov eax, dword [eax + 4]
call eax
add esp, 8
test al, al
jne 0x4647d9
mov eax, dword [esi]
push esi
mov dword [eax + 0x14], 0x19
mov eax, dword [esi]
mov eax, dword [eax]
call eax
add esp, 4
mov eax, dword [ebp - 0x3c]
inc eax
mov dword [ebp - 0x3c], eax
cmp eax, dword [edi + 0x128]
jb 0x464790
mov eax, dword [edi + 0x190]
push esi
mov eax, dword [eax + 8]
call eax
mov eax, dword [edi + 0x190]
add esp, 4
cmp byte [eax + 0xd], 0
je 0x464774
mov eax, dword [edi + 0x1a0]
push esi
mov eax, dword [eax + 0xc]
call eax
mov eax, dword [edi + 0x30]
push esi
mov eax, dword [eax + 0x10]
call eax
mov eax, dword [edi + 0x1c]
add esp, 8
test eax, eax
je 0x464851
mov eax, dword [eax + 0x24]
push 1
push esi
call eax
add esp, 8
cmp byte [edi + 0x28], 0
je 0x46484a
mov dword [edi + 0x2c], 0xc8
mov dword [edi + 0x12c], 0
jmp 0x464851
mov dword [edi + 0x2c], 0x64
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.0049681b
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret 0x14