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

Disassembly:
mov eax, dword [esp + 8]
mov ecx, dword [esp + 4]
push ebp
mov ebp, dword [esp + 0x10]
push ebp
push eax
push ecx
call fcn.10031bc0
add esp, 0xc
test eax, eax
jl 0x100321ef
mov edx, dword [ebp + 0xf0]
push ebx
push esi
xor esi, esi
shl edx, 2
test edx, edx
push edi
jle 0x10031ff5
lea ecx, [ebp + edx*4 + 8]
lea eax, [ebp + 8]
mov ebx, dword [ecx - 8]
mov edi, dword [eax - 8]
mov dword [eax - 8], ebx
mov ebx, dword [ecx - 4]
mov dword [ecx - 8], edi
mov edi, dword [eax - 4]
mov dword [eax - 4], ebx
mov ebx, dword [ecx]
mov dword [ecx - 4], edi
mov edi, dword [eax]
mov dword [eax], ebx
mov ebx, dword [ecx + 4]
mov dword [ecx], edi
mov edi, dword [eax + 4]
mov dword [eax + 4], ebx
mov dword [ecx + 4], edi
add esi, 4
sub edx, 4
add eax, 0x10
sub ecx, 0x10
cmp esi, edx
jl 0x10031fb9
mov eax, dword [ebp + 0xf0]
mov ecx, 1
cmp eax, ecx
jle 0x100321ea
lea eax, [ebp + 1]
mov dl, byte [eax + 0x11]
add eax, 0x10
xor ebx, ebx
and edx, 0xff
mov bl, byte [eax + 2]
mov edx, dword [edx*4 + str.ccccwwww]
mov esi, dword [ebx*4 + str.ccccwwww]
and edx, 0xff
and esi, 0xff
mov edx, dword [edx*4 + 0x1005b200]
mov ebx, dword [esi*4 + 0x1005ae00]
xor edx, ebx
xor ebx, ebx
mov bl, byte [eax]
mov esi, dword [ebx*4 + str.ccccwwww]
and esi, 0xff
mov ebx, dword [esi*4 + 0x1005b600]
mov esi, dword [eax - 1]
and esi, 0xff
xor edx, ebx
xor ebx, ebx
mov esi, dword [esi*4 + str.ccccwwww]
mov bl, byte [eax + 4]
and esi, 0xff
xor edx, dword [esi*4 + 0x1005ba00]
mov dword [eax - 1], edx
mov dl, byte [eax + 5]
mov esi, dword [ebx*4 + str.ccccwwww]
and edx, 0xff
and esi, 0xff
mov edx, dword [edx*4 + str.ccccwwww]
mov ebx, dword [esi*4 + 0x1005b600]
and edx, 0xff
mov edx, dword [edx*4 + 0x1005b200]
xor edx, ebx
xor ebx, ebx
mov bl, byte [eax + 6]
mov esi, dword [ebx*4 + str.ccccwwww]
and esi, 0xff
mov ebx, dword [esi*4 + 0x1005ae00]
mov esi, dword [eax + 3]
and esi, 0xff
xor edx, ebx
xor ebx, ebx
mov esi, dword [esi*4 + str.ccccwwww]
mov bl, byte [eax + 8]
and esi, 0xff
xor edx, dword [esi*4 + 0x1005ba00]
mov dword [eax + 3], edx
mov dl, byte [eax + 9]
mov esi, dword [ebx*4 + str.ccccwwww]
and edx, 0xff
and esi, 0xff
mov edx, dword [edx*4 + str.ccccwwww]
mov ebx, dword [esi*4 + 0x1005b600]
and edx, 0xff
mov edx, dword [edx*4 + 0x1005b200]
xor edx, ebx
xor ebx, ebx
mov bl, byte [eax + 0xa]
mov esi, dword [ebx*4 + str.ccccwwww]
and esi, 0xff
mov ebx, dword [esi*4 + 0x1005ae00]
mov esi, dword [eax + 7]
and esi, 0xff
xor edx, ebx
xor ebx, ebx
mov esi, dword [esi*4 + str.ccccwwww]
mov bl, byte [eax + 0xc]
and esi, 0xff
xor edx, dword [esi*4 + 0x1005ba00]
mov dword [eax + 7], edx
mov dl, byte [eax + 0xd]
mov esi, dword [ebx*4 + str.ccccwwww]
and edx, 0xff
mov edx, dword [edx*4 + str.ccccwwww]
and edx, 0xff
and esi, 0xff
mov edx, dword [edx*4 + 0x1005b200]
mov ebx, dword [esi*4 + 0x1005b600]
xor edx, ebx
xor ebx, ebx
mov bl, byte [eax + 0xe]
mov esi, dword [ebx*4 + str.ccccwwww]
and esi, 0xff
mov ebx, dword [esi*4 + 0x1005ae00]
mov esi, dword [eax + 0xb]
and esi, 0xff
xor edx, ebx
mov esi, dword [esi*4 + str.ccccwwww]
and esi, 0xff
mov edi, dword [esi*4 + 0x1005ba00]
xor edx, edi
inc ecx
mov dword [eax + 0xb], edx
mov edx, dword [ebp + 0xf0]
cmp ecx, edx
jl 0x1003200b
pop edi
pop esi
xor eax, eax
pop ebx
pop ebp
ret