org.apache.directory.server.core.authz
Class AuthorizationService

java.lang.Object
  extended by org.apache.directory.server.core.interceptor.BaseInterceptor
      extended by org.apache.directory.server.core.authz.AuthorizationService
All Implemented Interfaces:
Interceptor

public class AuthorizationService
extends BaseInterceptor

An ACI based authorization service.

Version:
$Rev: 499780 $
Author:
Apache Directory Project

Field Summary
static javax.naming.directory.SearchControls DEFAULT_SEARCH_CONTROLS
           
 
Constructor Summary
AuthorizationService()
           
 
Method Summary
 void add(NextInterceptor next, org.apache.directory.shared.ldap.name.LdapDN normName, javax.naming.directory.Attributes entry)
          Filters Partition.add(org.apache.directory.shared.ldap.name.LdapDN,javax.naming.directory.Attributes) call.
 void cacheNewGroup(java.lang.String upName, org.apache.directory.shared.ldap.name.LdapDN normName, javax.naming.directory.Attributes entry)
           
 boolean compare(NextInterceptor next, org.apache.directory.shared.ldap.name.LdapDN name, java.lang.String oid, java.lang.Object value)
          Filters PartitionNexus.compare(org.apache.directory.shared.ldap.name.LdapDN,String,Object) call.
 void delete(NextInterceptor next, org.apache.directory.shared.ldap.name.LdapDN name)
          Filters Partition.delete(org.apache.directory.shared.ldap.name.LdapDN) call.
 org.apache.directory.shared.ldap.name.LdapDN getMatchedName(NextInterceptor next, org.apache.directory.shared.ldap.name.LdapDN dn)
          Filters PartitionNexus.getMatchedName(org.apache.directory.shared.ldap.name.LdapDN) call.
 boolean hasEntry(NextInterceptor next, org.apache.directory.shared.ldap.name.LdapDN name)
          Filters Partition.lookup(org.apache.directory.shared.ldap.name.LdapDN,String[]) call.
 void init(DirectoryServiceConfiguration factoryCfg, InterceptorConfiguration cfg)
          Initializes this interceptor based service by getting a handle on the nexus, setting up the tupe and group membership caches and the ACIItem parser and the ACDF engine.
 boolean isPrincipalAnAdministrator(org.apache.directory.shared.ldap.name.LdapDN principalDn)
           
 javax.naming.NamingEnumeration list(NextInterceptor next, org.apache.directory.shared.ldap.name.LdapDN base)
          Filters Partition.list(org.apache.directory.shared.ldap.name.LdapDN) call.
 javax.naming.directory.Attributes lookup(NextInterceptor next, org.apache.directory.shared.ldap.name.LdapDN name)
          Filters Partition.lookup(org.apache.directory.shared.ldap.name.LdapDN) call.
 javax.naming.directory.Attributes lookup(NextInterceptor next, org.apache.directory.shared.ldap.name.LdapDN dn, java.lang.String[] attrIds)
          Filters Partition.lookup(org.apache.directory.shared.ldap.name.LdapDN,String[]) call.
 void modify(NextInterceptor next, org.apache.directory.shared.ldap.name.LdapDN name, int modOp, javax.naming.directory.Attributes mods)
          Filters Partition.modify(org.apache.directory.shared.ldap.name.LdapDN,int,javax.naming.directory.Attributes) call.
 void modify(NextInterceptor next, org.apache.directory.shared.ldap.name.LdapDN name, org.apache.directory.shared.ldap.message.ModificationItemImpl[] mods)
          Filters Partition#modify(org.apache.directory.shared.ldap.name.LdapDN,javax.naming.directory.ModificationItem[]) call.
 void modifyRn(NextInterceptor next, org.apache.directory.shared.ldap.name.LdapDN name, java.lang.String newRn, boolean deleteOldRn)
          Filters Partition.modifyRn(org.apache.directory.shared.ldap.name.LdapDN,String,boolean) call.
 void move(NextInterceptor next, org.apache.directory.shared.ldap.name.LdapDN oriChildName, org.apache.directory.shared.ldap.name.LdapDN newParentName)
          Filters Partition.move(org.apache.directory.shared.ldap.name.LdapDN,org.apache.directory.shared.ldap.name.LdapDN) call.
 void move(NextInterceptor next, org.apache.directory.shared.ldap.name.LdapDN oriChildName, org.apache.directory.shared.ldap.name.LdapDN newParentName, java.lang.String newRn, boolean deleteOldRn)
          Filters Partition.move(org.apache.directory.shared.ldap.name.LdapDN,org.apache.directory.shared.ldap.name.LdapDN,String,boolean) call.
 javax.naming.NamingEnumeration search(NextInterceptor next, org.apache.directory.shared.ldap.name.LdapDN base, java.util.Map env, org.apache.directory.shared.ldap.filter.ExprNode filter, javax.naming.directory.SearchControls searchCtls)
          Filters Partition.search(org.apache.directory.shared.ldap.name.LdapDN,java.util.Map,org.apache.directory.shared.ldap.filter.ExprNode,javax.naming.directory.SearchControls) call.
 
Methods inherited from class org.apache.directory.server.core.interceptor.BaseInterceptor
addContextPartition, bind, destroy, getContext, getPrincipal, getRootDSE, getSuffix, isSuffix, listSuffixes, removeContextPartition, unbind
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_SEARCH_CONTROLS

public static final javax.naming.directory.SearchControls DEFAULT_SEARCH_CONTROLS
Constructor Detail

AuthorizationService

public AuthorizationService()
Method Detail

init

public void init(DirectoryServiceConfiguration factoryCfg,
                 InterceptorConfiguration cfg)
          throws javax.naming.NamingException
Initializes this interceptor based service by getting a handle on the nexus, setting up the tupe and group membership caches and the ACIItem parser and the ACDF engine.

Specified by:
init in interface Interceptor
Overrides:
init in class BaseInterceptor
Parameters:
factoryCfg - the ContextFactory configuration for the server
cfg - the interceptor configuration
Throws:
javax.naming.NamingException - if there are problems during initialization

add

public void add(NextInterceptor next,
                org.apache.directory.shared.ldap.name.LdapDN normName,
                javax.naming.directory.Attributes entry)
         throws javax.naming.NamingException
Description copied from interface: Interceptor
Filters Partition.add(org.apache.directory.shared.ldap.name.LdapDN,javax.naming.directory.Attributes) call.

Specified by:
add in interface Interceptor
Overrides:
add in class BaseInterceptor
Throws:
javax.naming.NamingException

delete

public void delete(NextInterceptor next,
                   org.apache.directory.shared.ldap.name.LdapDN name)
            throws javax.naming.NamingException
Description copied from interface: Interceptor
Filters Partition.delete(org.apache.directory.shared.ldap.name.LdapDN) call.

Specified by:
delete in interface Interceptor
Overrides:
delete in class BaseInterceptor
Throws:
javax.naming.NamingException

modify

public void modify(NextInterceptor next,
                   org.apache.directory.shared.ldap.name.LdapDN name,
                   int modOp,
                   javax.naming.directory.Attributes mods)
            throws javax.naming.NamingException
Description copied from interface: Interceptor
Filters Partition.modify(org.apache.directory.shared.ldap.name.LdapDN,int,javax.naming.directory.Attributes) call.

Specified by:
modify in interface Interceptor
Overrides:
modify in class BaseInterceptor
Throws:
javax.naming.NamingException

modify

public void modify(NextInterceptor next,
                   org.apache.directory.shared.ldap.name.LdapDN name,
                   org.apache.directory.shared.ldap.message.ModificationItemImpl[] mods)
            throws javax.naming.NamingException
Description copied from interface: Interceptor
Filters Partition#modify(org.apache.directory.shared.ldap.name.LdapDN,javax.naming.directory.ModificationItem[]) call.

Specified by:
modify in interface Interceptor
Overrides:
modify in class BaseInterceptor
Throws:
javax.naming.NamingException

hasEntry

public boolean hasEntry(NextInterceptor next,
                        org.apache.directory.shared.ldap.name.LdapDN name)
                 throws javax.naming.NamingException
Description copied from interface: Interceptor
Filters Partition.lookup(org.apache.directory.shared.ldap.name.LdapDN,String[]) call.

Specified by:
hasEntry in interface Interceptor
Overrides:
hasEntry in class BaseInterceptor
Throws:
javax.naming.NamingException

lookup

public javax.naming.directory.Attributes lookup(NextInterceptor next,
                                                org.apache.directory.shared.ldap.name.LdapDN dn,
                                                java.lang.String[] attrIds)
                                         throws javax.naming.NamingException
Description copied from interface: Interceptor
Filters Partition.lookup(org.apache.directory.shared.ldap.name.LdapDN,String[]) call.

Specified by:
lookup in interface Interceptor
Overrides:
lookup in class BaseInterceptor
Throws:
javax.naming.NamingException

lookup

public javax.naming.directory.Attributes lookup(NextInterceptor next,
                                                org.apache.directory.shared.ldap.name.LdapDN name)
                                         throws javax.naming.NamingException
Description copied from interface: Interceptor
Filters Partition.lookup(org.apache.directory.shared.ldap.name.LdapDN) call.

Specified by:
lookup in interface Interceptor
Overrides:
lookup in class BaseInterceptor
Throws:
javax.naming.NamingException

modifyRn

public void modifyRn(NextInterceptor next,
                     org.apache.directory.shared.ldap.name.LdapDN name,
                     java.lang.String newRn,
                     boolean deleteOldRn)
              throws javax.naming.NamingException
Description copied from interface: Interceptor
Filters Partition.modifyRn(org.apache.directory.shared.ldap.name.LdapDN,String,boolean) call.

Specified by:
modifyRn in interface Interceptor
Overrides:
modifyRn in class BaseInterceptor
Throws:
javax.naming.NamingException

move

public void move(NextInterceptor next,
                 org.apache.directory.shared.ldap.name.LdapDN oriChildName,
                 org.apache.directory.shared.ldap.name.LdapDN newParentName,
                 java.lang.String newRn,
                 boolean deleteOldRn)
          throws javax.naming.NamingException
Description copied from interface: Interceptor
Filters Partition.move(org.apache.directory.shared.ldap.name.LdapDN,org.apache.directory.shared.ldap.name.LdapDN,String,boolean) call.

Specified by:
move in interface Interceptor
Overrides:
move in class BaseInterceptor
Throws:
javax.naming.NamingException

move

public void move(NextInterceptor next,
                 org.apache.directory.shared.ldap.name.LdapDN oriChildName,
                 org.apache.directory.shared.ldap.name.LdapDN newParentName)
          throws javax.naming.NamingException
Description copied from interface: Interceptor
Filters Partition.move(org.apache.directory.shared.ldap.name.LdapDN,org.apache.directory.shared.ldap.name.LdapDN) call.

Specified by:
move in interface Interceptor
Overrides:
move in class BaseInterceptor
Throws:
javax.naming.NamingException

list

public javax.naming.NamingEnumeration list(NextInterceptor next,
                                           org.apache.directory.shared.ldap.name.LdapDN base)
                                    throws javax.naming.NamingException
Description copied from interface: Interceptor
Filters Partition.list(org.apache.directory.shared.ldap.name.LdapDN) call.

Specified by:
list in interface Interceptor
Overrides:
list in class BaseInterceptor
Throws:
javax.naming.NamingException

search

public javax.naming.NamingEnumeration search(NextInterceptor next,
                                             org.apache.directory.shared.ldap.name.LdapDN base,
                                             java.util.Map env,
                                             org.apache.directory.shared.ldap.filter.ExprNode filter,
                                             javax.naming.directory.SearchControls searchCtls)
                                      throws javax.naming.NamingException
Description copied from interface: Interceptor
Filters Partition.search(org.apache.directory.shared.ldap.name.LdapDN,java.util.Map,org.apache.directory.shared.ldap.filter.ExprNode,javax.naming.directory.SearchControls) call.

Specified by:
search in interface Interceptor
Overrides:
search in class BaseInterceptor
Throws:
javax.naming.NamingException

isPrincipalAnAdministrator

public final boolean isPrincipalAnAdministrator(org.apache.directory.shared.ldap.name.LdapDN principalDn)
                                         throws javax.naming.NamingException
Throws:
javax.naming.NamingException

compare

public boolean compare(NextInterceptor next,
                       org.apache.directory.shared.ldap.name.LdapDN name,
                       java.lang.String oid,
                       java.lang.Object value)
                throws javax.naming.NamingException
Description copied from interface: Interceptor
Filters PartitionNexus.compare(org.apache.directory.shared.ldap.name.LdapDN,String,Object) call.

Specified by:
compare in interface Interceptor
Overrides:
compare in class BaseInterceptor
Throws:
javax.naming.NamingException

getMatchedName

public org.apache.directory.shared.ldap.name.LdapDN getMatchedName(NextInterceptor next,
                                                                   org.apache.directory.shared.ldap.name.LdapDN dn)
                                                            throws javax.naming.NamingException
Description copied from interface: Interceptor
Filters PartitionNexus.getMatchedName(org.apache.directory.shared.ldap.name.LdapDN) call.

Specified by:
getMatchedName in interface Interceptor
Overrides:
getMatchedName in class BaseInterceptor
Throws:
javax.naming.NamingException

cacheNewGroup

public void cacheNewGroup(java.lang.String upName,
                          org.apache.directory.shared.ldap.name.LdapDN normName,
                          javax.naming.directory.Attributes entry)
                   throws javax.naming.NamingException
Throws:
javax.naming.NamingException


Copyright © 2003-2012 Apache Software Foundation. All Rights Reserved.