When calling C_Initialize on the trust module more than once the second call does not return CKR_CRYPTOKI_ALREADY_INITIALIZED as described by PKCS#11. It also does not ignore the second initialization, but leaks/clears all session handles and such.
Created attachment 80327 [details] [review] trust: Fix reinitialization of trust module trust: Fix reinitialization of trust module Track number of C_Initialize calls, and require similar number of C_Finalize calls to finalize. This fixes leaks/disappearing sessions in the trust module.
Attachment 80327 [details] pushed as 3dc38f2 - trust: Fix reinitialization of trust module
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.