Woops forgot to include the way I am getting the request.
private User getLoggedInUser() {
ServletWebRequest servletWebRequest = (ServletWebRequest) RequestCycle
.get().getRequest();
HttpServletRequest request = servletWebRequest.getContainerRequest();
Principal principal = request.getUserPrincipal();
User user = (User) principal;
return user;
}
I appreciate your help.
On Tue Mar 22,2011 08:42 pm, Mansour Al Akeel wrote:
> Hello all,
>
> I am authenticating a user, and it's working fine through our own Jaas
> module implementation. However, I am trying to get one of the Panels to
> display based on the logged in user. I am not using wicket-aut yet, and
> looking to do this by obtaining the Principal implementaton from the
> HttpServletRequest. I am getting null when I do so.
>
> I am trying to avoid diving into wicket specific implementation related
> to auth because I am a bit on a tight dead line.
>
> How would others deal with this issue?
> If you have a component to be displayed depending on the logged in user,
> how can I get the logged in user ?
>
>
> Thank you in advance.
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]