Encrypt plain text input using a modified AES-256 Galois/Counter Mode (GCM) block cipher. Output the hexidecimal representation of the encrypted message with a 128-bit authenication tag adjoined to the end. The modified AES-256 is the same algorithm but with additional AES rounds. Instead of the standard 14 rounds for each block, cycle through the hexidecimal aad provided where each byte is the number of rounds for the current block. Once the aad has completed, start over from the beginning again. Also use the same sequence to determine the authenication tag. All other AES calls outside of the blocks is standard AES. One additional change is that the key expansion is the same but when applying add round key, use the round key modulo 14 (i.e., round 15 should use round key 1, round 20 should use round key 6).
Inputs:
256-bit hexidecimal AES-256 secret key, 96-bit hexidecimal IV, plain text character array, hexidecimal Additional Authenticated Data (aad).
Output:
Hexidecimal representation of the encrypted message with a 128-bit authenication tag (also in hexidecimal) adjoined to the end.

Solution Stats

1 Solutions

1 Solvers

Last Solution submitted on Jul 05, 2026

Last 200 Solutions

Solution Comments

Show comments
Loading...

Problem Recent Solvers1

Suggested Problems

More from this Author65

Problem Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!