Correctly handle password which are longer than 64 characters (see #6015)