Function at 0x1004e2b0
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc8
mov eax, dword [0x10195134]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 8]
push ebx
mov ebx, ecx
mov dword [ebp - 0xc8], eax
push esi
push edi
mov dword [ebp - 0xc4], edx
mov eax, dword [ebx]
mov dword [ebp - 0xc0], ebx
mov dword [eax + 8], 0
call fcn.1004d570
mov ecx, dword [ebx]
test eax, eax
jne 0x1004e301
mov edx, dword [ecx + 8]
mov ecx, ebx
push eax
call fcn.1004cc00
jmp 0x1004e924
mov edi, dword [ecx + 8]
mov dword [ebp - 0x90], edi
cmp edi, 3
jne 0x1004e33f
cmp dword [ebx + 0x47ec], edi
je 0x1004e329
cmp dword [ebx + 0x47e8], 0
jne 0x1004e33f
cmp dword [ebx + 0x47e4], 0
jne 0x1004e33f
xorps xmm0, xmm0
mov dword [ebp - 0xa0], 1
movups xmmword [ebp - 0xb8], xmm0
jmp 0x1004e361
mov dword [ebp - 0x90], edi
xorps xmm0, xmm0
mov dword [ebp - 0xa0], 0
movups xmmword [ebp - 0xb8], xmm0
test edi, edi
jle 0x1004e4a3
lea esi, [ebp - 0x80]
mov dword [ebp - 0x9c], 0
lea edx, [ebx + 0x46a0]
mov dword [ebp - 0x94], esi
mov dword [ebp - 0x98], edx
mov eax, dword [ebx]
mov eax, dword [eax]
add eax, 3
push eax
call fcn.100e379d
mov ecx, dword [ebp - 0x98]
add esp, 4
mov dword [ecx + 0x34], eax
test eax, eax
je 0x1004e477
mov eax, dword [ebx + 0x4684]
cdq
idiv dword [ecx]
mov dword [esi], eax
mov dword [ebp - 0xa4], eax
mov eax, dword [ebx + 0x4688]
cdq
idiv dword [ecx + 4]
mov edx, dword [ebp - 0x94]
mov esi, eax
mov eax, dword [ebp - 0xa4]
mov ecx, esi
dec eax
sar ecx, 1
mov dword [edx + 0xc], ecx
mov ecx, dword [ebx]
mov dword [edx + 4], esi
xor edx, edx
mov ecx, dword [ecx]
add eax, ecx
div dword [ebp - 0xa4]
mov ecx, dword [ebp - 0x94]
mov edx, dword [ebp - 0x98]
mov dword [ecx + 8], eax
mov eax, dword [edx + 0x28]
mov dword [ecx - 4], eax
mov dword [ecx - 8], eax
mov eax, dword [ebp - 0xa4]
mov dword [ecx + 0x10], 0
cmp eax, 1
jne 0x1004e424
cmp esi, eax
jne 0x1004e418
mov eax, fcn.10018b90
jmp 0x1004e447
cmp esi, 2
jne 0x1004e442
mov eax, 0x1004d950
jmp 0x1004e447
cmp eax, 2
jne 0x1004e442
cmp esi, 1
jne 0x1004e435
mov eax, 0x1004db80
jmp 0x1004e447
cmp esi, 2
jne 0x1004e442
mov eax, dword [ebx + 0x4814]
jmp 0x1004e447
mov eax, 0x1004dea0
mov dword [ecx - 0xc], eax
add edx, 0x48
mov eax, dword [ebp - 0x9c]
add ecx, 0x20
inc eax
mov dword [ebp - 0x94], ecx
mov dword [ebp - 0x9c], eax
mov esi, ecx
mov dword [ebp - 0x98], edx
cmp eax, edi
jl 0x1004e380
mov ecx, dword [ebx]
jmp 0x1004e4ad
mov edx, dword [ebx]
mov ecx, ebx
push 0
mov edx, dword [edx + 8]
call fcn.1004cc00
mov ecx, dword [0x10198f60]
mov eax, dword fs:[0x2c]
mov eax, dword [eax + ecx*4]
mov dword [eax + 0x10], 0x10139f84
jmp 0x1004e924
mov dword [ebp - 0xa0], 0
mov esi, dword [ecx + 4]
mov ecx, dword [ecx]
test ecx, ecx
js 0x1004e8fd
je 0x1004e4dc
mov eax, 0x7fffffff
cdq
idiv ecx
cmp eax, 4
jl 0x1004e8fd
lea eax, [ecx*4]
test eax, eax
js 0x1004e8fd
test esi, esi
js 0x1004e8fd
je 0x1004e4fd
mov eax, 0x7fffffff
cdq
idiv esi
lea edx, [ecx*4]
cmp edx, eax
jg 0x1004e8fd
imul esi, ecx
shl esi, 2
lea eax, [esi + 1]
push eax
call fcn.100e379d
mov ecx, dword [ebx]
mov edx, eax
add esp, 4
mov dword [ebp - 0x94], edx
test edx, edx
je 0x1004e8ff
xor esi, esi
mov dword [ebp - 0xa4], esi
cmp dword [ecx + 4], esi
jbe 0x1004e8be
mov dword [ebp - 0x94], edx
nop dword [eax + eax]
mov eax, dword [ecx]
imul eax, esi
mov dword [ebp - 0x9c], 0
lea esi, [edx + eax*4]
mov dword [ebp - 0x98], esi
test edi, edi
jle 0x1004e63c
lea edi, [ebx + 0x46bc]
mov ebx, dword [ebp - 0x90]
lea esi, [ebp - 0x74]
nop
mov eax, dword [ebp - 0x94]
mov edx, ebx
mov ecx, dword [ebp - 0xa0]
mov dword [ebp - 0x90], eax
mov dword [ebp - 0x94], eax
mov eax, dword [esi - 8]
sar eax, 1
mov dword [ebp - 0xa8], ecx
mov dword [ebp - 0xa0], ecx
cmp dword [esi], eax
jl 0x1004e5c1
mov ebx, dword [ebp - 0x90]
mov eax, dword [esi - 0x10]
mov ecx, dword [esi - 0x14]
mov dword [ebp - 0x94], ebx
mov ebx, dword [ebp - 0xa8]
mov dword [ebp - 0xa0], ebx
mov ebx, edx
jmp 0x1004e5c7
mov eax, dword [esi - 0x14]
mov ecx, dword [esi - 0x10]
push dword [esi - 0xc]
push dword [esi - 4]
push ecx
push eax
push dword [edi + 0x18]
call dword [esi - 0x18]
mov ecx, dword [ebp - 0x9c]
add esp, 0x14
mov dword [ebp + ecx*4 - 0xb8], eax
mov eax, dword [esi]
inc eax
mov dword [esi], eax
cmp eax, dword [esi - 8]
jl 0x1004e60d
inc dword [esi + 4]
mov eax, dword [esi + 4]
mov edx, dword [esi - 0x10]
mov dword [esi], 0
mov dword [esi - 0x14], edx
cmp eax, dword [edi]
jge 0x1004e60d
mov eax, dword [edi + 4]
add eax, edx
mov dword [esi - 0x10], eax
inc ecx
add esi, 0x20
add edi, 0x48
mov dword [ebp - 0x9c], ecx
cmp ecx, ebx
jl 0x1004e570
mov esi, dword [ebp - 0x98]
mov dword [ebp - 0x90], ebx
mov ebx, dword [ebp - 0xc0]
mov edi, dword [ebp - 0x90]
mov ecx, dword [ebx]
mov eax, dword [ecx + 8]
cmp eax, 3
jne 0x1004e6d9
cmp dword [ebp - 0xa0], 0
je 0x1004e6b2
xor esi, esi
cmp dword [ecx], esi
jbe 0x1004e8a0
mov ecx, dword [ebp - 0x98]
mov edx, dword [ebp - 0xb4]
add ecx, 2
mov edi, dword [ebp - 0xb8]
mov eax, dword [ebp - 0xb0]
sub edi, edx
sub eax, edx
mov dword [ebp - 0xa8], eax
movzx eax, byte [edi + edx]
lea ecx, [ecx + 4]
mov byte [ecx - 6], al
lea edx, [edx + 1]
movzx eax, byte [edx - 1]
inc esi
mov byte [ecx - 5], al
mov eax, dword [ebp - 0xa8]
movzx eax, byte [eax + edx - 1]
mov byte [ecx - 4], al
mov byte [ecx - 3], 0xff
mov eax, dword [ebx]
cmp esi, dword [eax]
jb 0x1004e680
jmp 0x1004e89a
mov eax, dword [ebx + 0x4810]
push 4
push dword [ecx]
push dword [ebp - 0xb0]
push dword [ebp - 0xb4]
push dword [ebp - 0xb8]
push esi
call eax
add esp, 0x18
jmp 0x1004e8a0
cmp eax, 4
jne 0x1004e871
mov eax, dword [ebx + 0x47e8]
test eax, eax
jne 0x1004e7b1
mov dword [ebp - 0x9c], eax
cmp dword [ecx], eax
jbe 0x1004e8a0
mov edx, dword [ebp - 0xac]
add esi, 2
mov ecx, dword [ebp - 0xb4]
mov edi, edx
mov eax, dword [ebp - 0xb8]
sub ecx, edx
mov dword [ebp - 0xa8], ecx
sub eax, edx
mov ecx, dword [ebp - 0xb0]
sub ecx, edx
mov dword [ebp - 0xbc], eax
mov dword [ebp - 0x98], ecx
movzx ecx, byte [eax + edi]
lea esi, [esi + 4]
movzx edx, byte [edi]
lea edi, [edi + 1]
imul ecx, edx
sub ecx, 0xffffff80
mov eax, ecx
shr eax, 8
add eax, ecx
shr eax, 8
mov byte [esi - 6], al
mov eax, dword [ebp - 0xa8]
movzx ecx, byte [eax + edi - 1]
imul ecx, edx
sub ecx, 0xffffff80
mov eax, ecx
shr eax, 8
add eax, ecx
shr eax, 8
mov byte [esi - 5], al
mov eax, dword [ebp - 0x98]
movzx ecx, byte [eax + edi - 1]
imul ecx, edx
mov byte [esi - 3], 0xff
sub ecx, 0xffffff80
mov eax, ecx
shr eax, 8
add eax, ecx
mov ecx, dword [ebp - 0x9c]
shr eax, 8
inc ecx
mov byte [esi - 4], al
mov eax, dword [ebx]
mov dword [ebp - 0x9c], ecx
cmp ecx, dword [eax]
mov eax, dword [ebp - 0xbc]
jb 0x1004e733
jmp 0x1004e89a
mov ecx, dword [ecx]
mov edx, dword [ebx + 0x4810]
push 4
push ecx
push dword [ebp - 0xb0]
push dword [ebp - 0xb4]
push dword [ebp - 0xb8]
push esi
cmp eax, 2
jne 0x1004e86a
call edx
mov eax, dword [ebx]
add esp, 0x18
mov dword [ebp - 0xbc], 0
cmp dword [eax], 0
jbe 0x1004e8a0
mov edi, dword [ebp - 0xbc]
add esi, 2
nop dword [eax + eax]
mov eax, dword [ebp - 0xac]
lea esi, [esi + 4]
movzx edx, byte [edi + eax]
inc edi
movzx eax, byte [esi - 6]
not al
movzx ecx, al
imul ecx, edx
sub ecx, 0xffffff80
mov eax, ecx
shr eax, 8
add eax, ecx
shr eax, 8
mov byte [esi - 6], al
movzx eax, byte [esi - 5]
not al
movzx ecx, al
imul ecx, edx
sub ecx, 0xffffff80
mov eax, ecx
shr eax, 8
add eax, ecx
shr eax, 8
mov byte [esi - 5], al
movzx eax, byte [esi - 4]
not al
movzx ecx, al
imul ecx, edx
sub ecx, 0xffffff80
mov eax, ecx
shr eax, 8
add eax, ecx
shr eax, 8
mov byte [esi - 4], al
mov eax, dword [ebx]
cmp edi, dword [eax]
jb 0x1004e800
jmp 0x1004e89a
call edx
add esp, 0x18
jmp 0x1004e8a0
xor edx, edx
cmp dword [ecx], edx
jbe 0x1004e8a0
mov edi, dword [ebp - 0xb8]
lea ecx, [esi + 1]
mov al, byte [edx + edi]
lea ecx, [ecx + 4]
mov byte [ecx - 3], al
inc edx
mov byte [ecx - 4], al
mov byte [ecx - 5], al
mov byte [ecx - 2], 0xff
mov eax, dword [ebx]
cmp edx, dword [eax]
jb 0x1004e880
mov edi, dword [ebp - 0x90]
mov ecx, dword [ebx]
mov esi, dword [ebp - 0xa4]
mov edx, dword [ebp - 0x94]
inc esi
mov dword [ebp - 0xa4], esi
cmp esi, dword [ecx + 4]
jb 0x1004e540
mov edx, dword [ecx + 8]
mov ecx, ebx
push 0
call fcn.1004cc00
mov ecx, dword [ebx]
add esp, 4
mov eax, dword [ebp - 0xc4]
mov ecx, dword [ecx]
mov dword [eax], ecx
mov ecx, dword [ebx]
mov eax, dword [ebp - 0xc8]
mov ecx, dword [ecx + 4]
mov dword [eax], ecx
mov eax, dword [ebp - 0x94]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.100da971
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebx]
mov edx, dword [ecx + 8]
mov ecx, ebx
push 0
call fcn.1004cc00
mov ecx, dword [0x10198f60]
mov eax, dword fs:[0x2c]
mov eax, dword [eax + ecx*4]
mov dword [eax + 0x10], 0x10139f90
mov ecx, dword [ebp - 8]
add esp, 4
xor ecx, ebp
xor eax, eax
pop edi
pop esi
pop ebx
call fcn.100da971
mov esp, ebp
pop ebp
ret