2 Replies Latest reply on Sep 2, 2008 8:45 AM by nimo stephan

    JpaIdentityStore bug?

    nimo stephan Master


      I have configured a JPAIdentityStore. Now, I want to use the method

      public boolean authenticate(String username, String password)

      I found out, that the

      boolean success = passwordHash.equals(userPasswordProperty.getValue(user));

      returns always false, as the userPasswordProperty.getValue(user) has trailing whitespace and therefore returns false.

      I replaced the success-attribute with that:

      boolean success = passwordHash.equals(userPasswordProperty.getValue(user).toString().trim());

      Now it works!

      Please make sure, that I am right with that. Am I right?