Dan McDonald wrote:
> Hello.
> 
> I *know* that one is suppoed to have one open PKCS#11 session per slot and
> per thread if you have a multithreaded PKCS#11 app.  What's less clear to me
> is if:
> 
>       - C_Initialize() is done per-thread or prior to thread creation.
>         (I'd suspect once prior to threads, but I'm not sure, hence I'm
>         asking.)

It is once per process.

>       - What about C_GetSlotList()?  My inituition says this is safe either
>           way, but there are no clear docs.

It is safe either way and the output can only grow, never shrink, unless 
you call C_Finalize() and C_Initalize() again.  Prior to v2.20 it could 
never change - the v2.20 revision was one I asked for.

--
Darren J Moffat

Reply via email to