'Illegal key size for this algorithm
From: Ron (namortaror@hotmail.com)
Date: 04/24/03
- Next message: Ron Ross: "Re: Illegal key size for this algorithm"
- Previous message: howard: "Running a Web application with Administrator privileges"
- Next in thread: Alek Davis: "Re: 'Illegal key size for this algorithm"
- Reply: Alek Davis: "Re: 'Illegal key size for this algorithm"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
From: "Ron" <namortaror@hotmail.com> Date: Thu, 24 Apr 2003 13:08:20 -0700
I'm getting the 'Illegal key size for this algorithm '
exception when running my application on Win 98. It runs
fine on XP.
I don't control the client's environment. The application
is a window forms application and it is excpected to be
installed on any .net platform win98 and up. I am
desperate for a solution. The application needs to encode
some personal info prior to sending it over the net (web
service connection) the center. The exacutable is build
on XP and it works fine on XP but not on NT, 98 and 2000.
Please Help.
Here is my implementation of my encription method;
public static byte[] Encrypt(string text, string
rsaPubKey)
{
UTF8Encoding utf8 = new UTF8Encoding();
byte[] plaintext = utf8.GetBytes(text);
RSACryptoServiceProvider rsa = new
RSACryptoServiceProvider();
rsa.FromXmlString(rsaPubKey);
byte[] cipherText = rsa.Encrypt(plaintext, false);
return cipherText;
}
and here is the code that created the keys;
RSACryptoServiceProvider rsa = new
RSACryptoServiceProvider();
publicKye = rsa.ToXmlString(false);
privateKye = rsa.ToXmlString(true);
Any help greatly appreciated,
Ron
- Next message: Ron Ross: "Re: Illegal key size for this algorithm"
- Previous message: howard: "Running a Web application with Administrator privileges"
- Next in thread: Alek Davis: "Re: 'Illegal key size for this algorithm"
- Reply: Alek Davis: "Re: 'Illegal key size for this algorithm"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|