Announcement Announcement Module
Collapse
No announcement yet.
sessionScope.SPRING_SECURITY_LAST_USERNAME doesn't print anything after login Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • sessionScope.SPRING_SECURITY_LAST_USERNAME doesn't print anything after login

    i followed the configuration in the following sample:

    http://facestutorials.icefaces.org/t...ity-basic.html

    and i am trying to print the logged in username after successful login
    but it doesn't print anything, any ideas why ?

    code:

    Code:
    #{sessionScope.SPRING_SECURITY_LAST_USERNAME}
    please advise.

  • #2
    Probably because it isn't stored in the session. If you have a valid logged in user, then use the standard servlet API methods to retrieve the user name, as Spring Security implements these.

    Alternatively you can directly access the information in the SecurityContext for the authenticated user. But if all you want is the name, then use the HttpServletRequest methods.

    Comment

    Working...
    X