bug-fix in password encoding