0 Replies Latest reply on Jul 4, 2007 6:23 AM by Peter Martiun

    How to set the principal name

    Peter Martiun Newbie

      In our application the user has a "remember me" option, which creates a cookie on their machine.

      If the cooky is set the token stored in the cookie is used as the username and the password is set to null. The format of the token is 'token_' e.g. 'token_test'.

      I have written a custom login module that checks for the token and does the necessary checks. When 'createIdentity()' is called we use the name of the user we have extracted from the token e.g. 'test'.

      Inside our web application, if we get the user Principal and call 'getName()' the name returned is 'token_test', when I am expecting 'test'.

      In my login module I can see SimplePrincipal is created correctly with 'test' as the name. Is there a way for me to see the correct principal name within my app?