Function at 0x100b4636
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x20
mov al, byte [esp + 0x50]
mov dword [esp + 8], edx
mov dword [esp + 0x10], ecx
mov ecx, dword [esp + 0x44]
mov edx, dword [esp + 0x3c]
mov ebx, dword [esp + 0x34]
test al, al
je 0x100b477e
cmp edx, ecx
jge 0x100b4917
mov al, byte [esp + 0x4c]
xor edx, edx
mov ecx, 0xfffffc01
lea esi, [ebx + 1]
mov dword [esp + 0x18], esi
test al, al
cmove ecx, edx
xor al, 1
movzx eax, al
mov dword [esp + 0xc], ecx
lea ecx, [ebx*4]
shl eax, 0xa
mov dword [esp + 0x14], ecx
or eax, 0x3ff
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x38]
mov dword [esp + 4], edx
cmp eax, dword [esp + 0x40]
jge 0x100b474b
mov eax, dword [esp + 8]
xor edx, edx
mov dword [esp], eax
test ebx, ebx
mov ebx, dword [esp + 0x18]
jle 0x100b4721
mov eax, dword [esp + 0x10]
cmp byte [esp + 0x4c], 0
mov edi, edx
mov ecx, dword [eax + ebx*4 - 8]
movzx eax, byte [ecx]
movzx esi, byte [ecx + 1]
movsx ebp, al
cmove ebp, eax
push dword [esp + 4]
call fcn.100b53bc
add esp, 4
cmp esi, 0x10
lea ecx, [ebp*8 + 4]
jb 0x100b46fc
shr esi, 4
imul eax, esi
shl eax, 3
mov edx, dword [esp + 0x1c]
add eax, ecx
mov ecx, eax
cmp edx, eax
cmovle ecx, edx
mov edx, dword [esp + 0xc]
cmp edx, eax
cmovg ecx, edx
mov edx, dword [esp]
mov dword [edx + ebx*4 - 8], ecx
dec ebx
mov edx, edi
cmp ebx, 1
jg 0x100b46bf
mov ebx, dword [esp + 0x34]
lea eax, [edx + 1]
cmp eax, 3
ja 0x100b474b
mov ecx, dword [esp]
add ecx, dword [esp + 0x14]
mov dword [esp], ecx
mov ecx, dword [esp + 0x38]
lea ecx, [edx + ecx + 1]
mov edx, eax
cmp ecx, dword [esp + 0x40]
jl 0x100b46b7
mov ebp, dword [esp + 4]
mov edx, dword [esp + 0x44]
mov esi, dword [esp + 0x3c]
lea eax, [ebp + 1]
cmp eax, 3
ja 0x100b4917
mov ecx, dword [esp + 0x48]
add dword [esp + 8], ecx
lea ecx, [ebp + esi + 1]
cmp ecx, edx
mov edx, eax
jl 0x100b469c
jmp 0x100b4917
cmp byte [esp + 0x4c], 0
je 0x100b4855
cmp edx, ecx
jge 0x100b4917
lea eax, [ebx + 1]
mov dword [esp + 0xc], eax
xor eax, eax
mov ecx, dword [esp + 0x38]
mov dword [esp + 4], eax
cmp ecx, dword [esp + 0x40]
jge 0x100b4824
mov eax, dword [esp + 8]
xor edx, edx
mov dword [esp], eax
mov esi, dword [esp + 0xc]
test ebx, ebx
jle 0x100b4805
mov eax, dword [esp + 0x10]
mov edi, edx
mov ebp, dword [eax + esi*4 - 8]
movsx ebx, byte [ebp]
mov ecx, ebp
push dword [esp + 4]
call fcn.100b53bc
add esp, 4
movzx ecx, byte [ebp + 1]
shr ecx, 4
imul ecx, eax
mov eax, 0x7f
add ecx, ebx
cmp ecx, 0x80
cmovge ecx, eax
cmp ecx, 0xffffff80
jg 0x100b47f6
mov cl, 0x80
mov eax, dword [esp]
mov edx, edi
mov byte [eax + esi - 2], cl
dec esi
cmp esi, 1
jg 0x100b47b9
mov ebx, dword [esp + 0x34]
lea eax, [edx + 1]
cmp eax, 3
ja 0x100b4824
mov ecx, dword [esp + 0x38]
add dword [esp], ebx
lea ecx, [edx + ecx + 1]
mov edx, eax
cmp ecx, dword [esp + 0x40]
jl 0x100b47b1
mov edi, dword [esp + 4]
mov edx, dword [esp + 0x44]
mov esi, dword [esp + 0x3c]
lea eax, [edi + 1]
cmp eax, 3
ja 0x100b4917
mov ecx, dword [esp + 0x48]
add dword [esp + 8], ecx
lea ecx, [edi + esi + 1]
cmp ecx, edx
jl 0x100b479a
jmp 0x100b4917
cmp edx, ecx
jge 0x100b4917
lea eax, [ebx + 1]
mov dword [esp + 0xc], eax
xor eax, eax
mov ecx, dword [esp + 0x38]
mov dword [esp + 4], eax
cmp ecx, dword [esp + 0x40]
jge 0x100b48ef
mov eax, dword [esp + 8]
xor edx, edx
mov dword [esp], eax
mov esi, dword [esp + 0xc]
test ebx, ebx
jle 0x100b48d0
mov eax, dword [esp + 0x10]
mov edi, edx
mov ebp, dword [eax + esi*4 - 8]
movzx ebx, byte [ebp]
mov ecx, ebp
push dword [esp + 4]
call fcn.100b53bc
add esp, 4
movzx ecx, byte [ebp + 1]
shr ecx, 4
imul ecx, eax
mov eax, 0xff
add ecx, ebx
cmp ecx, 0x100
cmovge ecx, eax
test ecx, ecx
jg 0x100b48c1
xor ecx, ecx
mov eax, dword [esp]
mov edx, edi
mov byte [eax + esi - 2], cl
dec esi
cmp esi, 1
jg 0x100b4885
mov ebx, dword [esp + 0x34]
lea eax, [edx + 1]
cmp eax, 3
ja 0x100b48ef
mov ecx, dword [esp + 0x38]
add dword [esp], ebx
lea ecx, [edx + ecx + 1]
mov edx, eax
cmp ecx, dword [esp + 0x40]
jl 0x100b487d
mov edi, dword [esp + 4]
mov edx, dword [esp + 0x44]
mov esi, dword [esp + 0x3c]
lea eax, [edi + 1]
cmp eax, 3
ja 0x100b4917
mov ecx, dword [esp + 0x48]
add dword [esp + 8], ecx
lea ecx, [edi + esi + 1]
cmp ecx, edx
jl 0x100b4866
add esp, 0x20
pop esi
pop edi
pop ebx
pop ebp
ret