Function at 0x10014b35
Capabilities:
Encode data using xor

Disassembly:
push ebp
lea ebp, [esp - 0x68]
sub esp, 0xe0
push ebx
mov ebx, dword [ebp + 0x78]
push esi
shr ebx, 3
cmp byte [ebp + 0x7c], 0
push edi
je 0x10014b5e
lea ebx, [ebx*8 + 0x10]
lea eax, [ebx - 8]
mov dword [ebp + 0x50], eax
jmp 0x10014b68
lea ebx, [ebx*8 - 8]
mov dword [ebp + 0x50], ebx
mov esi, dword [ebp + 0x70]
cmp dword [esi + 0x14], ebx
jae 0x10014b89
call fcn.10014728
lea eax, [ebx + 1]
push eax
call sub.MSVCRT.dll_malloc
mov dword [esi + 0x10], eax
mov byte [eax + ebx], 0
pop ecx
mov dword [esi + 0x14], ebx
lea eax, [ebp - 0x78]
push eax
push esi
mov dword [esi + 0x18], ebx
call fcn.100149e6
lea eax, [ebp - 0x18]
push eax
lea eax, [esi + 8]
push eax
call fcn.100149e6
cmp byte [ebp + 0x7c], 0
mov edi, dword [esi + 0x10]
je 0x10014c0c
xor esi, esi
call sub.MSVCRT.dll_rand
sar eax, 4
and eax, 0x800000ff
jns 0x10014bc4
dec eax
or eax, 0xffffff00
inc eax
mov byte [ebp + esi + 0x54], al
inc esi
cmp esi, 8
jb 0x10014bae
xor eax, eax
cmp byte [ebp + 0x7c], 1
sete al
and dword [ebp + 0x64], 0
mov esi, eax
mov eax, dword [ebp + 0x64]
and eax, 1
imul eax, eax, 0x60
push esi
push edi
lea ecx, [ebp + 0x54]
lea eax, [ebp + eax - 0x78]
push ecx
call fcn.10014906
xor eax, eax
test esi, esi
sete al
inc dword [ebp + 0x64]
cmp dword [ebp + 0x64], 3
mov esi, eax
jb 0x10014bdd
add edi, 8
jmp 0x10014c14
add dword [ebp + 0x74], 8
sub dword [ebp + 0x78], 8
mov eax, dword [ebp + 0x78]
and dword [ebp + 0x78], 0
cmp dword [ebp + 0x50], 0
mov dword [ebp + 0x5c], eax
jbe 0x10014d45
xor ecx, ecx
cmp byte [ebp + 0x7c], 1
mov esi, edi
sete cl
mov dword [ebp + 0x48], ecx
mov ecx, dword [ebp + 0x74]
sub ecx, edi
mov dword [ebp + 0x4c], ecx
jmp 0x10014c46
mov eax, dword [ebp + 0x5c]
mov ecx, dword [ebp + 0x4c]
test eax, eax
push 8
jne 0x10014c59
lea eax, [ebp + 0x54]
push 8
push eax
call sub.MSVCRT.dll_memset
jmp 0x10014c94
pop edx
cmp eax, edx
jae 0x10014c87
mov ecx, edx
sub ecx, eax
push ecx
sub edx, eax
push edx
lea eax, [ebp + eax + 0x54]
push eax
call sub.MSVCRT.dll_memset
push dword [ebp + 0x5c]
mov eax, dword [ebp + 0x4c]
add eax, esi
push eax
lea eax, [ebp + 0x54]
push eax
call sub.MSVCRT.dll_memcpy
add esp, 0x18
jmp 0x10014c97
push edx
add ecx, esi
push ecx
lea eax, [ebp + 0x54]
push eax
call sub.MSVCRT.dll_memcpy
add esp, 0xc
cmp byte [ebp + 0x7c], 0
je 0x10014cc1
mov eax, dword [ebp + 0x78]
lea eax, [eax + edi - 8]
mov dword [ebp + 0x64], eax
lea eax, [ebp + 0x54]
xor ecx, ecx
sub dword [ebp + 0x64], eax
mov edx, dword [ebp + 0x64]
lea eax, [ebp + ecx + 0x54]
mov dl, byte [edx + eax]
xor byte [eax], dl
inc ecx
cmp ecx, 8
jb 0x10014caf
mov eax, dword [ebp + 0x48]
and dword [ebp + 0x64], 0
mov dword [ebp + 0x60], eax
mov eax, dword [ebp + 0x64]
push dword [ebp + 0x60]
and eax, 1
imul eax, eax, 0x60
push esi
lea ecx, [ebp + 0x54]
lea eax, [ebp + eax - 0x78]
push ecx
call fcn.10014906
xor eax, eax
cmp dword [ebp + 0x60], eax
push 8
sete al
push esi
mov dword [ebp + 0x60], eax
lea eax, [ebp + 0x54]
push eax
call sub.MSVCRT.dll_memcpy
add esp, 0xc
inc dword [ebp + 0x64]
cmp dword [ebp + 0x64], 3
jb 0x10014ccb
cmp byte [ebp + 0x7c], 0
jne 0x10014d2e
mov eax, dword [ebp + 0x74]
mov ecx, dword [ebp + 0x78]
lea ecx, [ecx + eax - 8]
mov eax, esi
sub ecx, esi
mov dword [ebp + 0x60], 8
mov dl, byte [ecx + eax]
xor byte [eax], dl
inc eax
dec dword [ebp + 0x60]
jne 0x10014d23
add dword [ebp + 0x78], 8
mov eax, dword [ebp + 0x78]
sub dword [ebp + 0x5c], 8
add esi, 8
cmp eax, dword [ebp + 0x50]
jb 0x10014c40
cmp byte [ebp + 0x7c], 0
jne 0x10014d84
mov cl, byte [edi + ebx - 1]
cmp cl, 8
ja 0x10014d84
movzx esi, cl
mov edx, ebx
lea eax, [ebx - 2]
sub edx, esi
jmp 0x10014d66
cmp byte [eax + edi], cl
jne 0x10014d84
dec eax
cmp eax, edx
ja 0x10014d60
test cl, cl
je 0x10014d84
push esi
sub edi, esi
push 0
add edi, ebx
push edi
call sub.MSVCRT.dll_memset
mov eax, dword [ebp + 0x70]
add esp, 0xc
sub dword [eax + 0x18], esi
pop edi
pop esi
mov al, 1
pop ebx
add ebp, 0x68
leave
ret 0x10