Function at 0x408c7f
Capabilities:
Encrypt data using aes
Reference aes constants

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x48
mov eax, dword [ebp + 0x10]
mov esi, dword [ebp + 8]
movzx edx, byte [eax + 3]
movzx ecx, byte [eax]
mov edi, esi
xor edx, dword [esi]
shl ecx, 0x18
xor edx, ecx
movzx ecx, byte [eax + 1]
shl ecx, 0x10
xor edx, ecx
movzx ecx, byte [eax + 2]
shl ecx, 8
xor edx, ecx
movzx ecx, byte [eax + 4]
mov dword [ebp - 0x10], edx
movzx edx, byte [eax + 7]
xor edx, dword [esi + 4]
shl ecx, 0x18
xor edx, ecx
movzx ecx, byte [eax + 5]
shl ecx, 0x10
xor edx, ecx
movzx ecx, byte [eax + 6]
shl ecx, 8
xor edx, ecx
movzx ecx, byte [eax + 8]
mov dword [ebp - 0x14], edx
movzx edx, byte [eax + 0xb]
xor edx, dword [esi + 8]
shl ecx, 0x18
xor edx, ecx
movzx ecx, byte [eax + 9]
shl ecx, 0x10
xor edx, ecx
movzx ecx, byte [eax + 0xa]
mov ebx, edx
movzx edx, byte [eax + 0xc]
shl ecx, 8
shl edx, 0x18
xor ebx, ecx
movzx ecx, byte [eax + 0xf]
xor ecx, dword [esi + 0xc]
xor ecx, edx
movzx edx, byte [eax + 0xd]
movzx eax, byte [eax + 0xe]
shl edx, 0x10
shl eax, 8
xor edx, ecx
xor edx, eax
mov eax, dword [ebp + 0xc]
sar eax, 1
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x54], eax
mov eax, dword [ebp - 0x10]
add edi, 0x20
movzx ecx, byte [ebp - 0x14]
shr eax, 0x18
mov eax, dword [eax*4 + 0x411820]
xor eax, dword [ecx*4 + 0x410c20]
xor eax, dword [edi - 0x10]
mov ecx, eax
mov eax, edx
shr eax, 0x10
movzx eax, al
xor ecx, dword [eax*4 + 0x411420]
mov eax, ecx
movzx ecx, bh
xor eax, dword [ecx*4 + 0x411020]
movzx ecx, bl
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 0x14]
shr eax, 0x18
mov eax, dword [eax*4 + 0x411820]
xor eax, dword [ecx*4 + 0x410c20]
xor eax, dword [edi - 0xc]
mov ecx, eax
mov eax, dword [ebp - 0x10]
shr eax, 0x10
movzx eax, al
xor ecx, dword [eax*4 + 0x411420]
mov eax, ecx
movzx ecx, dh
xor eax, dword [ecx*4 + 0x411020]
movzx ecx, dl
shr edx, 0x18
mov edx, dword [edx*4 + 0x411820]
mov dword [ebp - 0x1c], eax
mov eax, ebx
shr eax, 0x18
mov eax, dword [eax*4 + 0x411820]
shr ebx, 0x10
xor eax, dword [ecx*4 + 0x410c20]
mov ecx, dword [ebp - 0x14]
xor eax, dword [edi - 8]
shr ecx, 0x10
movzx ecx, cl
xor eax, dword [ecx*4 + 0x411420]
mov ecx, dword [ebp - 0x10]
movzx ecx, ch
xor eax, dword [ecx*4 + 0x411020]
movzx ecx, byte [ebp - 0x10]
xor edx, dword [ecx*4 + 0x410c20]
movzx ecx, bl
mov ebx, dword [ebp - 0x14]
xor edx, dword [edi - 4]
xor edx, dword [ecx*4 + 0x411420]
movzx ecx, bh
mov ebx, dword [ebp - 0x18]
xor edx, dword [ecx*4 + 0x411020]
shr ebx, 0x18
mov ecx, edx
shr ecx, 0x10
movzx ecx, cl
mov dword [ebp - 0x10], ecx
movzx ecx, ah
mov dword [ebp - 0x14], ecx
movzx ecx, byte [ebp - 0x1c]
mov dword [ebp - 0x24], ecx
mov ecx, dword [edi]
mov dword [ebp - 0x28], ecx
mov ecx, dword [ebp - 0x1c]
shr ecx, 0x18
mov dword [ebp - 0x2c], ecx
mov ecx, dword [ebp - 0x18]
shr ecx, 0x10
movzx ecx, cl
mov dword [ebp - 0x30], ecx
movzx ecx, dh
mov dword [ebp - 0x34], ecx
movzx ecx, al
mov dword [ebp - 0x38], ecx
mov ecx, eax
shr ecx, 0x18
mov dword [ebp - 0x3c], ecx
mov ecx, dword [ebp - 0x1c]
shr ecx, 0x10
movzx ecx, cl
mov dword [ebp - 0x40], ecx
mov ecx, dword [ebp - 0x18]
movzx ecx, ch
mov dword [ebp - 0x44], ecx
movzx ecx, dl
mov dword [ebp - 0x48], ecx
shr edx, 0x18
mov dword [ebp - 0x4c], edx
shr eax, 0x10
dec dword [ebp - 0x54]
movzx eax, al
mov dword [ebp - 0x50], eax
mov eax, dword [ebp - 0x1c]
movzx eax, ah
mov dword [ebp - 0x1c], eax
movzx eax, byte [ebp - 0x18]
mov dword [ebp - 0x18], eax
je 0x408f4b
mov eax, dword [ebx*4 + 0x411820]
mov ebx, dword [ebp - 0x24]
mov edx, dword [edx*4 + 0x411820]
xor eax, dword [ebx*4 + 0x410c20]
mov ebx, dword [ebp - 0x28]
xor eax, ebx
mov ebx, dword [ebp - 0x10]
xor eax, dword [ebx*4 + 0x411420]
mov ebx, dword [ebp - 0x14]
xor eax, dword [ebx*4 + 0x411020]
mov ebx, dword [ebp - 0x38]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x2c]
mov eax, dword [eax*4 + 0x411820]
xor eax, dword [ebx*4 + 0x410c20]
mov ebx, dword [ebp - 0x30]
xor eax, dword [edi + 4]
xor eax, dword [ebx*4 + 0x411420]
mov ebx, dword [ebp - 0x34]
xor eax, dword [ebx*4 + 0x411020]
mov ebx, dword [ebp - 0x40]
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x3c]
mov eax, dword [eax*4 + 0x411820]
xor eax, dword [ecx*4 + 0x410c20]
xor eax, dword [edi + 8]
xor eax, dword [ebx*4 + 0x411420]
mov ebx, dword [ebp - 0x44]
xor eax, dword [ebx*4 + 0x411020]
mov ebx, eax
mov eax, dword [ebp - 0x18]
xor edx, dword [eax*4 + 0x410c20]
mov eax, dword [ebp - 0x50]
xor edx, dword [edi + 0xc]
xor edx, dword [eax*4 + 0x411420]
mov eax, dword [ebp - 0x1c]
xor edx, dword [eax*4 + 0x411020]
jmp 0x408d29
mov eax, dword [ebp - 0x20]
movzx edx, byte [ebx + 0x410b20]
mov edi, dword [ebp - 0x28]
shl eax, 5
shl edx, 0x18
add eax, esi
mov esi, dword [ebp - 0x24]
movzx ebx, byte [esi + 0x410b20]
mov esi, dword [ebp - 0x10]
xor ebx, edx
movzx edx, byte [esi + 0x410b20]
mov esi, dword [ebp - 0x14]
shl edx, 0x10
movzx ecx, byte [esi + 0x410b20]
xor edx, ebx
mov esi, dword [ebp + 0x14]
shl ecx, 8
xor edx, ecx
xor edx, edi
mov edi, dword [ebp - 0x2c]
bswap edx
mov dword [esi], edx
mov esi, dword [ebp - 0x38]
movzx edx, byte [edi + 0x410b20]
movzx ecx, byte [esi + 0x410b20]
mov edi, dword [ebp - 0x30]
mov esi, dword [ebp - 0x34]
shl edx, 0x18
xor ecx, edx
movzx edx, byte [edi + 0x410b20]
mov edi, dword [ebp + 0x14]
shl edx, 0x10
xor edx, ecx
movzx ecx, byte [esi + 0x410b20]
mov esi, dword [ebp - 0x3c]
shl ecx, 8
xor edx, ecx
xor edx, dword [eax + 4]
bswap edx
mov dword [edi + 4], edx
mov edi, dword [ebp - 0x48]
movzx edx, byte [esi + 0x410b20]
mov esi, dword [ebp - 0x40]
movzx ecx, byte [edi + 0x410b20]
shl edx, 0x18
mov edi, dword [ebp - 0x44]
xor ecx, edx
movzx edx, byte [esi + 0x410b20]
mov esi, dword [ebp + 0x14]
shl edx, 0x10
xor edx, ecx
movzx ecx, byte [edi + 0x410b20]
shl ecx, 8
xor edx, ecx
xor edx, dword [eax + 8]
bswap edx
mov dword [esi + 8], edx
mov edi, dword [ebp - 0x4c]
mov esi, dword [ebp - 0x18]
movzx edx, byte [edi + 0x410b20]
movzx ecx, byte [esi + 0x410b20]
mov edi, dword [ebp - 0x50]
mov esi, dword [ebp - 0x1c]
shl edx, 0x18
xor edx, ecx
movzx ecx, byte [edi + 0x410b20]
mov edi, dword [ebp + 0x14]
shl ecx, 0x10
xor edx, ecx
movzx ecx, byte [esi + 0x410b20]
shl ecx, 8
xor edx, ecx
xor edx, dword [eax + 0xc]
mov eax, edx
bswap eax
mov dword [edi + 0xc], eax
add esp, 0x48
pop ebx
pop esi
pop edi
pop ebp
ret