java.lang.Object
org.acegisecurity.captcha.CaptchaChannelProcessorTemplate
- All Implemented Interfaces:
- org.acegisecurity.securechannel.ChannelProcessor, org.springframework.beans.factory.InitializingBean
- Direct Known Subclasses:
- AlwaysTestAfterMaxRequestsCaptchaChannelProcessor, AlwaysTestAfterTimeInMillisCaptchaChannelProcessor, AlwaysTestBelowAverageTimeInMillisBetweenRequestsChannelProcessor, TestOnceAfterMaxRequestsCaptchaChannelProcessor
- public abstract class CaptchaChannelProcessorTemplate
- extends java.lang.Object
- implements org.acegisecurity.securechannel.ChannelProcessor, org.springframework.beans.factory.InitializingBean
CaptchaChannel template : Ensures the user has enough human privileges by
review of the CaptchaSecurityContext and using an abstract routine
isContextValidConcerningHumanity(CaptchaSecurityContext) 55
(implemented by sub classes)
The component uses 2 main parameters for its configuration :
- Version:
- $Id: CaptchaChannelProcessorTemplate.java,v 1.2 2005/11/17 00:55:49 benalex Exp $
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
logger
protected org.apache.commons.logging.Log logger
entryPoint
private org.acegisecurity.securechannel.ChannelEntryPoint entryPoint
keyword
private java.lang.String keyword
thresold
private int thresold
CaptchaChannelProcessorTemplate
public CaptchaChannelProcessorTemplate()
setEntryPoint
public void setEntryPoint(org.acegisecurity.securechannel.ChannelEntryPoint entryPoint)
getEntryPoint
public org.acegisecurity.securechannel.ChannelEntryPoint getEntryPoint()
setKeyword
public void setKeyword(java.lang.String keyword)
getKeyword
public java.lang.String getKeyword()
setThresold
public void setThresold(int thresold)
getThresold
public int getThresold()
afterPropertiesSet
public void afterPropertiesSet()
throws java.lang.Exception
- Verify if entryPoint and keyword are ok
- Specified by:
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
decide
public void decide(org.acegisecurity.intercept.web.FilterInvocation invocation,
ConfigAttributeDefinition config)
throws java.io.IOException,
javax.servlet.ServletException
- Description copied from interface:
org.acegisecurity.securechannel.ChannelProcessor
- Decided whether the presented org.acegisecurity.intercept.web.FilterInvocation provides the
appropriate level of channel security based on the requested
ConfigAttributeDefinition.
- Specified by:
decide in interface org.acegisecurity.securechannel.ChannelProcessor
supports
public boolean supports(ConfigAttribute attribute)
- Description copied from interface:
org.acegisecurity.securechannel.ChannelProcessor
- Indicates whether this
ChannelProcessor is able to process
the passed ConfigAttribute.
This allows the ChannelProcessingFilter to check every
configuration attribute can be consumed by the configured
ChannelDecisionManager.
- Specified by:
supports in interface org.acegisecurity.securechannel.ChannelProcessor
isContextValidConcerningHumanity
abstract boolean isContextValidConcerningHumanity(CaptchaSecurityContext context)
redirectToEntryPoint
private void redirectToEntryPoint(org.acegisecurity.intercept.web.FilterInvocation invocation)
throws java.io.IOException,
javax.servlet.ServletException