Function at 0x49223a
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
xor edx, edx
mov ecx, ebx
mov dword [ebp - 8], ebx
call fcn.0049742a
mov eax, ebx
mov dword [ebp - 0x20], edi
add esp, 4
mov dword [ebp - 4], edi
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x30], 3
xor ebx, ebx
xor ecx, ecx
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x1c], ecx
nop dword [eax + eax]
xor edi, edi
mov dword [ebp - 0x10], edi
xor esi, esi
test ecx, ecx
js 0x4922b6
lea eax, [eax + edi*8]
add eax, ecx
mov dword [ebp - 0x28], eax
xor ecx, ecx
mov edx, edi
cmp esi, ebx
cmovl edx, dword [ebp - 0x30]
test edx, edx
je 0x4922b1
mov edi, dword [eax]
mov eax, dword [ebp - 0x20]
mov ebx, dword [ebp - 8]
add eax, esi
lea eax, [ebx + eax*4]
mov ebx, dword [ebp - 0x18]
cmp edi, dword [eax]
je 0x492521
inc ecx
add eax, 8
cmp ecx, edx
jl 0x49229b
mov edi, dword [ebp - 0x10]
mov eax, dword [ebp - 0x28]
inc esi
cmp esi, ebx
jle 0x49227d
mov eax, dword [ebp - 4]
xor ecx, ecx
mov edx, dword [ebp - 0xc]
add eax, edi
mov esi, dword [ebp - 8]
add edx, 0x12138
mov dword [ebp - 0x28], ecx
lea eax, [ebx + eax*2]
shl eax, 2
add edx, eax
add esi, eax
xor eax, eax
mov dword [ebp - 0x34], edx
mov dword [ebp - 0x3c], esi
mov dword [ebp - 0x24], eax
mov ebx, dword [edx]
add ebx, eax
mov eax, dword [esi]
mov ax, word [ecx + eax]
add ax, ax
movzx ecx, ax
mov eax, ecx
mov edx, ecx
shr eax, 1
mov edi, ecx
or ecx, eax
mov eax, ecx
shr eax, 2
or ecx, eax
mov eax, ecx
shr eax, 4
or ecx, eax
mov eax, ecx
shr eax, 8
or eax, ecx
shr eax, 1
inc eax
imul eax, eax, 0x77cb531
shr eax, 0x1b
movzx esi, byte [eax + 0x4a36d4]
xor eax, eax
cmp eax, edx
sbb eax, eax
xor edx, edx
neg eax
dec eax
add esi, eax
mov eax, 1
mov word [ebx + 2], si
lea ecx, [esi + 0x10]
mov esi, dword [ebp - 0x3c]
shl eax, cl
div edi
mov ecx, dword [ebp - 0x28]
mov edx, dword [ebp - 0x34]
inc eax
mov word [ebx], ax
add ecx, 2
mov eax, dword [ebp - 0x24]
add eax, 4
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x24], eax
cmp eax, 0x100
jl 0x4922e1
mov ebx, dword [ebp - 0x18]
mov edi, dword [ebp - 0x10]
mov esi, dword [ebp - 4]
mov edx, dword [ebp - 0xc]
mov ecx, dword [ebp - 0x1c]
inc edi
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x10], edi
cmp edi, 3
jl 0x49226f
add ecx, 4
inc ebx
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x1c], ecx
cmp ecx, 8
jl 0x49226a
add dword [ebp - 0x20], 6
add esi, 3
add eax, 0x18
mov dword [ebp - 4], esi
mov dword [ebp - 0x14], eax
cmp esi, 0xc0
jl 0x49225b
mov eax, dword [ebp - 0x2c]
mov esi, 0x4a38d0
mov dword [ebp - 0x14], esi
movups xmm0, xmmword [eax + 0x100]
movups xmmword [edx + 0xc920], xmm0
movups xmm0, xmmword [eax + 0x110]
movups xmmword [edx + 0xc930], xmm0
movups xmm0, xmmword [eax + 0x120]
movups xmmword [edx + 0xc940], xmm0
movups xmm0, xmmword [eax + 0x130]
mov eax, dword [edx + 0x30]
movups xmmword [edx + 0xc950], xmm0
add edx, 0x2a738
lea eax, [eax + eax*2]
lea ecx, [eax*2 + 0x4a3830]
mov eax, dword [ebp - 8]
mov dword [ebp - 4], ecx
nop word [eax + eax]
mov dword [ebp - 0x10], edx
mov dword [ebp - 0xc], 0x40
nop word [eax + eax]
xorps xmm0, xmm0
mov dword [ebp - 0x1c], ecx
movlpd qword [ebp - 0x40], xmm0
mov ecx, dword [ebp - 0x3c]
mov dword [ebp - 0x24], ecx
mov ecx, dword [ebp - 0x40]
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x18], 3
mov dword [ebp - 0x28], ecx
mov edx, dword [eax]
xor edi, edi
mov dword [ebp - 0x2c], 0
mov ebx, esi
mov dword [ebp - 0x3c], edx
movzx eax, byte [edi + 0x4a34d0]
lea ebx, [ebx + 2]
movzx ecx, word [ebx - 2]
inc edi
movzx esi, word [edx + eax*2]
xor edx, edx
mov eax, esi
shr eax, 1
add eax, ecx
mov ecx, dword [ebp - 0x2c]
div esi
mov edx, dword [ebp - 0x3c]
imul eax, eax
add ecx, eax
mov dword [ebp - 0x2c], ecx
cmp edi, 0x40
jl 0x49245b
mov esi, dword [ebp - 0x1c]
push 0
push ecx
movzx eax, word [esi]
cdq
push edx
push eax
call 0x51d33a
mov ebx, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x24]
add ebx, eax
mov eax, dword [ebp - 0x20]
adc ecx, edx
mov dword [ebp - 0x28], ebx
add esi, 2
mov dword [ebp - 0x24], ecx
add eax, 8
mov dword [ebp - 0x1c], esi
sub dword [ebp - 0x18], 1
mov esi, dword [ebp - 0x14]
mov dword [ebp - 0x20], eax
jne 0x49244b
push ecx
push ebx
call fcn.0049b80a
xor ecx, ecx
add esp, 8
sub ecx, eax
mov eax, 0x60000000
sbb eax, edx
mov edx, dword [ebp - 0x10]
shrd ecx, eax, 1
sar eax, 1
mov dword [edx], ecx
mov ecx, dword [ebp - 4]
mov dword [edx + 4], eax
add edx, 8
sub dword [ebp - 0xc], 1
mov eax, dword [ebp - 0x20]
mov dword [ebp - 0x10], edx
jne 0x49242a
mov eax, dword [ebp - 8]
sub esi, 0xffffff80
add eax, 4
mov dword [ebp - 0x14], esi
mov dword [ebp - 8], eax
cmp esi, 0x4a39d0
jl 0x49241a
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 4]
mov edi, dword [ebp - 0x10]
add eax, ecx
lea edx, [esi + eax*2]
mov esi, dword [ebp - 4]
lea eax, [esi + edi]
lea ecx, [ebx + eax*2]
mov eax, dword [ebp - 0xc]
mov eax, dword [eax + edx*4 + 0x12138]
mov edx, dword [ebp - 0xc]
mov dword [edx + ecx*4 + 0x12138], eax
jmp 0x492373