Wrapper CSP

sbardhan_at_adelphia.net
Date: 09/22/05


Date: 22 Sep 2005 14:23:51 -0700

I am supposed to write a custom CSP and was thinking of starting with
wrapping rsaenh.dll by doing a loadLibrary from within my code and then
calling the appropriate function (CPxx). I have read several posts on
this subject and very very helpful pointers by Laszlo Elteto including
his XP advapi32.dll patching instructions!!!

a) I think I have got most of the preparation work like signing etc
done. But when I run the SDK sample test program and point to my CSP
which calles rsaenh.dll, I get back a 57 (parameter wrong) from within
the base CSP. Anybody faced this?

b) My trivial (not that trivial after all since I cant get this to
work) CSP dll, simply passes the parameters down to the MS CSP. In a
post Laszlo has mentioned that I need to create my own context and pass
that back to the client and hold on to the MS CSP context. What is the
reason for that?

c) I am seeing 2 general ideas of doing the wrapper. Call CryptXXX from
within my CPxxx or call CPxxx (of Base CSP) from my CPxxx. Which is the
correct one? Is one preferred over the other?

Thanks for any pointes.



Relevant Pages

  • Re: Wrapper CSP
    ... A 0x57 return means your CSP had an exception violation; ... the name of the DLL). ... > post Laszlo has mentioned that I need to create my own context and pass ... > within my CPxxx or call CPxxx from my CPxxx. ...
    (microsoft.public.platformsdk.security)
  • Re: Wrapper CSP
    ... I got the CryptXXX way to work but somehow ... the Loadlibraryand CPxxx just wouldn't work for me. ... My CSP is ... wrapping the MS Enhanced Provider and the CSP test utility is showing ...
    (microsoft.public.platformsdk.security)
  • RE: How a custom CSP call MS default (base)CSP?
    ... Load the partilar MS CSP dll ... key handle functions) you need to create your own context ... (usually via allocating a memory block) ... How do I call MS base CSP in my own CSP? ...
    (microsoft.public.platformsdk.security)
  • Re: How a custom CSP call MS default (base)CSP?
    ... You can also just call the standard CryptoAPI routines from your CSP. ... that will automatically validate the signature of the Microsoft CSP during ... CryptAcquireContext, as opposed to taking the default CSP for the type, just ... How do I call MS base CSP in my own CSP? ...
    (microsoft.public.platformsdk.security)
  • Re: Debugging CSP
    ... Currently my CSP is already a wrapper for the MS base CSP, so my CSP load ...
    (microsoft.public.platformsdk.security)