Hi,
Thank you very much

BR
/Amleto


> -----Messaggio originale-----
> Da: Tim Funk [mailto:[EMAIL PROTECTED] 
> Inviato: martedì 2 maggio 2006 13.14
> A: Tomcat Users List
> Oggetto: Re: add a session's attribute after authentication
> 
> 
> Via tomcat - there isn't a hook. The best (and most portable 
> way) you can do 
> this is to write a filter which checks for the attribute in 
> the session vs 
> the remoteUser value. For example:
> 
> doFilter(...) {
>    if (null!=request.getRemoteUser() &&
>          null==request.getSession().getAttribute("cowbell")) {
>      myCodeWhichInitializesSessionOnLogin();
>    }
>    chain.doFilter(request, response);
> }
> 
> -Tim
> 
> Amleto Di Salle wrote:
> 
> > Hi all,
> > I have used the container (Tomcat) managed security, but after the 
> > authentication I would like to set an object inside the 
> session. How 
> > can I do? I have noticed that Tomcat creates a session if the user 
> > accesses to a protected resource, so i cannot use the 
> > HttpSessionListener.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> -- 
> No virus found in this incoming message.
> Checked by AVG Free Edition.
> Version: 7.1.385 / Virus Database: 268.5.1/327 - Release 
> Date: 28/04/2006
>  
> 

-- 
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.385 / Virus Database: 268.5.1/327 - Release Date:
28/04/2006
 


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

Reply via email to