org.apache.cocoon.auth.impl
Class ServletSecurityHandler

java.lang.Object
  extended byorg.apache.cocoon.auth.impl.AbstractSecurityHandler
      extended byorg.apache.cocoon.auth.impl.ServletSecurityHandler
All Implemented Interfaces:
BeanNameAware, org.apache.cocoon.auth.SecurityHandler

public class ServletSecurityHandler
extends AbstractSecurityHandler

Verify if a user can be authenticated. This is a very simple authenticator that checks if the user is authenticated using the servlet authentication mechanisms.

Version:
$Id: ServletSecurityHandler.html 1304280 2012-03-23 11:18:01Z ilgrosso $

Nested Class Summary
static class ServletSecurityHandler.ServletUser
          Inner class for the current user.
 
Field Summary
protected  org.apache.cocoon.processing.ProcessInfoProvider processInfoProvider
          The process info provider.
 
Fields inherited from class org.apache.cocoon.auth.impl.AbstractSecurityHandler
anonName, anonPass, id, supportAnonUser
 
Constructor Summary
ServletSecurityHandler()
           
 
Method Summary
protected  org.apache.cocoon.auth.User createUser(org.apache.cocoon.environment.Request req)
          Create a new user.
 org.apache.cocoon.auth.User login(Map loginContext)
           
 void logout(Map logoutContext, org.apache.cocoon.auth.User user)
           
 void setProcessInfoProvider(org.apache.cocoon.processing.ProcessInfoProvider p)
           
 
Methods inherited from class org.apache.cocoon.auth.impl.AbstractSecurityHandler
getId, getLogger, setAnonymousName, setAnonymousPassword, setBeanName, setLogger, setSupportAnonymousUser
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

processInfoProvider

protected org.apache.cocoon.processing.ProcessInfoProvider processInfoProvider
The process info provider.

Constructor Detail

ServletSecurityHandler

public ServletSecurityHandler()
Method Detail

setProcessInfoProvider

public void setProcessInfoProvider(org.apache.cocoon.processing.ProcessInfoProvider p)

createUser

protected org.apache.cocoon.auth.User createUser(org.apache.cocoon.environment.Request req)
Create a new user.

Parameters:
req - The current request.
Returns:
A new user object.

login

public org.apache.cocoon.auth.User login(Map loginContext)
                                  throws org.apache.cocoon.auth.AuthenticationException
Throws:
org.apache.cocoon.auth.AuthenticationException
See Also:
SecurityHandler.login(java.util.Map)

logout

public void logout(Map logoutContext,
                   org.apache.cocoon.auth.User user)
See Also:
SecurityHandler.logout(java.util.Map, org.apache.cocoon.auth.User)


Copyright 1999-2008 The Apache Software Foundation. All Rights Reserved.