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

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x1c
mov ecx, dword [ebp + 0x10]
mov esi, dword [ebp + 8]
mov ebx, dword [esi]
bswap ebx
xor ebx, dword [ecx]
mov edx, dword [esi + 4]
bswap edx
xor edx, dword [ecx + 4]
mov eax, dword [esi + 8]
bswap eax
xor eax, dword [ecx + 8]
mov edi, dword [esi + 0xc]
bswap edi
xor edi, dword [ecx + 0xc]
mov ecx, dword [ecx + 0xf0]
sar ecx, 1
lea esi, [ecx*8]
mov dword [ebp - 0x1c], esi
dec ecx
mov dword [ebp - 0x28], ecx
mov ecx, dword [ebp + 0x10]
add ecx, 0x2c
mov dword [ebp - 0x20], ecx
mov ecx, ebx
shr ecx, 0x18
mov dword [ebp - 0x14], edi
mov esi, edi
shr esi, 0xe
mov edi, 0x3fc
and esi, edi
mov esi, dword [esi + 0x772dcc]
xor esi, dword [ecx*4 + 0x7729cc]
mov ecx, eax
shr ecx, 8
mov edi, 0xff
and ecx, edi
xor esi, dword [ecx*4 + 0x7731cc]
mov ecx, edx
and ecx, edi
xor esi, dword [ecx*4 + 0x7735cc]
mov dword [ebp - 0x10], esi
mov ecx, edx
mov dword [ebp - 0x24], edx
shr ecx, 0x18
mov dword [ebp - 0x18], ebx
shr ebx, 0xe
mov esi, 0x3fc
and ebx, esi
mov esi, dword [ebx + 0x772dcc]
xor esi, dword [ecx*4 + 0x7729cc]
mov ecx, dword [ebp - 0x14]
shr ecx, 8
mov edi, 0xff
and ecx, edi
xor esi, dword [ecx*4 + 0x7731cc]
mov ecx, eax
and ecx, edi
xor esi, dword [ecx*4 + 0x7735cc]
mov ecx, eax
shr ecx, 0x18
mov ebx, edx
shr ebx, 0xe
mov edi, 0x3fc
and ebx, edi
mov ebx, dword [ebx + 0x772dcc]
xor ebx, dword [ecx*4 + 0x7729cc]
mov ecx, dword [ebp - 0x18]
shr ecx, 8
mov edi, 0xff
and ecx, edi
xor ebx, dword [ecx*4 + 0x7731cc]
mov edi, dword [ebp - 0x14]
mov ecx, edi
mov edx, 0xff
and ecx, edx
xor ebx, dword [ecx*4 + 0x7735cc]
shr edi, 0x18
shr eax, 0xe
mov ecx, 0x3fc
and eax, ecx
mov ecx, dword [eax + 0x772dcc]
xor ecx, dword [edi*4 + 0x7729cc]
mov edx, dword [ebp - 0x24]
shr edx, 8
mov eax, 0xff
and edx, eax
xor ecx, dword [edx*4 + 0x7731cc]
mov edx, dword [ebp - 0x18]
and edx, eax
xor ecx, dword [edx*4 + 0x7735cc]
mov eax, dword [ebp - 0x20]
mov edi, dword [ebp - 0x10]
xor edi, dword [eax - 0x1c]
xor esi, dword [eax - 0x18]
xor ebx, dword [eax - 0x14]
xor ecx, dword [eax - 0x10]
mov eax, dword [ebp - 0x28]
sub eax, 1
mov dword [ebp - 0x10], edi
jb 0x640ea0
mov dword [ebp - 0x28], eax
mov eax, edi
shr eax, 0x18
mov edx, ecx
shr edx, 0xe
mov edi, 0x3fc
and edx, edi
mov edx, dword [edx + 0x772dcc]
xor edx, dword [eax*4 + 0x7729cc]
mov eax, ebx
shr eax, 8
mov edi, 0xff
and eax, edi
xor edx, dword [eax*4 + 0x7731cc]
mov eax, esi
and eax, edi
xor edx, dword [eax*4 + 0x7735cc]
mov dword [ebp - 0x18], edx
mov eax, esi
shr eax, 0x18
mov edx, dword [ebp - 0x10]
shr edx, 0xe
mov edi, 0x3fc
and edx, edi
mov edx, dword [edx + 0x772dcc]
xor edx, dword [eax*4 + 0x7729cc]
mov eax, ecx
shr eax, 8
mov edi, 0xff
and eax, edi
xor edx, dword [eax*4 + 0x7731cc]
mov eax, ebx
and eax, edi
xor edx, dword [eax*4 + 0x7735cc]
mov dword [ebp - 0x24], edx
mov eax, ebx
shr eax, 0x18
mov edx, esi
shr edx, 0xe
mov edi, 0x3fc
and edx, edi
mov edi, 0x3fc
mov dword [ebp - 0x14], esi
mov esi, dword [edx + 0x772dcc]
xor esi, dword [eax*4 + 0x7729cc]
mov eax, dword [ebp - 0x10]
shr eax, 8
mov edx, 0xff
and eax, edx
xor esi, dword [eax*4 + 0x7731cc]
mov eax, ecx
and eax, edx
mov edx, 0xff
xor esi, dword [eax*4 + 0x7735cc]
shr ecx, 0x18
shr ebx, 0xe
and ebx, edi
mov edi, dword [ebx + 0x772dcc]
xor edi, dword [ecx*4 + 0x7729cc]
mov eax, dword [ebp - 0x14]
shr eax, 8
and eax, edx
xor edi, dword [eax*4 + 0x7731cc]
mov ebx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x10]
and eax, edx
xor edi, dword [eax*4 + 0x7735cc]
mov ecx, dword [ebp - 0x20]
xor ebx, dword [ecx - 0xc]
mov edx, dword [ebp - 0x24]
xor edx, dword [ecx - 8]
xor esi, dword [ecx - 4]
mov eax, esi
xor edi, dword [ecx]
add ecx, 0x20
jmp 0x640c60
mov eax, edi
shr eax, 0x18
movzx eax, byte [eax + 0x7739cc]
shl eax, 0x18
mov edx, ecx
shr edx, 0x10
mov edi, 0xff
and edx, edi
movzx edx, byte [edx + 0x7739cc]
shl edx, 0x10
or edx, eax
mov eax, ebx
shr eax, 8
and eax, edi
movzx eax, byte [eax + 0x7739cc]
shl eax, 8
or eax, edx
mov edx, esi
and edx, edi
movzx edx, byte [edx + 0x7739cc]
or edx, eax
mov edi, dword [ebp + 0x10]
mov eax, dword [ebp - 0x1c]
xor edx, dword [edi + eax*4]
bswap edx
mov eax, dword [ebp + 0xc]
mov dword [eax], edx
mov eax, esi
shr eax, 0x18
movzx eax, byte [eax + 0x7739cc]
shl eax, 0x18
mov edx, dword [ebp - 0x10]
shr edx, 0x10
mov edi, 0xff
and edx, edi
movzx edx, byte [edx + 0x7739cc]
shl edx, 0x10
or edx, eax
mov eax, ecx
shr eax, 8
mov edi, 0xff
and eax, edi
mov edi, 0xff
movzx eax, byte [eax + 0x7739cc]
shl eax, 8
or eax, edx
mov edx, ebx
and edx, edi
movzx edx, byte [edx + 0x7739cc]
or edx, eax
mov eax, dword [ebp - 0x1c]
mov edi, dword [ebp + 0x10]
xor edx, dword [edi + eax*4 + 4]
bswap edx
mov eax, dword [ebp + 0xc]
mov dword [eax + 4], edx
mov eax, ebx
shr eax, 0x18
movzx eax, byte [eax + 0x7739cc]
shl eax, 0x18
mov edx, esi
shr edx, 0x10
mov edi, 0xff
and edx, edi
movzx edx, byte [edx + 0x7739cc]
shl edx, 0x10
or edx, eax
mov eax, dword [ebp - 0x10]
shr eax, 8
and eax, edi
mov edi, 0xff
movzx eax, byte [eax + 0x7739cc]
shl eax, 8
or eax, edx
mov edx, ecx
and edx, edi
movzx edx, byte [edx + 0x7739cc]
or edx, eax
mov edi, dword [ebp - 0x1c]
mov eax, dword [ebp + 0x10]
xor edx, dword [eax + edi*4 + 8]
bswap edx
mov eax, dword [ebp + 0xc]
mov dword [eax + 8], edx
shr ecx, 0x18
movzx eax, byte [ecx + 0x7739cc]
shl eax, 0x18
shr ebx, 0x10
mov edx, 0xff
and ebx, edx
movzx ecx, byte [ebx + 0x7739cc]
shl ecx, 0x10
or ecx, eax
shr esi, 8
and esi, edx
mov edx, 0xff
movzx eax, byte [esi + 0x7739cc]
shl eax, 8
or eax, ecx
mov ecx, dword [ebp - 0x10]
and ecx, edx
movzx ecx, byte [ecx + 0x7739cc]
or ecx, eax
mov eax, dword [ebp + 0x10]
xor ecx, dword [eax + edi*4 + 0xc]
bswap ecx
mov eax, dword [ebp + 0xc]
mov dword [eax + 0xc], ecx
add esp, 0x1c
pop esi
pop edi
pop ebx
pop ebp
ret