Skip to content

testing/crypto: Add pbkdf2 test app#3437

Merged
xiaoxiang781216 merged 1 commit intoapache:masterfrom
PruteanuVlad:add_pbkdf2_support
Mar 27, 2026
Merged

testing/crypto: Add pbkdf2 test app#3437
xiaoxiang781216 merged 1 commit intoapache:masterfrom
PruteanuVlad:add_pbkdf2_support

Conversation

@PruteanuVlad
Copy link
Copy Markdown
Contributor

@PruteanuVlad PruteanuVlad commented Mar 25, 2026

Summary

This adds support for testing PBKDF2 implementation. Test vectors for SHA1 are taken from RFC6070.
SHA256 vectors were extrapolated using an online PBKDF2 generator which was checked against RFC6070.

Impact

This allows for the testing of PBKDF2 implementation.

Modified files:

  • testing/drivers/crypto/CMakeLists.txt - enables app compilation
  • testing/drivers/crypto/Kconfig - add option for test app
  • testing/drivers/crypto/Makefile - enables app compilation
  • testing/drivers/crypto/pbkdf2.c - actual test app

Testing

Development was done using ESP32 DevkitC.
Building was done on Ubuntu 24.04 VM.

nsh> pbkdf2
hmac PBKDF2 SHA1 success
hmac PBKDF2 SHA1 success
hmac PBKDF2 SHA1 success
hmac PBKDF2 SHA1 success
hmac PBKDF2 SHA1 success
hmac PBKDF2 SHA1 success
hmac PBKDF2 SHA256 success
hmac PBKDF2 SHA256 success
hmac PBKDF2 SHA256 success
hmac PBKDF2 SHA256 success
hmac PBKDF2 SHA256 success
hmac PBKDF2 SHA256 success

This adds support for testing PBKDF2 implementation. Test
vectors for SHA1 are taken from RFC6070. SHA256 vectors
were extrapolated using an online PBKDF2 generator which
was checked against RFC6070.

Signed-off-by: Vlad Pruteanu <pruteanuvlad1611@yahoo.com>
Copy link
Copy Markdown
Contributor

@cederom cederom left a comment

Choose a reason for hiding this comment

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

Thank you @PruteanuVlad :-)

@xiaoxiang781216 xiaoxiang781216 merged commit cd2b0c0 into apache:master Mar 27, 2026
40 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants