Questions tagged [aes-ni]

Intel's Advanced Encryption Standard (AES) New Instructions (AES-NI) is an extension to the x86 instruction set architecture for microprocessors from Intel and AMD proposed by Intel in March 2008.

The purpose of the instruction set is to improve the speed of applications performing encryption and decryption using the Advanced Encryption Standard (AES).

New instructions

Instruction      Description
AESENC           Perform one round of an AES encryption flow
AESENCLAST       Perform the last round of an AES encryption flow
AESDEC           Perform one round of an AES decryption flow
AESDECLAST       Perform the last round of an AES decryption flow
AESKEYGENASSIST  Assist in AES round key generation
AESIMC           Assist in AES Inverse Mix Columns
PCLMULQDQ        Carryless multiply (CLMUL).
32 questions
2
votes
1 answer

Unable to use Intel AES-NI sample library to encrypt/decrypt in 32-byte block size

I am trying to use the intel_aes_c library with C++ on Visual Studio to create an encryption method that encrypts in 32-byte block sizes, but even when doing a #define BLOCK_SIZE (32) does not really help. In general, I would like to ask how I can…
J. Lim
  • 55
  • 5
1
vote
0 answers

AES multi-core bad performance

I am writing code that uses AES in multi-core, It is very efficient on my laptop 8 core Intel. But when I moving on a machine with more core like 48 - 72 (Xeon) the performance is bad. I think because AES-NI works badly on multi-core because all the…
1
vote
1 answer

Is there a fast way to make IBM's vncipher instruction result the same as Intels mm_aesdec_si128?

I'm porting a application that uses AES encryption and decryption instructions to randomize some data from x86 to POWER8. I hit a wall with the _mm_aesdec_si128 instruction, it seems to do something different than the equivalent IBM…
nioroso
  • 65
  • 8
1
vote
0 answers

_mm_aesimc_si128 not compiled correctly with MSVC

I was reading the AES-NI White Paper and wanted to try it out myself by writing a simple demo program based on the code provided by Intel but I was getting some weird result. It works in Debug/Release x86 and Debug x64 modes but I would get some…
uNiverselEgacy
  • 337
  • 3
  • 14
1
vote
2 answers

Within my c++ program is there a way to check if the CPU has AES-NI

I want to be able to check if a CPU has AES-NI available to it with C++ code on windows. (MinGW GCC) I found a solution to this written in C# with visual studio. Test for AES-NI instructions from C# private static bool IsAESNIPresent() { …
Rahim Khoja
  • 695
  • 13
  • 26
1
vote
0 answers

C++ AES-NI decrypting a 256 bit block

So here's my problem.. I am writing out an AES-NI implementation for a library, and I am stuck on the decryption of a 256 bit block. Here's what I know.. The 128 bit block works perfectly. The encryption of a 256 block aligns with a proven Rijndael…
JGU
  • 879
  • 12
  • 14
1
vote
0 answers

How to check if hardware accelarated AES is supported in Android

I am developing e project where I am doing AES encryption with CBC mode. But I need to know does java AES implementation use Hardware Acceleration (AES-NI CPU instruction set). As far as I know that form lollipop hardware accelerated disk…
Farhana Haque
  • 1,371
  • 14
  • 23
1
vote
1 answer

AES-NI 256-Bit block encryption

I am attempting to use this code which is taken from the intel whitepaper as shown below. My aim is to perform 256-bit block encryption using AES-NI. I have successfully derived the key schedule using the method, this method was provided in the…
user1926691
  • 173
  • 1
  • 3
  • 17
0
votes
1 answer

How many clock cycles does it take to execute AES-NI AESE instruction on Cortex A-78?

AESE is used for single round AES encryption. I want to know how many clock cycles it takes to execute this instruction on an ARM CPU (Cortex A-78). Note that the number cycles that takes to execute a specific instruction is a deterministic number…
Karthik k
  • 21
  • 4
0
votes
1 answer

How to check AES-NI support with __cpuid?

I'm looking for a way to check whether or not does my CPU support AES-NI instructions. I found on the Internet a lot of things, that worked but a lot of them were inline assembly code and since I'm under Microsoft Visual Studio and that I'm…
0
votes
1 answer

Number of independent AES 256 CBC decryption operations per second with AES-NI or GPU acceleration

AES-NI seems to be optimized to encrypt/decrypt big chunks of data. However I'm trying to decrypt a password and I have many very small bits to try (iv + first cbc block, 32 bytes in total). I'm using openssl at the moment, calling…
Dae
  • 45
  • 6
0
votes
0 answers

Do I have to change some codes for using AES_NI?

I got sample codes for using AES_NI from Intel website. (https://software.intel.com/en-us/articles/download-the-intel-aesni-sample-library) However, I dont know how to configure it. What I want to do is, First, I have codes using AES from…
0
votes
0 answers

Does AES-NI supports the AES-GCM Cipher?

AES-NI is to improve the speed of applications performing encryption and decryption using the Advanced Encryption Standard (AES). Does AES-NI supports the AES-GCM cipher as well along AES-CBC? may i know why aesni_gcm_cipher is defined in…
rakesh sharma
  • 129
  • 2
  • 8
0
votes
0 answers

AES-NI 256 Bits block encryption - CBC

I am trying to implement the AES-NI on 256 bits blocks . I have modified the codes based on the Intel whitepaper and below is my modification. extern "C" __declspec(dllexport) void AES_CBC_encrypt(const unsigned char *in, unsigned char *out, …
user1926691
  • 173
  • 1
  • 3
  • 17
0
votes
2 answers

GDB is reporting EXC_BAD_ACCESS, when manipulating SSE2 registers

So I'm trying to code an AESNI library. When I compile my program with symbols and run it in GDB. I get the following error: Program received signal EXC_BAD_ACCESS, Could not access memory. Reason: 13 at address: 0x0000000000000000 Code: (g++ -g…
Nocturnal
  • 683
  • 7
  • 25