From: andrew lowe (andrew)
Date: Tue, 29 Jul 2003 09:52:44 +1000
"Jan Vanek" <firstname.lastname@example.org> wrote in message
> Hi all!
> I have problem with subj. I tried to use it in ASP.NET application under
> and .NET framework 1.0 but I'm unable to get this object using any
> constructor. I'm always getting this error : CryptoAPI cryptographic
> provider (CSP) for this implementation could not be acquired. Same
> is with DSACryp... Strange is that using same source file it works under W
> XP and .NET 1.1. It also works making Win application or in install
> on W2k and framework 1.0.
> Does anybody knows what the hell I should do to be able to use it?
The ASP.NET account does not have a key container store because it is not an
interactive account, so you'll have to use the machines key store. This can
ben done by setting the Flags property of the CspParameters object that you
pass to the RSACryptographicServiceProvdier constructor, eg:
cspParameters.Flags = CspProviderFlags.UseMachineStore