public static boolean validateToken(MSession session,MUser user,String token){
  try {
    String hash=getPasswordHash(session,user);
    return hash.equals(token);
  }
 catch (  Exception e) {
    log.log(Level.WARNING,e.getLocalizedMessage(),e);
  }
  return false;
}

public static boolean validateToken ( MSession session , MUser user , String token ) { try { String hash = getPasswordHash ( session , user ) ; return hash . equals ( token ) ; } catch ( Exception e ) { log . log ( Level . WARNING , e . getLocalizedMessage ( ) , e ) ; } return false ; }
validate a stored client side token is valid
