Function at 0x100b5070
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x70
push ebx
mov ebx, edx
mov dword [ebp - 0x14], ecx
push esi
push edi
mov dword [ebp - 0x60], ebx
cmp ebx, dword [ebp + 0x18]
jne 0x100b56cf
mov edx, dword [ebp + 0x20]
mov eax, dword [edx + 0x18]
mov edi, dword [edx + 0xc]
mov esi, dword [edx + 0x10]
imul eax, edi
imul eax, esi
cmp ebx, eax
jne 0x100b56cf
mov edx, dword [edx]
mov eax, edi
shr eax, 1
mov dword [ebp - 0x34], eax
mov eax, esi
shr eax, 1
mov dword [ebp - 0x30], eax
lea esi, [edx - 1]
mov eax, dword [ebp + 0x1c]
mov ebx, dword [eax + 8]
mov eax, 1
lea ecx, [ebx - 1]
shl eax, cl
add esi, eax
shr esi, cl
mov dword [ebp - 0x20], esi
cmp esi, 1
jae 0x100b50dc
mov dword [ebp - 0x20], 1
mov ecx, dword [ebp + 0x20]
mov ecx, dword [ecx + 4]
dec ecx
add eax, ecx
lea ecx, [ebx - 1]
shr eax, cl
mov dword [ebp - 0x2c], eax
cmp eax, 1
jae 0x100b50f9
mov dword [ebp - 0x2c], 1
mov eax, dword [ebp + 0x1c]
mov ecx, ebx
dec edx
mov esi, dword [eax]
mov eax, 1
shl eax, cl
inc esi
mov dword [ebp - 0x58], eax
add eax, edx
shr eax, cl
xor edx, edx
dec eax
mov dword [ebp - 0x5c], esi
add eax, edi
div edi
mov dword [ebp - 0x3c], eax
cmp eax, 1
jae 0x100b512a
mov eax, 1
mov dword [ebp - 0x3c], eax
mov edx, dword [ebp + 0x20]
cmp esi, eax
mov eax, dword [ebp + 0x1c]
setae byte [ebp - 3]
mov esi, dword [edx + 0x10]
mov eax, dword [eax + 4]
inc eax
mov dword [ebp - 0x40], eax
mov eax, dword [ebp - 0x58]
dec eax
add eax, dword [edx + 4]
xor edx, edx
shr eax, cl
dec eax
add eax, esi
div esi
mov dword [ebp - 0x44], eax
cmp eax, 1
jae 0x100b5160
mov eax, 1
mov dword [ebp - 0x44], eax
cmp dword [ebp - 0x40], eax
setae byte [ebp - 4]
xor edx, edx
mov dword [ebp - 0x10], edx
test edi, edi
je 0x100b56c6
mov ecx, dword [0x101d4ab4]
mov eax, dword fs:[0x2c]
mov ebx, dword [ebp - 0x34]
lea eax, [eax + ecx*4]
mov dword [ebp - 0x50], eax
mov eax, dword [ebp + 0x20]
lea esp, [esp]
mov ecx, dword [ebp - 0x30]
mov dword [ebp - 0xc], ebx
mov dword [ebp - 0x24], ecx
test edx, edx
jne 0x100b51d7
mov ecx, dword [ebp - 0x5c]
cmp ecx, dword [ebp - 0x3c]
jb 0x100b51d1
mov edx, dword [eax]
mov eax, 1
mov ecx, dword [ebp + 0x1c]
mov ecx, dword [ecx + 8]
shl eax, cl
dec eax
add eax, edx
shr eax, cl
cmp eax, 1
jae 0x100b51c3
mov eax, 1
xor edx, edx
div edi
cmp edx, ebx
ja 0x100b51d1
mov byte [ebp - 1], 1
jmp 0x100b51dd
mov byte [ebp - 1], 0
jmp 0x100b51dd
mov al, byte [ebp - 3]
mov byte [ebp - 1], al
mov eax, dword [ebp + 0x20]
xor ebx, ebx
mov dword [ebp - 0x28], ebx
test esi, esi
je 0x100b56b0
lea ecx, [ecx]
test ebx, ebx
jne 0x100b5230
mov ecx, dword [ebp - 0x40]
cmp ecx, dword [ebp - 0x44]
jb 0x100b522a
mov edx, dword [eax + 4]
mov eax, 1
mov ecx, dword [ebp + 0x1c]
mov ecx, dword [ecx + 8]
shl eax, cl
dec eax
add eax, edx
shr eax, cl
cmp eax, 1
jae 0x100b521b
mov eax, 1
xor edx, edx
div esi
cmp edx, dword [ebp - 0x30]
ja 0x100b522a
mov byte [ebp - 2], 1
jmp 0x100b5236
mov byte [ebp - 2], 0
jmp 0x100b5236
mov al, byte [ebp - 4]
mov byte [ebp - 2], al
mov edi, dword [ebp - 0x10]
test edi, edi
jne 0x100b524b
test ebx, ebx
jne 0x100b5246
mov ebx, dword [ebp + 8]
jmp 0x100b5255
mov ebx, dword [ebp + 0x10]
jmp 0x100b5255
test ebx, ebx
mov ebx, dword [ebp + 0xc]
je 0x100b5255
mov ebx, dword [ebp + 0x14]
cmp byte [ebp - 1], 0
mov dword [ebp - 8], ebx
je 0x100b5298
mov eax, dword [ebp + 0x1c]
mov ecx, dword [eax + 8]
mov eax, dword [ebp + 0x20]
mov edx, dword [eax]
mov eax, 1
shl eax, cl
dec edx
add eax, edx
shr eax, cl
cmp eax, 1
jae 0x100b527f
mov eax, 1
dec eax
xor edx, edx
div dword [ebp - 0x34]
test byte [ebp - 0x20], 1
lea esi, [edx + 1]
mov dword [ebp - 0xc], esi
je 0x100b529b
mov esi, edx
mov dword [ebp - 0xc], esi
jmp 0x100b529b
mov esi, dword [ebp - 0xc]
cmp byte [ebp - 2], 0
je 0x100b52dc
mov eax, dword [ebp + 0x1c]
mov ecx, dword [eax + 8]
mov eax, dword [ebp + 0x20]
mov edx, dword [eax + 4]
mov eax, 1
shl eax, cl
dec edx
add eax, edx
shr eax, cl
cmp eax, 1
jae 0x100b52c3
mov eax, 1
dec eax
xor edx, edx
div dword [ebp - 0x30]
test byte [ebp - 0x2c], 1
lea ecx, [edx + 1]
mov dword [ebp - 0x24], ecx
je 0x100b52df
mov ecx, edx
mov dword [ebp - 0x24], ecx
jmp 0x100b52df
mov ecx, dword [ebp - 0x24]
test ebx, ebx
je 0x100b5699
mov edx, dword [ebp + 0x20]
test ecx, ecx
je 0x100b55c5
lea eax, [esi + edi]
mov dword [ebp - 0x58], ecx
mov edi, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x14]
mov dword [ebp - 0x4c], eax
lea eax, [esi*8]
mov dword [ebp - 0x68], eax
mov eax, dword [ebp - 0x20]
and eax, 1
mov dword [ebp - 0x1c], edi
mov dword [ebp - 0x6c], eax
mov eax, dword [ebp - 0x34]
sub eax, esi
add eax, eax
mov dword [ebp - 0x70], eax
mov esi, dword [edx + 0xc]
mov eax, ebx
or eax, ecx
test al, 0xf
jne 0x100b5448
call fcn.100bce60
cmp eax, 3
jl 0x100b536a
mov ecx, dword [ebp - 0xc]
mov eax, ecx
and eax, 0x80000003
jns 0x100b534d
dec eax
or eax, 0xfffffffc
add eax, 1
jne 0x100b536a
push dword [ebp - 0x60]
mov edx, edi
push dword [ebp - 0x14]
push dword [ebp + 0x18]
push ebx
push esi
push ecx
mov ecx, dword [ebp - 0x10]
call fcn.100b2f90
jmp 0x100b5534
mov edx, dword [ebp - 0x10]
lea eax, [ebx + esi*4]
imul esi, edi
lea ecx, [eax + 4]
mov dword [ebp - 0x54], eax
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x18], ecx
add esi, edx
lea eax, [eax + esi*4]
mov dword [ebp - 0x38], eax
cmp edx, dword [ebp - 0x4c]
jge 0x100b5534
mov eax, dword [ebp - 0x50]
lea edi, [ebx + 2]
mov ebx, dword [ebp - 0x54]
mov edx, dword [eax]
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x64], edx
mov dword [ebp - 0x48], eax
mov eax, dword [0x101d7250]
cmp eax, dword [edx + 4]
jg 0x100b56da
jmp 0x100b53ba
mov ecx, dword [ebp - 0x18]
movzx eax, byte [ebx + 2]
movzx esi, byte [edi + 4]
movzx edx, byte [edi + 3]
add esi, eax
movzx eax, byte [ecx + 2]
add esi, eax
movzx eax, byte [edi]
add esi, eax
movzx eax, byte [edi - 1]
add edx, eax
movzx eax, byte [ebx + 1]
add edx, eax
movzx eax, byte [ecx + 1]
movzx ecx, byte [edi - 2]
add edx, eax
movzx eax, byte [edi + 2]
add edi, 8
add ecx, eax
movzx eax, byte [ebx]
add ecx, eax
add ebx, 8
mov eax, dword [ebp - 0x18]
movzx eax, byte [eax]
add eax, 2
add eax, ecx
mov ecx, dword [ebp - 0x38]
shr eax, 2
mov byte [ecx], al
lea eax, [edx + 2]
mov edx, dword [ebp - 0x64]
shr eax, 2
mov byte [ecx + 1], al
lea eax, [esi + 2]
shr eax, 2
mov byte [ecx + 2], al
mov al, byte [0x101d7254]
mov byte [ecx + 3], al
add ecx, 4
mov dword [ebp - 0x38], ecx
mov ecx, dword [ebp - 0x18]
add ecx, 8
sub dword [ebp - 0x48], 1
mov dword [ebp - 0x18], ecx
jne 0x100b53a4
jmp 0x100b552e
lea eax, [esi*4]
imul esi, edi
lea ecx, [ebx + 4]
add ecx, eax
lea edx, [ebx + 4]
mov dword [ebp - 0x18], ecx
mov ecx, dword [ebp - 0x14]
add esi, dword [ebp - 0x10]
mov dword [ebp - 0x38], edx
lea ecx, [ecx + esi*4]
mov dword [ebp - 0x48], ecx
mov ecx, dword [ebp - 0x4c]
cmp dword [ebp - 0x10], ecx
jge 0x100b5534
mov ecx, dword [ebp - 0x50]
lea ebx, [eax - 3]
mov eax, dword [ebp - 0xc]
lea edi, [edx - 3]
add ebx, edx
mov dword [ebp - 0x54], eax
mov ecx, dword [ecx]
mov dword [ebp - 0x64], ecx
mov edi, edi
mov eax, dword [0x101d7250]
cmp eax, dword [ecx + 4]
jg 0x100b570d
movzx eax, byte [edi + 1]
movzx esi, byte [edi + 5]
mov ecx, dword [ebp - 0x18]
add esi, eax
movzx eax, byte [ebx + 1]
movzx edx, byte [edi + 4]
add esi, eax
movzx eax, byte [ecx + 2]
add esi, eax
movzx eax, byte [ecx + 1]
movzx ecx, byte [edi - 1]
add edx, eax
movzx eax, byte [edi]
add edi, 8
add edx, eax
movzx eax, byte [ebx]
add edx, eax
movzx eax, byte [ebx - 1]
add ecx, eax
add ebx, 8
mov eax, dword [ebp - 0x18]
add dword [ebp - 0x18], 8
movzx eax, byte [eax]
add ecx, eax
mov eax, dword [ebp - 0x38]
add dword [ebp - 0x38], 8
movzx eax, byte [eax]
add eax, 2
add eax, ecx
mov ecx, dword [ebp - 0x48]
shr eax, 2
mov byte [ecx], al
lea eax, [edx + 2]
shr eax, 2
mov byte [ecx + 1], al
lea eax, [esi + 2]
shr eax, 2
mov byte [ecx + 2], al
mov al, byte [0x101d7254]
mov byte [ecx + 3], al
add ecx, 4
sub dword [ebp - 0x54], 1
mov dword [ebp - 0x48], ecx
mov ecx, dword [ebp - 0x64]
jne 0x100b5490
mov edi, dword [ebp - 0x1c]
mov ebx, dword [ebp - 8]
add ebx, dword [ebp - 0x68]
cmp dword [ebp - 0x6c], 0
mov dword [ebp - 8], ebx
je 0x100b55a2
cmp byte [ebp - 1], 0
je 0x100b55a2
mov eax, dword [ebp + 0x20]
movzx esi, byte [ebx]
movzx edi, byte [ebx + 1]
movzx ebx, byte [ebx + 2]
mov edx, dword [eax + 0xc]
mov eax, dword [ebp - 8]
lea ecx, [eax + edx*4]
imul edx, dword [ebp - 0x1c]
movzx eax, byte [ecx]
add esi, eax
movzx eax, byte [ecx + 1]
add edi, eax
movzx eax, byte [ecx + 2]
mov ecx, dword [ebp - 0x14]
add ebx, eax
add edx, dword [ebp - 0xc]
add edx, dword [ebp - 0x10]
lea eax, [esi + 1]
shr eax, 1
mov byte [ecx + edx*4], al
lea eax, [edi + 1]
mov edi, dword [ebp - 0x1c]
shr eax, 1
mov byte [ecx + edx*4 + 1], al
lea eax, [ebx + 1]
mov ebx, dword [ebp - 8]
shr eax, 1
mov byte [ecx + edx*4 + 2], al
mov byte [ecx + edx*4 + 3], 0xff
jmp 0x100b55a5
mov ecx, dword [ebp - 0x14]
mov edx, dword [ebp + 0x20]
inc edi
mov dword [ebp - 0x1c], edi
mov eax, dword [edx + 0xc]
add eax, dword [ebp - 0x70]
sub dword [ebp - 0x58], 1
lea ebx, [ebx + eax*4]
mov dword [ebp - 8], ebx
jne 0x100b5321
mov edi, dword [ebp - 0x10]
mov eax, dword [ebp - 0x2c]
mov ecx, dword [ebp - 0xc]
test al, 1
je 0x100b5658
cmp byte [ebp - 2], 0
je 0x100b5658
lea eax, [ecx + edi]
cmp edi, eax
jge 0x100b564f
mov eax, dword [ebp - 0x28]
lea edi, [ebx + 2]
add eax, dword [ebp - 0x24]
imul eax, dword [edx + 0xc]
mov ebx, dword [ebp - 0x14]
mov dword [ebp - 0x58], ecx
add eax, dword [ebp - 0x10]
inc ebx
lea ebx, [ebx + eax*4]
mov edi, edi
movzx eax, byte [edi + 2]
lea edi, [edi + 8]
movzx ecx, byte [edi - 0xa]
lea ebx, [ebx + 4]
movzx edx, byte [edi - 9]
add ecx, eax
movzx eax, byte [edi - 5]
movzx esi, byte [edi - 8]
add edx, eax
movzx eax, byte [edi - 4]
add esi, eax
mov byte [ebx - 2], 0xff
lea eax, [ecx + 1]
shr eax, 1
mov byte [ebx - 5], al
lea eax, [edx + 1]
shr eax, 1
mov byte [ebx - 4], al
lea eax, [esi + 1]
shr eax, 1
sub dword [ebp - 0x58], 1
mov byte [ebx - 3], al
jne 0x100b5600
mov ebx, dword [ebp - 8]
mov ecx, dword [ebp - 0xc]
mov edi, dword [ebp - 0x10]
mov eax, dword [ebp - 0x2c]
lea ebx, [ebx + ecx*8]
mov dword [ebp - 8], ebx
and eax, dword [ebp - 0x20]
test al, 1
je 0x100b5699
cmp byte [ebp - 1], 0
je 0x100b5699
cmp byte [ebp - 2], 0
je 0x100b5699
mov esi, dword [ebp + 0x20]
mov eax, dword [ebp - 0x28]
add eax, dword [ebp - 0x24]
mov dl, byte [ebx + 1]
imul eax, dword [esi + 0xc]
mov bl, byte [ebx + 2]
add eax, ecx
mov ecx, dword [ebp - 0x14]
add eax, edi
lea ecx, [ecx + eax*4]
mov eax, dword [ebp - 8]
mov al, byte [eax]
mov byte [ecx], al
mov byte [ecx + 1], dl
mov byte [ecx + 2], bl
mov byte [ecx + 3], 0xff
mov eax, dword [ebp + 0x20]
mov ebx, dword [ebp - 0x28]
add ebx, dword [ebp - 0x30]
mov dword [ebp - 0x28], ebx
mov esi, dword [eax + 0x10]
cmp ebx, esi
jb 0x100b51f0
mov edx, dword [ebp - 0x10]
mov ebx, dword [ebp - 0x34]
add edx, ebx
mov edi, dword [eax + 0xc]
mov dword [ebp - 0x10], edx
cmp edx, edi
jb 0x100b5190
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
push 0x80070057
call dword [sym.imp.PhotoBase.dll_void___stdcall_Base::Throw_long_int_]
push 0x101d7250
call fcn.101baee0
add esp, 4
cmp dword [0x101d7250], 0xffffffff
jne 0x100b53b7
push 0x101d7250
mov byte [0x101d7254], 0xff
call fcn.101bae8e
add esp, 4
jmp 0x100b53b7
push 0x101d7250
call fcn.101baee0
add esp, 4
cmp dword [0x101d7250], 0xffffffff
jne 0x100b54a1
push 0x101d7250
mov byte [0x101d7254], 0xff
call fcn.101bae8e
add esp, 4
jmp 0x100b54a1