Oleg,
I agree -- It would be nice to be able turn off role mapping for my
application.
- Keith
-----Original Message-----
From: Oleg Nitz <[EMAIL PROTECTED]>
To: jBoss <[EMAIL PROTECTED]>
Date: Saturday, November 18, 2000 7:58 PM
Subject: Re: [jBoss-User] bug in EnterpriseContext.java
>Hi Keith,
>
>Of course, you are right. The bug is mine :-(
>Thank you for pointing it out, I'll committed the fix to CVS ASAP.
>Also I see that now it's impossible to use authentication (security
manager)
>without role mapping, this also should be fixed.
>
>Thanks,
> Oleg
>
>Sun, 19 Nov 2000, you wrote:
>>
>> There appears to be a bug in the CVS version of
EnterpriseContext.java. (I have not traced back to see when it was
introduced, or whether it has always been there.)
>>
>> The problem is with what I believe is caching of "caller principal".
In the following code snippet...
>>
>> public Principal getCallerPrincipal(){
>> if (principal == null && beanPrincipal == null &&
con.getRealMapping() != null){
>> beanPrincipal =
con.getRealmMapping().getPrincipal(principal);
>> }
>> return beanPrincipal;
>> }
>>
>> This code avoids re-mapping the principal after the first call to
"getCallerPrincipal". However, the actual principal may actually have
changed. (New user calls the same bean.) However, the original
beanPrincipal is always returned.
>>
>> Unless I am misunderstanding something, the "beanPrincipal" should be
cleared the next time "principal" is changed in
"setPrincipal( principal )". That way an updated beanPrincipal is
calculated every time principal changes.
>>
>> I am making this change in my copy of source. Please let me know if
the current implementation is correct and I'm mixed up.
>>
>> Thanks,
>> - Keith
>>
>> The code for
>> Keith L. Musser
>> Integrated Dynamics, Inc.
>> 812-371-7777
>> email: [EMAIL PROTECTED]
>>
>>
>
>----------------------------------------
>Content-Type: text/html; name="unnamed"
>Content-Transfer-Encoding: quoted-printable
>Content-Description:
>----------------------------------------
>
>
>--
>--------------------------------------------------------------
>To subscribe: [EMAIL PROTECTED]
>To unsubscribe: [EMAIL PROTECTED]
>Problems?: [EMAIL PROTECTED]
>
>
--
--------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
Problems?: [EMAIL PROTECTED]