cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Guido Casper <>
Subject Re: Auth-fw, can't get Session context
Date Thu, 19 May 2005 08:25:01 GMT
Stavros Kounis wrote:

> On 5/19/05, Guido Casper <> wrote:
>>Stavros Kounis wrote:
>>>hi all
>>>i try to use Auth-FW. i have choose to create one just like the flow
>>>based in cocoon's samples.
>>>The auth process work fine (i can login log-out etc) but i can not get
>>>loged-in user's information.
>>>I have try the code snippet from AuthFWWithFlow wiki page [1]
>>>var contextMan =
>>>var authContext = contextMan.getContext("authentication");
>>>var userFrag = authContext.getXML("/authentication/ID");
>>>var username =;
>>>this code return NULL at contextMan.getContext("authentication").
>>>I have to note that when i add this snippet at original cocoon's
>>>sample work fine.
>>>Did anyone give me a hint where i have to look for?
>>The authentication context is only available within sitemap sections
>>being protected via AuthAction.
> hi  Guido and thank you for your reply
> now i have to say that i'm totaly confused because i have try previews
> snippet in flow based auth-fw example (succesfully, or i just think
> so?!?).

Sorry, I use above code snippet together with action based approach. But 
it should be possible with flow-based as well (as you confirmed).

All I can say is that you should look for differences between your code 
and the Cocoon sample (sorry :-).

I just had a quick look at the AuthAction, which code snippet may be 
responsible for making the auth context available and I think it's this:

   RequestState state = authManager.getState();
   map = state.getHandler().getContext().getContextInfo();

which, I assume, places the auth info into the request and which I can't 
find in the flow based sample.


> So there is NO way to get loged-in user-name in flow ?
> I have to use the action based approach ONLY?
> regards
> --stavros 

Freundliche Grüße / With kind regards
Guido Casper

Competence Center Open Source
Klingenderstr. 5
D 33100 Paderborn

voice  +49 5251/1581-87
fax    +49 5251/1581-71

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message