salt is the addition of characters, words, terms or even numbers that give a certain randomness to algorithms and help make them indecipherable.
To illustrate I will consider, here, the inversion of the text (ABC -> CBA) as a type of cryptography, only to demonstrate what happens with SALT in a way that facilitates human understanding. In the real world, it’s not humans doing this work, it’s algorithms based on mathematical models.
Based on the example above, imagine a password "123456", using this algorithm (terrible by the way) you would result in "654321".
With a known password and its encrypted result, it is possible to identify which algorithm was used to generate it. The complexity of the algorithm and the password are determinant in the time needed to break it. Until today, mathematically any password can be broken, however it is important to note that in many cases it would take hundreds or thousands of years, so it is assumed as safe(as) these passwords and algorithms.
Although in the real world we do not use simple algorithms like this, it is also not only humans who try to break these encryptions, specialized algorithms also do this dirty work, so hence the need to make these passwords more secure.
Salt consists of adding characters, words, terms, or even numbers that give randomness to the cryptographic result and help make it more complex. They are usually added before encryption, and can be fixed or random.
Taking into account the same algorithm cited, let’s take the example:
Senha: 123456
Salt: 20170323
Senha+Salt: 12342017032356
Senha Criptografada: 65323071024321
You can create random, dynamic Salts that don’t even need to be stored, You can use data from the record itself to determine a salt (date of registration, or creation date). All this helps to increase randomness and thus helps to hinder identification of the pattern used to encrypt something.
Would not be duplicate this one?
– user28595
@diegofm is not duplicated, but apparently has something to do with reply. I’ll read it there, because as you said yourself, the article is very big. So maybe this question is more specific about salt.
– viana
see http://answall.com/questions/2402/like-fazer-hash-de-passhas-safesafety and https://code.tutsplus.com/pt/tutorials/understanding-hash-functions-and-keeping-passwords-safe-net-17577
– user60252
Possible duplicate of How to hash passwords securely?
– Daniel Omine