Function at 0x100013c0
Capabilities:
Encode data using xor
Encrypt data using aes
Reference aes constants

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
push esi
mov esi, ecx
mov dword [ebp - 0x18], esi
cmp byte [esi + 4], 0
je 0x10001694
mov eax, dword [esi + 0x3cc]
cmp eax, 0x10
jne 0x100013f3
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.10001030
pop esi
mov esp, ebp
pop ebp
ret 8
cdq
and edx, 3
push ebx
push edi
lea edi, [edx + eax]
sar edi, 2
mov dword [ebp - 0x1c], edi
cmp edi, 4
jne 0x1000142e
mov ecx, dword [0x10007b8c]
lea edx, [esi + 0x454]
mov eax, dword [0x10007b84]
mov ebx, edx
mov dword [ebp - 4], ecx
mov ecx, dword [0x10007b94]
mov dword [ebp - 0x10], edx
mov dword [ebp - 8], eax
mov dword [ebp - 0xc], ecx
jmp 0x10001468
cmp edi, 6
mov ecx, 0x20
mov eax, 0x40
cmove eax, ecx
mov edx, dword [eax + 0x10007b84]
mov ecx, dword [eax + 0x10007b8c]
mov eax, dword [eax + 0x10007b94]
mov dword [ebp - 0xc], eax
lea eax, [esi + 0x454]
mov dword [ebp - 8], edx
mov ebx, eax
mov dword [ebp - 4], ecx
mov dword [ebp - 0x10], eax
test edi, edi
jle 0x100014bd
mov eax, dword [ebp + 8]
add esi, 0x1e8
mov dword [ebp - 0x14], edi
mov edi, esi
movzx ecx, byte [eax]
lea eax, [eax + 4]
shl ecx, 0x18
lea edi, [edi + 4]
mov dword [ebx], ecx
mov esi, ebx
movzx edx, byte [eax - 3]
shl edx, 0x10
or edx, ecx
mov dword [ebx], edx
movzx ecx, byte [eax - 2]
shl ecx, 8
or ecx, edx
mov dword [ebx], ecx
movzx edx, byte [eax - 1]
or edx, ecx
mov dword [ebx], edx
add ebx, 4
mov ecx, dword [edi - 4]
xor ecx, edx
sub dword [ebp - 0x14], 1
mov dword [esi], ecx
jne 0x10001476
mov edi, dword [ebp - 0x1c]
mov esi, dword [ebp - 0x18]
mov edx, dword [ebp - 8]
cmp dword [esi + 0x3d0], 1
mov dword [ebp - 0x1c], 1
jle 0x100015b8
lea ecx, [esi + 0x208]
lea eax, [esi + 0x434]
mov dword [ebp - 0x20], ecx
test edi, edi
jle 0x1000157b
mov dword [ebp - 0x14], eax
mov ebx, edx
mov eax, dword [ebp - 4]
mov dword [ebp + 8], ecx
sub eax, edx
mov ecx, dword [ebp - 0xc]
sub ecx, edx
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x24], ecx
mov dword [ebp - 0x18], edi
add eax, ebx
cdq
idiv edi
mov eax, dword [esi + edx*4 + 0x454]
sar eax, 8
movzx ecx, al
mov eax, dword [ebp - 0x24]
add eax, ebx
cdq
idiv edi
mov ecx, dword [ecx*4 + 0x10006270]
movzx eax, byte [esi + edx*4 + 0x454]
xor ecx, dword [eax*4 + 0x10007370]
mov eax, ebx
cdq
inc ebx
idiv edi
movsx eax, word [esi + edx*4 + 0x456]
mov edx, dword [ebp - 0x14]
movzx eax, al
xor ecx, dword [eax*4 + 0x10005270]
movzx eax, byte [edx + 0x23]
xor ecx, dword [eax*4 + 0x10007778]
mov eax, dword [ebp + 8]
xor ecx, dword [eax]
add eax, 4
mov dword [edx], ecx
add edx, 4
sub dword [ebp - 0x18], 1
mov dword [ebp + 8], eax
mov eax, dword [ebp - 0x28]
mov dword [ebp - 0x14], edx
jne 0x10001503
lea eax, [esi + 0x434]
lea ecx, [edi*4]
push ecx
push eax
lea eax, [esi + 0x454]
push eax
call sub.VCRUNTIME140.dll_memcpy
mov eax, dword [ebp - 0x1c]
add esp, 0xc
mov ecx, dword [ebp - 0x20]
inc eax
mov edx, dword [ebp - 8]
add ecx, 0x20
cmp eax, dword [esi + 0x3d0]
mov dword [ebp - 0x1c], eax
lea eax, [esi + 0x434]
mov dword [ebp - 0x20], ecx
jl 0x100014e0
xor ecx, ecx
mov dword [ebp - 0x20], ecx
test edi, edi
jle 0x10001692
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp - 8]
mov dword [ebp + 8], eax
mov eax, dword [ebp - 4]
sub edx, eax
sub dword [ebp - 0xc], eax
mov dword [ebp - 8], edx
nop dword [eax]
mov eax, dword [esi + 0x3d0]
lea eax, [ecx + eax*8]
mov ebx, dword [esi + eax*4 + 0x1e8]
mov ecx, ebx
mov eax, dword [ebp - 0x10]
sar ecx, 0x18
add dword [ebp - 0x10], 4
movzx eax, byte [eax + 3]
xor cl, byte [eax + 0x10005170]
mov eax, dword [ebp + 8]
mov byte [eax], cl
inc eax
mov dword [ebp + 8], eax
mov ecx, ebx
mov eax, dword [ebp - 4]
add eax, edx
sar ecx, 0x10
cdq
idiv edi
movsx eax, word [esi + edx*4 + 0x456]
movzx eax, al
xor cl, byte [eax + 0x10005170]
mov eax, dword [ebp + 8]
mov byte [eax], cl
inc eax
mov dword [ebp + 8], eax
mov ecx, ebx
mov eax, dword [ebp - 4]
cdq
idiv edi
sar ecx, 8
mov eax, dword [esi + edx*4 + 0x454]
sar eax, 8
movzx eax, al
xor cl, byte [eax + 0x10005170]
mov eax, dword [ebp + 8]
mov byte [eax], cl
mov ecx, eax
mov eax, dword [ebp - 4]
add eax, dword [ebp - 0xc]
cdq
idiv edi
inc dword [ebp - 4]
movzx eax, byte [esi + edx*4 + 0x454]
mov edx, dword [ebp - 8]
mov al, byte [eax + 0x10005170]
xor al, bl
mov byte [ecx + 1], al
add ecx, 2
mov dword [ebp + 8], ecx
mov ecx, dword [ebp - 0x20]
inc ecx
mov dword [ebp - 0x20], ecx
cmp ecx, edi
jl 0x100015e0
pop edi
pop ebx
pop esi
mov esp, ebp
pop ebp
ret 8