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

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff0
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 0xc], ebx
mov dword [ebp - 0x10], ebx
mov dword [ebp - 8], ecx
mov dword [ebp - 4], edx
mov ebx, eax
mov eax, dword [ebp - 4]
call fcn.00405cd8
xor eax, eax
push ebp
push 0x512a95
push dword fs:[eax]
mov dword fs:[eax], esp
push 4
lea eax, [ebp - 0xc]
mov ecx, 1
mov edx, dword [0x50c3d8]
call fcn.00405b54
add esp, 4
xor esi, esi
mov ecx, esi
mov edx, dword [ebp - 4]
mov eax, ebx
call fcn.00511690
mov edx, dword [ebp - 0xc]
mov dword [edx + esi*4], eax
inc esi
cmp esi, 4
jne 0x512421
push 4
lea eax, [ebp - 0x10]
mov ecx, 1
mov edx, dword [0x50c3d8]
call fcn.00405b54
add esp, 4
movzx esi, byte [ebx + 0x14]
cmp esi, 1
jl 0x51269f
mov eax, dword [ebp - 0xc]
mov eax, dword [eax]
mov edx, dword [ebx + 0x18]
mov edx, dword [edx + esi*4]
xor eax, dword [edx]
mov edx, dword [ebp - 0x10]
mov dword [edx], eax
mov eax, dword [ebp - 0xc]
mov eax, dword [eax + 4]
mov edx, dword [ebx + 0x18]
mov edx, dword [edx + esi*4]
xor eax, dword [edx + 4]
mov edx, dword [ebp - 0x10]
mov dword [edx + 4], eax
mov eax, dword [ebp - 0xc]
mov eax, dword [eax + 8]
mov edx, dword [ebx + 0x18]
mov edx, dword [edx + esi*4]
xor eax, dword [edx + 8]
mov edx, dword [ebp - 0x10]
mov dword [edx + 8], eax
mov eax, dword [ebp - 0xc]
mov eax, dword [eax + 0xc]
mov edx, dword [ebx + 0x18]
mov edx, dword [edx + esi*4]
xor eax, dword [edx + 0xc]
mov edx, dword [ebp - 0x10]
mov dword [edx + 0xc], eax
mov eax, dword [ebp - 0x10]
mov edx, dword [eax]
xor ecx, ecx
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov edi, dword [eax*4 + 0x594654]
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 0xc]
mov ecx, 1
mov eax, ebx
call fcn.0051172c
and eax, 0xff
xor edi, dword [eax*4 + 0x594a54]
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 8]
mov ecx, 2
mov eax, ebx
call fcn.0051172c
and eax, 0xff
xor edi, dword [eax*4 + 0x594e54]
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 4]
mov ecx, 3
mov eax, ebx
call fcn.0051172c
and eax, 0xff
xor edi, dword [eax*4 + 0x595254]
mov eax, dword [ebp - 0xc]
mov dword [eax], edi
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 4]
xor ecx, ecx
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov edi, dword [eax*4 + 0x594654]
mov eax, dword [ebp - 0x10]
mov edx, dword [eax]
mov ecx, 1
mov eax, ebx
call fcn.0051172c
and eax, 0xff
xor edi, dword [eax*4 + 0x594a54]
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 0xc]
mov ecx, 2
mov eax, ebx
call fcn.0051172c
and eax, 0xff
xor edi, dword [eax*4 + 0x594e54]
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 8]
mov ecx, 3
mov eax, ebx
call fcn.0051172c
and eax, 0xff
xor edi, dword [eax*4 + 0x595254]
mov eax, dword [ebp - 0xc]
mov dword [eax + 4], edi
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 8]
xor ecx, ecx
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov edi, dword [eax*4 + 0x594654]
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 4]
mov ecx, 1
mov eax, ebx
call fcn.0051172c
and eax, 0xff
xor edi, dword [eax*4 + 0x594a54]
mov eax, dword [ebp - 0x10]
mov edx, dword [eax]
mov ecx, 2
mov eax, ebx
call fcn.0051172c
and eax, 0xff
xor edi, dword [eax*4 + 0x594e54]
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 0xc]
mov ecx, 3
mov eax, ebx
call fcn.0051172c
and eax, 0xff
xor edi, dword [eax*4 + 0x595254]
mov eax, dword [ebp - 0xc]
mov dword [eax + 8], edi
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 0xc]
xor ecx, ecx
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov edi, dword [eax*4 + 0x594654]
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 8]
mov ecx, 1
mov eax, ebx
call fcn.0051172c
and eax, 0xff
xor edi, dword [eax*4 + 0x594a54]
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 4]
mov ecx, 2
mov eax, ebx
call fcn.0051172c
and eax, 0xff
xor edi, dword [eax*4 + 0x594e54]
mov eax, dword [ebp - 0x10]
mov edx, dword [eax]
mov ecx, 3
mov eax, ebx
call fcn.0051172c
and eax, 0xff
xor edi, dword [eax*4 + 0x595254]
mov eax, dword [ebp - 0xc]
mov dword [eax + 0xc], edi
dec esi
test esi, esi
jne 0x51245e
push 0x10
mov eax, dword [ebp - 8]
mov ecx, 1
mov edx, dword [0x47e9c0]
call fcn.00405b54
add esp, 4
mov eax, dword [ebp - 0x10]
mov edx, dword [eax]
xor ecx, ecx
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov al, byte [eax + 0x595754]
push eax
mov eax, dword [ebx + 0x18]
mov eax, dword [eax]
mov edx, dword [eax]
xor ecx, ecx
mov eax, ebx
call fcn.0051172c
pop edx
xor dl, al
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov byte [eax], dl
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 0xc]
mov ecx, 1
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov al, byte [eax + 0x595754]
push eax
mov eax, dword [ebx + 0x18]
mov eax, dword [eax]
mov edx, dword [eax]
mov ecx, 1
mov eax, ebx
call fcn.0051172c
pop edx
xor dl, al
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov byte [eax + 1], dl
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 8]
mov ecx, 2
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov al, byte [eax + 0x595754]
push eax
mov eax, dword [ebx + 0x18]
mov eax, dword [eax]
mov edx, dword [eax]
mov ecx, 2
mov eax, ebx
call fcn.0051172c
pop edx
xor dl, al
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov byte [eax + 2], dl
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 4]
mov ecx, 3
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov al, byte [eax + 0x595754]
push eax
mov eax, dword [ebx + 0x18]
mov eax, dword [eax]
mov edx, dword [eax]
mov ecx, 3
mov eax, ebx
call fcn.0051172c
pop edx
xor dl, al
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov byte [eax + 3], dl
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 4]
xor ecx, ecx
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov al, byte [eax + 0x595754]
push eax
mov eax, dword [ebx + 0x18]
mov eax, dword [eax]
mov edx, dword [eax + 4]
xor ecx, ecx
mov eax, ebx
call fcn.0051172c
pop edx
xor dl, al
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov byte [eax + 4], dl
mov eax, dword [ebp - 0x10]
mov edx, dword [eax]
mov ecx, 1
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov al, byte [eax + 0x595754]
push eax
mov eax, dword [ebx + 0x18]
mov eax, dword [eax]
mov edx, dword [eax + 4]
mov ecx, 1
mov eax, ebx
call fcn.0051172c
pop edx
xor dl, al
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov byte [eax + 5], dl
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 0xc]
mov ecx, 2
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov al, byte [eax + 0x595754]
push eax
mov eax, dword [ebx + 0x18]
mov eax, dword [eax]
mov edx, dword [eax + 4]
mov ecx, 2
mov eax, ebx
call fcn.0051172c
pop edx
xor dl, al
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov byte [eax + 6], dl
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 8]
mov ecx, 3
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov al, byte [eax + 0x595754]
push eax
mov eax, dword [ebx + 0x18]
mov eax, dword [eax]
mov edx, dword [eax + 4]
mov ecx, 3
mov eax, ebx
call fcn.0051172c
pop edx
xor dl, al
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov byte [eax + 7], dl
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 8]
xor ecx, ecx
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov al, byte [eax + 0x595754]
push eax
mov eax, dword [ebx + 0x18]
mov eax, dword [eax]
mov edx, dword [eax + 8]
xor ecx, ecx
mov eax, ebx
call fcn.0051172c
pop edx
xor dl, al
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov byte [eax + 8], dl
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 4]
mov ecx, 1
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov al, byte [eax + 0x595754]
push eax
mov eax, dword [ebx + 0x18]
mov eax, dword [eax]
mov edx, dword [eax + 8]
mov ecx, 1
mov eax, ebx
call fcn.0051172c
pop edx
xor dl, al
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov byte [eax + 9], dl
mov eax, dword [ebp - 0x10]
mov edx, dword [eax]
mov ecx, 2
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov al, byte [eax + 0x595754]
push eax
mov eax, dword [ebx + 0x18]
mov eax, dword [eax]
mov edx, dword [eax + 8]
mov ecx, 2
mov eax, ebx
call fcn.0051172c
pop edx
xor dl, al
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov byte [eax + 0xa], dl
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 0xc]
mov ecx, 3
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov al, byte [eax + 0x595754]
push eax
mov eax, dword [ebx + 0x18]
mov eax, dword [eax]
mov edx, dword [eax + 8]
mov ecx, 3
mov eax, ebx
call fcn.0051172c
pop edx
xor dl, al
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov byte [eax + 0xb], dl
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 0xc]
xor ecx, ecx
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov al, byte [eax + 0x595754]
push eax
mov eax, dword [ebx + 0x18]
mov eax, dword [eax]
mov edx, dword [eax + 0xc]
xor ecx, ecx
mov eax, ebx
call fcn.0051172c
pop edx
xor dl, al
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov byte [eax + 0xc], dl
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 8]
mov ecx, 1
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov al, byte [eax + 0x595754]
push eax
mov eax, dword [ebx + 0x18]
mov eax, dword [eax]
mov edx, dword [eax + 0xc]
mov ecx, 1
mov eax, ebx
call fcn.0051172c
pop edx
xor dl, al
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov byte [eax + 0xd], dl
mov eax, dword [ebp - 0x10]
mov edx, dword [eax + 4]
mov ecx, 2
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov al, byte [eax + 0x595754]
push eax
mov eax, dword [ebx + 0x18]
mov eax, dword [eax]
mov edx, dword [eax + 0xc]
mov ecx, 2
mov eax, ebx
call fcn.0051172c
pop edx
xor dl, al
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov byte [eax + 0xe], dl
mov eax, dword [ebp - 0x10]
mov edx, dword [eax]
mov ecx, 3
mov eax, ebx
call fcn.0051172c
and eax, 0xff
mov al, byte [eax + 0x595754]
push eax
mov eax, dword [ebx + 0x18]
mov eax, dword [eax]
mov edx, dword [eax + 0xc]
mov ecx, 3
mov eax, ebx
call fcn.0051172c
pop edx
xor dl, al
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov byte [eax + 0xf], dl
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x512a9c
lea eax, [ebp - 0x10]
mov edx, dword [0x50c3d8]
mov ecx, 2
call fcn.00405078
lea eax, [ebp - 4]
mov edx, dword [0x47e9c0]
call fcn.00405c74
ret