3 Replies Latest reply on Mar 7, 2014 6:30 PM by anil.saldhana

    Authentication Fails with Custom User - JPA

    noamichael

      Hello everyone.

       

      I'm trying to create my own custom user object to be used with PicketLink. Eventually, I would like to have custom attributes, but for the moment I'm just trying to get PicketLink to recognize my User. My user class is exactly the same as the org.picketlink.idm.model.basic.User class, the only difference is the class name. In my AccountTypeEntity class (from the simple schema), I modified the annotation to read @IdentityManaged({ User.class, Agent.class, MyCustomUser.class }). I used the same entity manager that I supply PicketLink to run the query "SELECT U from AccountTypeEntity U" and my custom users are there alongside the default users. The issue is that authentication fails when I try to login using one of  the custom accounts. Is there anything I'm missing? I thought that since the two classes User and MyCustomUser are identical and the fact that MyCustomUser is managed by AccountTypeEntity would be enough to allow me to use my class.

       

      I really appreciate any help.