javascript hash password before sending