Fix legacy passwords which have a salt containing a colon

Closes #1540