Skip to content

Commit

Permalink
Merge pull request wolfSSL#6778 from danielinux/writeable_pkcs11_tokens
Browse files Browse the repository at this point in the history
Add compile-time option WOLFSSL_PKCS11_RW_TOKENS
  • Loading branch information
JacobBarthelmeh authored Sep 15, 2023
2 parents 5654691 + ca56b79 commit 1f2ddb7
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions wolfcrypt/src/wc_pkcs11.c
Original file line number Diff line number Diff line change
Expand Up @@ -3755,7 +3755,12 @@ int wc_Pkcs11_CryptoDevCb(int devId, wc_CryptoInfo* info, void* ctx)
int ret = 0;
Pkcs11Token* token = (Pkcs11Token*)ctx;
Pkcs11Session session;

#ifdef WOLFSSL_PKCS11_RW_TOKENS
int readWrite = 1;
#else
int readWrite = 0;
#endif

if (devId <= INVALID_DEVID || info == NULL || ctx == NULL)
ret = BAD_FUNC_ARG;
Expand Down

0 comments on commit 1f2ddb7

Please sign in to comment.