boundary fix for sha512 passwords #1040