We took a slightly different approach in the past with this problem.

We had a stateful Seam application and so had two managed beans. One
representing your identity and the other a user.

For regular users these would effectively be the same. For administrators,
they had the necessary permission to search and choose the user object.

In all our Seam EL we then referenced #{currentuser.name} etc and it all
worked rather nicely.

On 23 September 2011 23:25, Manoj Khangaonkar <[email protected]> wrote:

> HI
>
> Use the method
>
> Subject.runAs(PrincipalCollection ....
>
> to impersonate a user and the method
>
> Subject.releaseRunAs
>
> to revert back to the original
>
> Manoj
>
>
>
> On Thu, Sep 22, 2011 at 11:45 PM, Sudhir N <[email protected]>
> wrote:
> >
> > I need to implement the 'Impersonate an user' functionality so that who
> ever
> > has that perm. can see the application from users perspective.
> > Can any one guide me on how that can be accomplished.
> > I am using Shiro with grails (Shiro security plugin), but that does not
> > change the things much I believe.
> >
> > Thanks
> > Sudhir
> > http://www.geeksays.com
>
>
>
> --
> http://khangaonkar.blogspot.com/
>

Reply via email to