Skip to content

Commit

Permalink
Add test for deriving ECDH with KDF
Browse files Browse the repository at this point in the history
  • Loading branch information
aveenismail committed Feb 7, 2024
1 parent 91c63e1 commit 1f0c414
Show file tree
Hide file tree
Showing 2 changed files with 533 additions and 0 deletions.
17 changes: 17 additions & 0 deletions pkcs11/tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,12 @@ set (
common.c
)

set (
SOURCE_ECDH_SP800
ecdh_sp800_test.c
common.c
)

set (
SOURCE_AES_ENCRYPT
aes_encrypt_test.c
Expand All @@ -218,6 +224,7 @@ set (
if(NOT ${CMAKE_SYSTEM_NAME} MATCHES "Windows")
add_executable (aes_encrypt_test ${SOURCE_AES_ENCRYPT})
add_executable (ecdh_derive_test ${SOURCE_ECDH_DERIVE})
add_executable (ecdh_sp800_test ${SOURCE_ECDH_SP800})

target_link_libraries(
aes_encrypt_test
Expand All @@ -234,11 +241,21 @@ target_link_libraries (
${LIBCRYPTO_LDFLAGS}
"-ldl")

target_link_libraries (
ecdh_sp800_test
${LIBCRYPTO_LDFLAGS}
"-ldl")

add_test (
NAME ecdh_derive_test
COMMAND ${CMAKE_CURRENT_BINARY_DIR}/ecdh_derive_test ${CMAKE_CURRENT_BINARY_DIR}/../yubihsm_pkcs11.${LIBEXT}
)

add_test (
NAME ecdh_sp800_test
COMMAND ${CMAKE_CURRENT_BINARY_DIR}/ecdh_sp800_test ${CMAKE_CURRENT_BINARY_DIR}/../yubihsm_pkcs11.${LIBEXT}
)

if (NOT ${LIBCRYPTO_VERSION} VERSION_LESS 1.1)
add_executable (rsa_enc_test ${SOURCE_RSA_ENC_TEST})

Expand Down
Loading

0 comments on commit 1f0c414

Please sign in to comment.