Re: How to encrypt/decrypt a file
- From: "Valery Pryamikov" <valery@xxxxxxxxx>
- Date: Sat, 18 Feb 2006 01:06:54 +0100
you misread what I wrote. Salt for PasswordDeriveBytes is important. Salt appended to plain text before encryption (as you done it in your sample) is redundant if IV is random. Your sample is more secure than Ivan's sample who is simply using fixed IV, and in your case random salt added to plain text before encryption compensates insecurity of fixed IV. However use of salt for that purpose is not very good solution because it implicity binds it to a fixed mode of operations - CBC, and totally fails for CTR (and some other modes of operations).
And for the hashed Passwords - salt is very important.
However the salt is misnomer. Real purpose of the salt was to modify encryption algorithm so that fast hardware cryptography will be unusable. For example DES salt is 12 bits and is used for switching bits from pairs of left and right parts of round key (48 bits). At first salt was used with crypt algorithm, that was relying on DES encryption, but after crypt was replaced with other hashed passwords, due to limitation of crypt to 8 chars (here is 7bit chars), salt continued to be used to refer to extra IV used with hashing algorithms.
-Valery.
http://www.harper.no/valery
"Mitch Gallant" <jensigner@xxxxxxxxxxxxxxxx> wrote in message news:ub%23Yy3BNGHA.2472@xxxxxxxxxxxxxxxxxxxxxxx
"Valery Pryamikov" <valery@xxxxxxxxx> wrote in message news:uV12dpBNGHA.1124@xxxxxxxxxxxxxxxxxxxxxxx
Adding a "salt" is redundant... and even harmful since it is just unnecessary goo that distructs attention from the real task - secure encryption.
So are you claiming that the salt used in the algorithm behind .NET PasswordDeriveBytes
adds NO useful entropy (or added randomness) and hence is useless?
- Mitch
.
- Follow-Ups:
- Re: How to encrypt/decrypt a file
- From: Mitch Gallant
- Re: How to encrypt/decrypt a file
- References:
- How to encrypt/decrypt a file
- From: corey . burnett
- Re: How to encrypt/decrypt a file
- From: Eric Johnson
- Re: How to encrypt/decrypt a file
- From: Mitch Gallant
- Re: How to encrypt/decrypt a file
- From: Eric Johnson
- Re: How to encrypt/decrypt a file
- From: Mitch Gallant
- Re: How to encrypt/decrypt a file
- From: Henning Krause [MVP]
- Re: How to encrypt/decrypt a file
- From: Mitch Gallant
- Re: How to encrypt/decrypt a file
- From: bradbury9
- Re: How to encrypt/decrypt a file
- From: corey . burnett
- Re: How to encrypt/decrypt a file
- From: Mitch Gallant
- Re: How to encrypt/decrypt a file
- From: corey . burnett
- Re: How to encrypt/decrypt a file
- From: Mitch Gallant
- Re: How to encrypt/decrypt a file
- From: corey . burnett
- Re: How to encrypt/decrypt a file
- From: Mitch Gallant
- Re: How to encrypt/decrypt a file
- From: corey . burnett
- Re: How to encrypt/decrypt a file
- From: Valery Pryamikov
- Re: How to encrypt/decrypt a file
- From: Mitch Gallant
- Re: How to encrypt/decrypt a file
- From: Mitch Gallant
- Re: How to encrypt/decrypt a file
- From: Valery Pryamikov
- Re: How to encrypt/decrypt a file
- From: Mitch Gallant
- How to encrypt/decrypt a file
- Prev by Date: Re: How to encrypt/decrypt a file
- Next by Date: Re: How to encrypt/decrypt a file
- Previous by thread: Re: How to encrypt/decrypt a file
- Next by thread: Re: How to encrypt/decrypt a file
- Index(es):
Relevant Pages
|
Loading