Skip to content

Add test for invalid key size for AEAD mechanisms#226

Merged
robin-nitrokey merged 1 commit into
mainfrom
aead-key-size
Jun 2, 2026
Merged

Add test for invalid key size for AEAD mechanisms#226
robin-nitrokey merged 1 commit into
mainfrom
aead-key-size

Conversation

@robin-nitrokey
Copy link
Copy Markdown
Member

This patch adds a test for the panic on an invalid key size for AEAD mechanisms that was reported by @MG3004 in GHSA-32mp-78p5-q55v and fixed in #224.

This patch adds a test for the panic on an invalid key size for AEAD mechanisms
that was reported by @MG3004 in GHSA-32mp-78p5-q55v and fixed in #224.
Copy link
Copy Markdown
Contributor

@sosthene-nitrokey sosthene-nitrokey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be good to also have some tests with encryption/decryption where the nonce is of the wrong length, especially through unwrap_key because this one could easily be called with user-provided data.

@robin-nitrokey
Copy link
Copy Markdown
Member Author

@sosthene-nitrokey Already prepared. :)

@robin-nitrokey robin-nitrokey merged commit fe42b5d into main Jun 2, 2026
3 checks passed
@robin-nitrokey robin-nitrokey deleted the aead-key-size branch June 2, 2026 11:43
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