Function at 0x40f0d0
Capabilities:
Encrypt data using aes via x86 extensions

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff0
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
sub esp, 0xe8
push esi
push edi
push ecx
push dword [ebx + 0xc]
mov edi, ecx
mov esi, edx
mov dword [ebp - 0x2c], edi
call fcn.00472020
mov eax, dword [ebx + 0xc]
add esp, 4
add eax, 0xd0
add edi, esi
mov edx, esi
mov dword [ebp - 0xc], eax
mov ecx, edi
push eax
call fcn.00472020
mov ecx, dword [ebx + 0xc]
add esp, 8
mov eax, dword [ebp - 0x2c]
mov edx, dword [ecx + 0xc0]
xor edx, dword [eax + 0x23]
mov dword [ebp - 0x6c], edx
mov edx, dword [ecx + 0xc4]
xor edx, dword [eax + 0x27]
mov eax, dword [edi + 0x23]
xor eax, dword [ecx + 0x190]
mov dword [ebp - 0x80], eax
mov eax, dword [edi + 0x27]
mov edi, ecx
mov dword [ebp - 0x78], edx
xor eax, dword [edi + 0x194]
mov dword [ebp - 0x88], eax
mov eax, dword [edi + 0x1a0]
mov edx, eax
mov dword [ebp - 0x1c], eax
lea esi, [eax + 0x100000]
mov dword [ebp - 0x50], esi
call fcn.0047d820
mov edx, esi
lea ecx, [edi + 0xd0]
call fcn.0047d820
mov ecx, dword [edi + 0x24]
xor ecx, dword [edi + 4]
mov edx, dword [edi + 0xf0]
xor edx, dword [edi + 0xd0]
mov eax, dword [edi + 0x20]
xor eax, dword [edi]
mov esi, dword [edi + 0xf4]
xor esi, dword [edi + 0xd4]
mov dword [ebp - 0x44], ecx
mov dword [ebp - 0x9c], ecx
lea ecx, [edi + 0xd0]
mov dword [ebp - 0x40], eax
mov dword [ebp - 0xa0], eax
mov eax, dword [edi + 0x28]
xor eax, dword [edi + 8]
mov dword [ebp - 0x4c], edx
mov dword [ebp - 0xb0], edx
mov edx, dword [edi + 0x2c]
xor edx, dword [edi + 0xc]
mov dword [ebp - 0x74], eax
mov dword [ebp - 0x98], eax
mov eax, edx
mov dword [ebp - 0x94], eax
mov eax, dword [ecx + 0x28]
xor eax, dword [ecx + 8]
mov ecx, dword [ecx + 0x2c]
xor ecx, dword [edi + 0xdc]
mov dword [ebp - 0x8c], ecx
mov dword [ebp - 0xa4], ecx
mov ecx, dword [edi + 0x38]
xor ecx, dword [edi + 0x18]
mov dword [ebp - 0x84], eax
mov dword [ebp - 0xa8], eax
mov eax, dword [edi + 0x3c]
xor eax, dword [edi + 0x1c]
mov dword [ebp - 0x70], esi
mov dword [ebp - 0xac], esi
mov dword [ebp - 0x3c], edx
mov dword [ebp - 8], ecx
mov ecx, dword [edi + 0x30]
xor ecx, dword [edi + 0x10]
mov dword [ebp - 4], eax
movq xmm0, qword [ebp - 8]
mov eax, dword [edi + 0x34]
xor eax, dword [edi + 0x14]
mov edi, dword [ebp - 0xc]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
movq xmm4, qword [ebp - 8]
mov ecx, dword [edi + 0x38]
xor ecx, dword [edi + 0x18]
mov eax, dword [edi + 0x3c]
xor eax, dword [edi + 0x1c]
mov dword [ebp - 8], ecx
mov ecx, dword [edi + 0x30]
xor ecx, dword [edi + 0x10]
mov dword [ebp - 4], eax
mov eax, dword [edi + 0x34]
xor eax, dword [edi + 0x14]
mov edi, dword [ebp - 0x4c]
punpcklqdq xmm4, xmm0
movq xmm0, qword [ebp - 8]
mov dword [ebp - 4], eax
mov eax, dword [ebp - 0x44]
mov dword [ebp - 8], ecx
movq xmm5, qword [ebp - 8]
mov ecx, dword [ebp - 0x40]
mov dword [ebp - 4], eax
mov eax, dword [ebp - 0x50]
mov dword [ebp - 4], esi
punpcklqdq xmm5, xmm0
mov dword [ebp - 0x2c], 0x40000
lea esi, [eax + 0xb]
mov dword [ebp - 0xbc], esi
lea esi, [eax + 8]
mov dword [ebp - 0xb4], esi
jmp 0x40f2a7
mov eax, dword [ebp - 0x50]
mov edx, dword [ebp - 0x1c]
and ecx, 0xffff0
movq xmm0, qword [ebp - 0x98]
lea esi, [edx + 0xb]
movq xmm1, qword [ebp - 0xa0]
and edi, 0xffff0
punpcklqdq xmm1, xmm0
movups xmm3, xmmword [ecx + edx]
movq xmm0, qword [ebp - 0xa8]
movups xmm2, xmmword [edi + eax]
aesenc xmm3, xmm1
movq xmm1, qword [ebp - 0xb0]
punpcklqdq xmm1, xmm0
movaps xmm0, xmm3
mov dword [ebp - 0x10], ecx
pxor xmm0, xmm4
movups xmmword [ecx + edx], xmm0
aesenc xmm2, xmm1
movaps xmm0, xmm2
movaps xmmword [ebp - 0xd0], xmm3
pxor xmm0, xmm5
movaps xmmword [ebp - 0xe0], xmm2
movups xmmword [edi + eax], xmm0
movaps xmm0, xmm3
mov dl, byte [esi + ecx]
mov al, dl
movzx ecx, dl
and al, 1
shr ecx, 2
add al, al
psrldq xmm0, 4
and ecx, 0xc
or ecx, eax
mov eax, 0x75310
shr eax, cl
mov ecx, dword [ebp - 0x10]
and al, 0x30
xor al, dl
mov byte [esi + ecx], al
mov esi, dword [ebp - 0xbc]
mov dl, byte [esi + edi]
mov al, dl
movzx ecx, dl
and al, 1
shr ecx, 2
add al, al
and ecx, 0xc
or ecx, eax
mov eax, 0x75310
shr eax, cl
xor ecx, ecx
and al, 0x30
xor al, dl
mov byte [esi + edi], al
xor edi, edi
movd eax, xmm3
movd esi, xmm0
movaps xmm0, xmm2
psrldq xmm0, 4
or edi, eax
movd dword [ebp - 0x7c], xmm0
movd eax, xmm2
mov dword [ebp - 0x54], esi
or ecx, eax
mov eax, edi
mov dword [ebp - 0x48], ecx
and eax, 0xffff0
mov ecx, dword [ebp - 0x1c]
add ecx, eax
mov dword [ebp - 0x58], ecx
mov edx, dword [ecx]
mov ecx, dword [ecx + 4]
mov dword [ebp - 0x10], ecx
mov ecx, dword [ebp - 0x1c]
add ecx, 8
mov dword [ebp - 0x34], edx
add eax, ecx
mov dword [ebp - 0x5c], eax
mov ecx, dword [eax]
mov eax, dword [eax + 4]
mov dword [ebp - 0x64], ecx
push 0
push esi
push 0
push edx
mov dword [ebp - 0x28], eax
call fcn.0042bf70
push 0
push edi
push 0
push dword [ebp - 0x34]
mov dword [ebp - 0xc], eax
mov esi, edx
call fcn.0042bf70
push 0
push edi
push 0
push dword [ebp - 0x10]
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x14], edx
call fcn.0042bf70
mov edi, eax
mov ecx, edx
mov eax, dword [ebp - 0xc]
add edi, eax
adc ecx, esi
mov dword [ebp - 0xc], ecx
cmp ecx, esi
ja 0x40f41e
jb 0x40f40e
cmp edi, eax
jae 0x40f41e
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x24], 1
jmp 0x40f432
xorps xmm0, xmm0
movlpd qword [ebp - 8], xmm0
mov eax, dword [ebp - 4]
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 8]
mov dword [ebp - 0x20], eax
mov ecx, dword [ebp - 0x18]
xor esi, esi
add esi, ecx
adc edi, dword [ebp - 0x14]
cmp edi, dword [ebp - 0x14]
ja 0x40f457
jb 0x40f447
cmp esi, ecx
jae 0x40f457
mov dword [ebp - 0x14], 1
mov dword [ebp - 0x18], 0
jmp 0x40f46b
xorps xmm0, xmm0
movlpd qword [ebp - 8], xmm0
mov eax, dword [ebp - 4]
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 8]
mov dword [ebp - 0x14], eax
push 0
push dword [ebp - 0x54]
push 0
push dword [ebp - 0x10]
call fcn.0042bf70
add eax, dword [ebp - 0xc]
mov ecx, dword [ebp - 0x40]
adc edx, 0
add eax, dword [ebp - 0x20]
push 0
adc edx, dword [ebp - 0x24]
add eax, dword [ebp - 0x14]
push dword [ebp - 0x7c]
adc edx, dword [ebp - 0x18]
add ecx, eax
mov eax, dword [ebp - 0x44]
adc eax, edx
add esi, dword [ebp - 0x74]
mov edx, dword [ebp - 0x58]
adc edi, dword [ebp - 0x3c]
xor esi, dword [ebp - 0x6c]
xor edi, dword [ebp - 0x78]
mov dword [edx], ecx
xor ecx, dword [ebp - 0x34]
mov dword [edx + 4], eax
xor eax, dword [ebp - 0x10]
mov edx, dword [ebp - 0x5c]
mov dword [ebp - 4], eax
mov dword [ebp - 0x40], ecx
mov dword [ebp - 0xa0], ecx
mov dword [edx], esi
mov dword [edx + 4], edi
mov edx, dword [ebp - 0x64]
xor edx, esi
mov dword [ebp - 0x44], eax
mov esi, dword [ebp - 0x28]
xor edx, dword [ebp - 0x6c]
xor esi, edi
xor esi, dword [ebp - 0x78]
mov dword [ebp - 0x9c], eax
mov eax, dword [ebp - 0x48]
mov dword [ebp - 0x10], ecx
and eax, 0xffff0
mov ecx, dword [ebp - 0x1c]
add ecx, 0x100000
mov dword [ebp - 0x74], edx
add ecx, eax
mov dword [ebp - 0x98], edx
add eax, dword [ebp - 0xb4]
mov dword [ebp - 0x3c], esi
mov dword [ebp - 0x94], esi
mov edx, dword [ecx]
mov esi, dword [ecx + 4]
mov dword [ebp - 0x58], ecx
mov ecx, dword [eax]
push 0
mov dword [ebp - 0x54], eax
mov eax, dword [eax + 4]
push edx
mov dword [ebp - 0x20], edx
mov dword [ebp - 0xc], esi
mov dword [ebp - 0xb8], ecx
mov dword [ebp - 4], eax
call fcn.0042bf70
push 0
push dword [ebp - 0x48]
mov dword [ebp - 0x28], eax
mov edi, edx
push 0
push dword [ebp - 0x20]
call fcn.0042bf70
push 0
push dword [ebp - 0x48]
mov dword [ebp - 0x64], eax
push 0
push esi
mov dword [ebp - 0x5c], edx
call fcn.0042bf70
mov esi, eax
mov ecx, edx
mov eax, dword [ebp - 0x28]
add esi, eax
adc ecx, edi
mov dword [ebp - 0x28], ecx
cmp ecx, edi
ja 0x40f586
jb 0x40f576
cmp esi, eax
jae 0x40f586
mov dword [ebp - 0x34], 0
mov dword [ebp - 0x18], 1
jmp 0x40f59a
xorps xmm0, xmm0
movlpd qword [ebp - 0x38], xmm0
mov eax, dword [ebp - 0x34]
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 0x38]
mov dword [ebp - 0x34], eax
mov ecx, dword [ebp - 0x64]
xor edi, edi
add edi, ecx
adc esi, dword [ebp - 0x5c]
cmp esi, dword [ebp - 0x5c]
ja 0x40f5bf
jb 0x40f5af
cmp edi, ecx
jae 0x40f5bf
mov dword [ebp - 0x14], 1
mov dword [ebp - 0x24], 0
jmp 0x40f5d3
xorps xmm0, xmm0
movlpd qword [ebp - 0x68], xmm0
mov eax, dword [ebp - 0x64]
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 0x68]
mov dword [ebp - 0x14], eax
push 0
push dword [ebp - 0x7c]
push 0
push dword [ebp - 0xc]
call fcn.0042bf70
add eax, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x4c]
adc edx, 0
movaps xmm4, xmmword [ebp - 0xd0]
add eax, dword [ebp - 0x34]
movaps xmm5, xmmword [ebp - 0xe0]
adc edx, dword [ebp - 0x18]
add eax, dword [ebp - 0x14]
adc edx, dword [ebp - 0x24]
add ecx, eax
mov eax, dword [ebp - 0x70]
adc eax, edx
mov edx, dword [ebp - 0x58]
add edi, dword [ebp - 0x84]
adc esi, dword [ebp - 0x8c]
xor edi, dword [ebp - 0x80]
xor esi, dword [ebp - 0x88]
mov dword [edx], ecx
xor ecx, dword [ebp - 0x20]
mov dword [edx + 4], eax
mov edx, dword [ebp - 0x54]
xor eax, dword [ebp - 0xc]
mov dword [ebp - 0x4c], ecx
mov dword [ebp - 0xb0], ecx
mov dword [edx], edi
mov dword [edx + 4], esi
mov edx, dword [ebp - 0xb8]
xor edx, edi
mov dword [ebp - 0x70], eax
mov edi, dword [ebp - 4]
xor edx, dword [ebp - 0x80]
xor edi, esi
xor edi, dword [ebp - 0x88]
sub dword [ebp - 0x2c], 1
mov dword [ebp - 0x8c], edi
mov dword [ebp - 0xa4], edi
mov edi, ecx
mov ecx, dword [ebp - 0x10]
mov dword [ebp - 0x84], edx
mov dword [ebp - 0xa8], edx
mov dword [ebp - 0xac], eax
mov dword [ebp - 4], eax
jne 0x40f2a4
mov edi, dword [ebx + 0xc]
mov edx, edi
mov ecx, dword [ebp - 0x1c]
call fcn.0047d490
mov ecx, dword [ebp - 0x50]
lea edx, [edi + 0xd0]
call fcn.0047d490
mov ecx, edi
call fcn.00471710
lea ecx, [edi + 0xd0]
call fcn.00471710
movzx eax, byte [edi]
mov esi, dword [ebx + 8]
and eax, 3
push esi
push 0xc8
push edi
mov eax, dword [eax*4 + 0x495ed0]
call eax
movzx ecx, byte [edi + 0xd0]
lea edx, [edi + 0xd0]
add esp, 0xc
lea eax, [esi + 0x20]
and ecx, 3
push eax
mov eax, dword [ecx*4 + 0x495ed0]
push 0xc8
push edx
call eax
add esp, 0xc
pop edi
pop esi
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret