Reputation: 13
I tried to do like in this topic: Symfony 2 authentication with (doctrine) Entity And I don't know what to do with the getSalt() method, I don't want to use salt so I try getSalt() returning null but it doesn't work. Please, can anyone help me?
PS: Sorry for my poor english.
Upvotes: 1
Views: 1770
Reputation: 825
The salt is a string (usually derived from a one-way hashing function) that is prefixed the password before the chosen encoding function is applied. It can be a fixed string if you like, and it can also be an empty one.
public function getSalt() {
return ''; // Could also be 'mysalt'
}
Upvotes: 7