Thank you, James.

I must confess that my Eclipse can't organize imports of some of your
mentioned classes. Could you be so kind and tell me where to find them
(Subject, AccessController, Principal, SecurityHelper, UserPrincipal,
RolePrincipal)?

Thank you.

-----Ursprüngliche Nachricht-----
Von: James Liao [mailto:[EMAIL PROTECTED] 
Gesendet: Freitag, 8. Juli 2005 09:18
An: Jetspeed Users List
Betreff: Re: AW: getting information about which role/user is logged in
?

Hi,
How about get the info from current context's subject?
Subject subject = Subject.getSubject(AccessController.getContext());
Principal user  = SecurityHelper.getPrincipal(subject,
UserPrincipal.class);
Principal role =
SecurityHelper.getPrincipals(user.getSubject(),RolePrincipal.class);

- James Liao

On 7/8/05, Luc Fouin <[EMAIL PROTECTED]> wrote:
> [EMAIL PROTECTED] a écrit :
> > Yes, but how can you see who is currently logged in?
> 
> arf, sorry i misunderstood your question... in this case i can't
answer...
> 
> i think you'll have to check the database using the mapping, but i
can't
> tell you more...
> 
> Luc
> 
> 
> --
> Luc FOUIN - Stagiaire Aptiwan
> 14 rue Niepce
> 75014 Paris
> Tél : 06 77 95 17 24
> Mél : luc*DOT*fouin*AT*aptiwan*DOT*com
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to