Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Method C_OpenSession returned CKR_CRYPTOKI_NOT_INITIALIZED #214

Open
lsadehaan opened this issue Nov 8, 2022 · 0 comments
Open

Method C_OpenSession returned CKR_CRYPTOKI_NOT_INITIALIZED #214

lsadehaan opened this issue Nov 8, 2022 · 0 comments

Comments

@lsadehaan
Copy link

I'm using PKCS11Interop v5.1.2 in a long running dotnet core 6 windows service connected to a remote Safenet HSM using the networking interface adaptor from Safenet.
Whenever the service has not been used for a while and I try opening a new session to start a new key operation I get the exception with "Method C_OpenSession returned CKR_CRYPTOKI_NOT_INITIALIZED"
Any ideas on why this happens (I'm guessing it might be within the safenet pkcs11 provider code?) and what I should do to handle this problem gracefully?
Note that it takes 5 minutes for this error response to actually occur, for 5 minutes the application just hangs waiting for a reply.
A restart of the entire application fixes the problem.

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

No branches or pull requests

1 participant