Skip to content

Conversation

@vogelpi
Copy link
Contributor

@vogelpi vogelpi commented Jan 30, 2026

This is the 17th PR of a series of PRs to upstream support for AES-GCM. The original PR can be found here: vogelpi#19


This PR contains several commits that integrate the new AES-GCM mode into the UVM test bench.

This commit adds the nist_vectors_gcm test to the DV environment.
In this test, the testbench reads in four different NIST AES-GCM
reference vectors and performs encryptions/tag generations/
decryptions. The output is compared to the NIST reference.

Signed-off-by: Pascal Nasahl <[email protected]>
This commit adds the basic aes_gcm_test to the top-level test
framework.

Signed-off-by: Pascal Nasahl <[email protected]>
Only check if we are reseeding when we actually start the cipher
core.

Signed-off-by: Pascal Nasahl <[email protected]>
This commit adds the following parameters to the
c_dpi_aes_crypt_message interface:
- Message length
- AAD Length
- Error result code of the underlying library

Previously, the first two parameters (length) were generate
by simply using the size() of the input vector. However,
as this input vector is always a multiple of 16 bytes,
sub-blocks smaller than 16 bytes are not supported.
As we need this for the AES-GCM mode, add a dedicated
length parameter to the interface.

Moreover, this commit also enables that the
c_dpi_aes_crypt_message function returns the error code
that is generated by the underyling crypto lib.

This is important as, when in GCM mode, a tag mismatch during
decryption is signaled using this error code.

Signed-off-by: Pascal Nasahl <[email protected]>
This commit adds the AES-GCM mode to the base AES DV
sequence. To demonstrate that this is working, this
commit enables the AES-GCM mode in the smoke test.

Signed-off-by: Pascal Nasahl <[email protected]>
This commit enables the AES-GCM mode in the
config_error_test.

Signed-off-by: Pascal Nasahl <[email protected]>
@vogelpi vogelpi requested a review from a team as a code owner January 30, 2026 07:11
@vogelpi vogelpi requested review from andrea-caforio, eshapira and nasahlpa and removed request for a team and eshapira January 30, 2026 07:11
@nasahlpa
Copy link
Member

The failing DV tests should be fixed with:
vogelpi@cf0b04e
and
vogelpi@35db866

@vogelpi
Copy link
Contributor Author

vogelpi commented Jan 30, 2026

Thanks @nasahlpa for your feedback, I should probably combine all these two additional PRs vogelpi#25 and vogelpi#26 into this one then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants