"Sandhya " wrote in message
news:3f55d92b$1@newsgroups.bea.com...
>
> Hi,
> I am using a JAAS authentication in weblogic 7.0. After the authentication

is
> done successfully, I am storing the user's information as a part of the

Principal
> of the Subject. For this I am using a customized principal class object i

have
> created. So when the user is committed in the JAAS framework i am storing

the
> principals as a part of the subject. The actual code looks like,
>
> principal = new myPrincipal(userInfo);
> this.subject.getPrincipals().add(principal);
>
>
> So when I need to retrive it, I use getCurrentSubject() and cast the

principal
> from it and retrive the necessry information from it. Like the sample code

looks
> like,
>
> Subject subject = Security.getCurrentSubject();
> MyPrincipal myPrincipal = null;
>
> Set principalSet = subject.getPrincipals();
> Iterator principals = principalSet.iterator();
> myPrincipal = (myPrincipal) principals.next();
>
> The above code works fine for most case, but when invoking multiple

threads of
> hte same user, like with the same login, mutliple process is invoked which

in
> trun will fetch the user's information from the subject part, it retrives

"weblogic.security.principal.WLSKernelIdentity"
> from the principal. Can u help me find out whne in is the case that a

WLSKernelIdentity
> gets stored and would i be able to avoid it.
>


Double check that you are in a thread which should have the user identity.
If so, then this sounds like a bug so contact BEA support and file a support
case.