need help using CryptoAPI from COM object in IIS5
am 17.04.2006 15:35:06 von radar
I am a newbie for Crypto.... I am attempting to develop a COM/ATL
component that uses the CryptoAPI that I can then use it from
ASP/VBScript. The component works fine when is called from a C++
executable or VB program. Unfortunately when using the component under
VBScript on Win2000/IIS5.0, the component fails on the call to
CryptAcquireContext. The value returned by GetLastError() is 2 (File
not found?). I made sure the iuser_machinename account has fuul access
to the crypto directory under All Users / Apllications Data /
Microsoft. I have tried broadening the privileges of the
iuser_machinename account, but have met with no success.
Does anyone have any pointers on how I can make this work?
Thanks,
Ronnie
radar at pennypublications dot net
Re: need help using CryptoAPI from COM object in IIS5
am 18.04.2006 14:38:03 von radar
OK...
Solution to the above issue was relatively simple.... it just needed a
lot of reading and finding the right document.
Set the CRYPT_MACHINE_KEYSET flag. You can read more about it under
"Using the CRYPT_MACHINE_KEYSET flag" in this Microsoft KB
document:
http://support.microsoft.com/default.aspx?scid=kb%3Ben-us%3B 238187
Thanks,
Ronnie
radar at pennypublications dot net
radar wrote:
> I am a newbie for Crypto.... I am attempting to develop a COM/ATL
> component that uses the CryptoAPI that I can then use it from
> ASP/VBScript. The component works fine when is called from a C++
> executable or VB program. Unfortunately when using the component under
> VBScript on Win2000/IIS5.0, the component fails on the call to
> CryptAcquireContext. The value returned by GetLastError() is 2 (File
> not found?). I made sure the iuser_machinename account has fuul access
> to the crypto directory under All Users / Apllications Data /
> Microsoft. I have tried broadening the privileges of the
> iuser_machinename account, but have met with no success.
>
>
> Does anyone have any pointers on how I can make this work?
>
>
> Thanks,
> Ronnie
> radar at pennypublications dot net