1
vote
3answers
646 views

Is Salt, IV and Key necessary when encrypting password in a database using AES? If so, how should they be used?

Imagine I have a website with user accounts. I want to authenticate users, so I need to know if the password they provide matches the one stored in my database. To protect the passwords from prying ...
16
votes
3answers
2k views

Is it safe to write the salt AND/OR the IV at the beggining of an encrypted file?

I want to encrypt a file with AES in CBC mode (maybe another mode is better for file encryption...I don't know, but suggestions are welcome!). What I usually do is that I first write a few random ...
1
vote
1answer
104 views

Sending Salts For Key Generation

I am working on a project that uses a combination of a web based framework (Django) and an installed app (Python) for the purpose of data entry/upload. I will have to send medical records over the web ...
3
votes
2answers
715 views

Why would you need a salt for AES-CBS when IV is already randomly generated and stored with the encrypted data?

I was looking at this code and came across these comments which says encrypting without a salt is insecure. Why would it be insecure when you are already using a random IV for each value? I think the ...
1
vote
2answers
171 views

Do I need to salt PBKDF2 when it's used for AES encryption

If I'm using PBKDF2 to stretch a password into a suitable key for use in encryption with AES, should I be using a random salt (for PBKDF2, not the AES IV)?
5
votes
2answers
409 views

How less secure is an encryption if we know something about the original data?

I have a number of files encrypted with a key derived from a password. In line with standard practice, I use a random salt and password and do many PBKDF2 iterations to obtain an encryption key and ...
3
votes
4answers
494 views

Is it safe to have the salt equal to IV?

If I'm using AES-256 CBC to encrypt, getting the 32 byte key using multiple iterations of the PBKDF2 function with a 16 byte salt, is it safe for me to let IV be equal to the salt? (Edit: The salt is ...
7
votes
3answers
2k views

I don't see how “-salt” in the openssl command line tool enhances security at all

I do this to encrypt a single file: openssl aes-256-cbc -a -salt -in file.txt -out file.enc and then type in some regular plaintext password. I do not understand how -salt enhances the security of ...
10
votes
1answer
6k views

Where is the salt on the OpenSSL AES encryption?

I'm interested in knowing how and where OpenSSL inserts the generated salt on an AES encrypted data. Why? Im encrypting data in Java classes and need to guarantee that I can use OpenSSL to decrypt ...