Skip to content

Commit 1f2ddb7

Browse files
Merge pull request #6778 from danielinux/writeable_pkcs11_tokens
Add compile-time option WOLFSSL_PKCS11_RW_TOKENS
2 parents 5654691 + ca56b79 commit 1f2ddb7

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

wolfcrypt/src/wc_pkcs11.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3755,7 +3755,12 @@ int wc_Pkcs11_CryptoDevCb(int devId, wc_CryptoInfo* info, void* ctx)
37553755
int ret = 0;
37563756
Pkcs11Token* token = (Pkcs11Token*)ctx;
37573757
Pkcs11Session session;
3758+
3759+
#ifdef WOLFSSL_PKCS11_RW_TOKENS
3760+
int readWrite = 1;
3761+
#else
37583762
int readWrite = 0;
3763+
#endif
37593764

37603765
if (devId <= INVALID_DEVID || info == NULL || ctx == NULL)
37613766
ret = BAD_FUNC_ARG;

0 commit comments

Comments
 (0)