made encrypt and decrypt passwords consistent