I need to generate password reset links with random tokens, something like 8-20 random alphanumeric characters to append to a password reset link. Is it a good idea to use
getSaltBytes() to generate these tokens?
Below is an example of what I need (I used
getSaltBytes() to achieve this, the first param is the user id):
So far I have recieved some seemingly random Strings, they can vary by 1 character and seem to have no distinct pattern.
Could someone who has done something like this before offer some advice, and give me reason why this might or might not be a good idea, if so please could you offer a better solution?
I have to finish this Uni project by Monday ^^,