Topaz Filer - Email filing software
Weak Key...
Messages   Related Types
This message was discovered on microsoft.public.dotnet.framework.


Ciro Fonseca
Hi guys...

I'm having some problems to use the DES class to
encrypt things...

When i pass a Key to the CreateEncryptor method of the
DES class, i get
a "System.Security.Cryptography.CryptographicException:
Specified key is not a valid size for this algorithm."

Well this is the Key that i'm using to Criptography the
text: "s2@$vKT,-_0~`L+lo*&^(lo)[*k]<0xb q]>|!^<kjf ]>[<?/1"

is this a weak key..? if it is... what is the rules to
make a "strong" key..?

Thanks in advance...

[]'s
Ciro Fonseca
Reply to this message...
Vote that this is a GOOD answer...
 
New BootFX DBGet build available
Twitter and Snow… simple #uksnow
 
    
Jun Su [MS]
GOOD ANSWER
Hi,

The key of the DESCryptoServiceProvider must be 64 bytes. You can get the
valid key size from the property LegalKeySizes.

I hope this helps. If you have any questions, please reply to this post.

Best Regards,

Jun Su
Microsoft Support

---
This posting is provided "AS IS" with no warranties, and confers no rights.

--------------------
Content-Class: urn:content-classes:message
From: "Ciro Fonseca" <Click here to reveal e-mail address>
Sender: "Ciro Fonseca" <Click here to reveal e-mail address>
Subject: Weak Key...
Date: Tue, 1 Jan 2002 19:45:32 -0800

Hi guys...

I'm having some problems to use the DES class to
encrypt things...

When i pass a Key to the CreateEncryptor method of the
DES class, i get
a "System.Security.Cryptography.CryptographicException:
Specified key is not a valid size for this algorithm."

Well this is the Key that i'm using to Criptography the
text: "s2@$vKT,-_0~`L+lo*&^(lo)[*k]<0xb q]>|!^<kjf ]>[<?/1"

is this a weak key..? if it is... what is the rules to
make a "strong" key..?

Thanks in advance...

[]'s
Ciro Fonseca

Reply to this message...
Vote that this is a GOOD answer... (2 votes from other users already)
 
 
 
System.Security.Cryptography.CryptographicException
System.Security.Cryptography.DESCryptoServiceProvider




Topaz Filer - Email filing software
Ad
BootFX
Reliable and powerful .NET application framework.
Looking to invest in a major software project? Technical and commercial advice available here.
Other Helpful Sites
MBR 247
Topaz Filer
SharePoint Email Filing
Software Advisory Services
 
Copyright © AMX Software Ltd 2008-2010. Portions copyright © Matthew Baxter-Reynolds 2001-2010. All rights reserved.
Contact Us - Terms of Use - Privacy Policy - 4.0.30129.1734