Skip to content

aes: expose raw round function API#257

Merged
tarcieri merged 1 commit intomasterfrom
aes/round-function
May 18, 2021
Merged

aes: expose raw round function API#257
tarcieri merged 1 commit intomasterfrom
aes/round-function

Conversation

@tarcieri
Copy link
Member

@tarcieri tarcieri commented May 17, 2021

Closes #252

Exposes a hazmat (more like kryptonite) raw AES round function API intended for use in implementing things like CAESAR candidates (e.g. AEGIS, AEZ, Deoxys)

The current implementation only wraps hardware intrinsics and panics if they aren't available, however the goal is to provide a soft portable fallback as well.

Currently only exposes the "cipher" function (i.e. encryption). However, the goal is to support at least the "equivalent inverse cipher" function (ala Intel AES-NI's AESDEC) as well.

cc @zer0x64

@tarcieri tarcieri requested a review from newpavlov May 17, 2021 23:55
@tarcieri tarcieri marked this pull request as draft May 17, 2021 23:55
@tarcieri tarcieri mentioned this pull request May 17, 2021
@tarcieri tarcieri force-pushed the aes/round-function branch 3 times, most recently from 51ef1f6 to d292ec6 Compare May 18, 2021 00:40
@tarcieri tarcieri changed the title [WIP] aes: expose raw round function API aes: expose raw round function API May 18, 2021
Closes #252

Exposes a `hazmat` (more like kryptonite) raw AES round function API
intended for use in implementing things like CAESAR candidates
(e.g. AEGIS, AEZ, Deoxys)

The current implementation only wraps hardware intrinsics and panics if
they aren't available, however the goal is to provide a soft portable
fallback as well.

Currently only exposes the "cipher" function (i.e. encryption).
However, the goal is to support at least the "equivalent inverse cipher"
function as well.
@tarcieri tarcieri force-pushed the aes/round-function branch from d292ec6 to 727f467 Compare May 18, 2021 00:48
@tarcieri tarcieri marked this pull request as ready for review May 18, 2021 00:49
@tarcieri
Copy link
Member Author

tarcieri commented May 18, 2021

Removing draft/WIP.

I think this is enough to get started, especially for a hazmat feature being used to implement more exotic authenticated ciphers.

I propose to merge this as-is and circle back on implementing a software fallback. Unfortunately "soft" fallback is a little bit tricky due to the way the fixsliced implementation optimizes away various operations by coupling them to the key schedule. But we can get started with this and I can open an issue to address the "soft" fallback.

@tarcieri tarcieri merged commit e69df30 into master May 18, 2021
@tarcieri tarcieri deleted the aes/round-function branch May 18, 2021 01:14
@tarcieri tarcieri mentioned this pull request May 26, 2021
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.

aes: expose round function

1 participant