org.apache.lenya.ac.impl
Class BypassableAccessController
java.lang.Object
org.apache.avalon.framework.logger.AbstractLogEnabled
org.apache.lenya.ac.impl.DefaultAccessController
org.apache.lenya.ac.impl.BypassableAccessController
- All Implemented Interfaces:
- org.apache.avalon.framework.activity.Disposable, org.apache.avalon.framework.component.Component, org.apache.avalon.framework.configuration.Configurable, org.apache.avalon.framework.logger.LogEnabled, org.apache.avalon.framework.service.Serviceable, AccessController, ItemManagerListener
public class BypassableAccessController
- extends DefaultAccessController
AccessController that can be bypassed for certain URL patterns.
Method Summary |
boolean |
authorize(org.apache.cocoon.environment.Request request)
Authorizes a request inside a publication. |
void |
configure(org.apache.avalon.framework.configuration.Configuration conf)
|
protected boolean |
preparedMatch(org.apache.regexp.REProgram preparedPattern,
java.lang.String match)
Matches a string using a prepared pattern program. |
protected org.apache.regexp.REProgram |
preparePattern(java.lang.String pattern)
Compile the pattern in a org.apache.regexp.REProgram . |
Methods inherited from class org.apache.lenya.ac.impl.DefaultAccessController |
authenticate, configureOrParameterize, dispose, getAccreditableManager, getAuthenticator, getAuthorizers, getManager, getPolicyManager, hasAuthorizers, hasValidIdentity, itemAdded, itemRemoved, ownsIdenity, service, setupAccreditableManager, setupAuthenticator, setupAuthorizers, setupIdentity, setupPolicyManager |
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled |
enableLogging, getLogger, setupLogger, setupLogger, setupLogger |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BypassableAccessController
public BypassableAccessController()
- Ctor.
configure
public void configure(org.apache.avalon.framework.configuration.Configuration conf)
throws org.apache.avalon.framework.configuration.ConfigurationException
- Specified by:
configure
in interface org.apache.avalon.framework.configuration.Configurable
- Overrides:
configure
in class DefaultAccessController
- Throws:
org.apache.avalon.framework.configuration.ConfigurationException
- See Also:
Configurable.configure(org.apache.avalon.framework.configuration.Configuration)
preparePattern
protected org.apache.regexp.REProgram preparePattern(java.lang.String pattern)
throws org.apache.cocoon.sitemap.PatternException
- Compile the pattern in a
org.apache.regexp.REProgram
.
- Parameters:
pattern
- The pattern to compile.
- Returns:
- A RE program representing the pattern.
- Throws:
org.apache.cocoon.sitemap.PatternException
- when something went wrong.
preparedMatch
protected boolean preparedMatch(org.apache.regexp.REProgram preparedPattern,
java.lang.String match)
- Matches a string using a prepared pattern program.
- Parameters:
preparedPattern
- The pattern program.match
- The string to match.
- Returns:
true
if the string matched the pattern, false
otherwise.
authorize
public boolean authorize(org.apache.cocoon.environment.Request request)
throws AccessControlException
- Description copied from interface:
AccessController
- Authorizes a request inside a publication.
- Specified by:
authorize
in interface AccessController
- Overrides:
authorize
in class DefaultAccessController
- Parameters:
request
- A request.
- Returns:
- A boolean value.
- Throws:
AccessControlException
- when something went wrong.- See Also:
AccessController.authorize(org.apache.cocoon.environment.Request)
Copyright © 1999-2005 Apache Software Foundation. All Rights Reserved.