Ondřej Přikryl
Ondřej Přikryl

Reputation: 71

Writing my own CSP (cryptographic service provider)

I have to implement my own csp for signing. I have access to remote certificate storage, which implements functions for signing. Server API has call for listing all certificates. I want to add those certificates to containers. I read csp cookbook, but there is no mention, when I should add those certificates to containers. I implemented pkcs11 module, which is functional on linux. Certificates are added to slots in C_Initialize function. I believe that the first function which is called is CryptAquiareContext so that´s probably the function I was looking for. Is that correct? And what is a difference between CryptAquireContext and CPAquireContext and which function should I use? I would take any advice to make it right. Thank you.

Upvotes: 3

Views: 422

Answers (1)

user2033775
user2033775

Reputation: 153

CryptAquireContext is called by user code. CryptAquireContext function-- enumerates the registred CSP in system registry, then loads appropriate image into memory and pass arguments to the CPAquireContext function. So of CP* function should be exported from your CSP-library.

Upvotes: 1

Related Questions