SEARCH
NEW RPMS
DIRECTORIES
ABOUT
FAQ
VARIOUS
BLOG
DONATE


YUM REPOSITORY

 
 

MAN page from StartCom 5 openldap-servers-overlays-2.3.43-12.SEL5_5.i386.rpm

SLAPO-ACCESSLOG

Section: File Formats (5)
Updated: 2008/07/16
Index 

NAME

slapo-accesslog - Access Logging overlay 

SYNOPSIS

/etc/openldap/slapd.conf 

DESCRIPTION

The Access Logging overlay can be used to record all accesses to a givenbackend database on another database. This allows all of the activity ona given database to be reviewed using arbitrary LDAP queries, instead ofjust logging to local flat text files. Configuration options are availablefor selecting a subset of operation types to log, and to automaticallyprune older log records from the logging database. Log records are storedwith audit schema (see below) to assure their readability whether viewedas LDIF or in raw form. 

CONFIGURATION

Theseslapd.confoptions apply to the Access Logging overlay.They should appear after theoverlaydirective.
logdb <suffix>
Specify the suffix of a database to be used for storing the log records.The specified database must have already been configured in a prior sectionof the config file, and it must have a rootDN configured. The access controlson the log database should prevent general write access. The suffix entryof the log database will be created automatically by this overlay. The logentries will be generated as the immediate children of the suffix entry.
logops <operations>
Specify which types of operations to log. The valid operation types areabandon, add, bind, compare, delete, extended, modify, modrdn, search,and unbind. Aliases for common sets of operations are also available:
writes
add, delete, modify, modrdn
reads
compare, search
session
abandon, bind, unbind
all
all operations
logold <filter>
Specify a filter for matching against Deleted and Modified entries. Ifthe entry matches the filter, the old contents of the entry will belogged along with the current request.
logpurge <age> <interval>
Specify the maximum age for log entries to be retained in the database,and how often to scan the database for old entries. Both theageandintervalare specified as a time span in days, hours, minutes, and seconds. Thetime format is [ddd+]hh:mm[:ss] i.e., the days and seconds components areoptional but hours and minutes are required. Except for days, which canbe up to 5 digits, each numeric field must be exactly two digits. For example
logpurge 2+00:00 1+00:00
would specify that the log database should be scanned every day for oldentries, and entries older than two days should be deleted. When using alog database that supports ordered indexing on generalizedTime attributes,specifying an eq index on thereqStartattribute will greatly benefit the performance of the purge operation.
logsuccess TRUE | FALSE
If set to TRUE then log records will only be generated for successfulrequests, i.e., requests that produce a result code of 0 (LDAP_SUCCESS).If FALSE, log records are generated for all requests whether theysucceed or not. The default is FALSE.

 

EXAMPLES

        database bdb        suffix cn=log        ...        index reqStart eq        database bdb        suffix dc=example,dc=com        ...        overlay accesslog        logdb cn=log        logops writes reads        logold (objectclass=person)

 

SCHEMA

Theaccesslogoverlay utilizes the "audit" schema described herein.This schema is specifically designed foraccesslogauditing and is not intended to be used otherwise. It is alsonoted that the schema describe here isa work inprogress,and hence subject to change without notice.The schema is loaded automatically by the overlay.

The schema includes a number of object classes and associatedattribute types as described below.

There isa basicauditObjectclass from which two additional classes,auditReadObjectandauditWriteObjectare derived. Object classes for each type of LDAP operation are furtherderived from these classes. This object class hierarchy is designed toallow flexible yet efficient searches of the log based on either a specificoperation type's class, or on more general classifications. The definitionof theauditObjectclass is as follows:

( 1.3.6.1.4.1.4203.666.11.5.2.1
    NAME 'auditObject'
    DESC 'OpenLDAP request auditing'
    SUP top STRUCTURAL
    MUST ( reqStart $ reqType $ reqSession )
    MAY ( reqDN $ reqAuthzID $ reqControls $ reqRespControls $
        reqEnd $ reqResult $ reqMessage $ reqReferral ) )
Note that all of the OIDs used in the logging schema currently resideunder the OpenLDAP Experimental branch. It is anticipated that theywill migrate to a Standard branch in the future.

An overview of the attributes follows:reqStartandreqEndprovide the start and end time of the operation, respectively. They usegeneralizedTime syntax. ThereqStartattribute is also used as the RDN for each log entry.

ThereqTypeattribute is a simple string containing the type of operationbeing logged, e.g.add,delete,search,etc. For extended operations, the type also includes the OID of theextended operation, e.g.extended(1.1.1.1)

ThereqSessionattribute is an implementation-specific identifier that is common toall the operations associated with the same LDAP session. Currently thisis slapd's internal connection ID, stored in decimal.

ThereqDNattribute is the distinguishedName of the target of the operation. E.g., fora Bind request, this is the Bind DN. For an Add request, this is the DNof the entry being added. For a Search request, this is the base DN ofthe search.

ThereqAuthzIDattribute is the distinguishedName of the user that performed the operation.This will usually be the same name as was established at the start of asession by a Bind request (if any) but may be altered in variouscircumstances.

ThereqControlsandreqRespControlsattributes carry any controls sent by the client on the request and returnedby the server in the response, respectively. The attribute values are justuninterpreted octet strings.

ThereqResultattribute is the numeric LDAP result code of the operation, indicatingeither success or a particular LDAP error code. An error code may beaccompanied by a text error message which will be recorded in thereqMessageattribute.

ThereqReferralattribute carries any referrals that were returned with the result of therequest.

Operation-specific classes are defined with additional attributes to carryall of the relevant parameters associated with the operation:

( 1.3.6.1.4.1.4203.666.11.5.2.4
    NAME 'auditAbandon'
    DESC 'Abandon operation'
    SUP auditObject STRUCTURAL
    MUST reqId )
For theAbandonoperation thereqIdattribute contains the message ID of the request that was abandoned.

( 1.3.6.1.4.1.4203.666.11.5.2.5
    NAME 'auditAdd'
    DESC 'Add operation'
    SUP auditWriteObject STRUCTURAL
    MUST reqMod )
TheAddclass inherits from theauditWriteObjectclass. The Add and Modify classes are very similar. ThereqModattribute carries all of the attributes of the original entry being added.(Or in the case of a Modify operation, all of the modifications beingperformed.) The values are formatted as
attribute:<+|-|=|#> [ value]
Where '+' indicates an Add of a value, '-' for Delete, '=' for Replace,and '#' for Increment. In an Add operation, all of the reqMod values willhave the '+' designator.

( 1.3.6.1.4.1.4203.666.11.5.2.6
    NAME 'auditBind'
    DESC 'Bind operation'
    SUP auditObject STRUCTURAL
    MUST ( reqVersion $ reqMethod ) )
TheBindclass includes thereqVersionattribute which contains the LDAP protocol version specified in the Bindas well as thereqMethodattribute which contains the Bind Method used in the Bind. This will bethe stringSIMPLEfor LDAP Simple Binds orSASL(<mech>)for SASL Binds.Note that unless configured as a global overlay, only Simple Binds usingDNs that reside in the current database will be logged.

( 1.3.6.1.4.1.4203.666.11.5.2.7
    NAME 'auditCompare'
    DESC 'Compare operation'
    SUP auditObject STRUCTURAL
    MUST reqAssertion )
For theCompareoperation thereqAssertionattribute carries the Attribute Value Assertion used in the compare request.

( 1.3.6.1.4.1.4203.666.11.5.2.8
    NAME 'auditDelete'
    DESC 'Delete operation'
    SUP auditWriteObject STRUCTURAL
    MAY reqOld )
TheDeleteoperation needs no further parameters. However, thereqOldattribute may optionally be used to record the contents of the entry priorto its deletion. The values are formatted as
attribute: value
ThereqOldattribute is only populated if the entry being deleted matches theconfiguredlogoldfilter.

( 1.3.6.1.4.1.4203.666.11.5.2.9
    NAME 'auditModify'
    DESC 'Modify operation'
    SUP auditWriteObject STRUCTURAL
    MAY reqOld MUST reqMod )
TheModifyoperation contains a description of modifications in thereqModattribute, which was already described above in the Add operation. It mayoptionally contain the previous contents of any modified attributes in thereqOldattribute, using the same format as described above for the Delete operation.ThereqOldattribute is only populated if the entry being modified matches theconfiguredlogoldfilter.

( 1.3.6.1.4.1.4203.666.11.5.2.10
    NAME 'auditModRDN'
    DESC 'ModRDN operation'
    SUP auditWriteObject STRUCTURAL
    MUST ( reqNewRDN $ reqDeleteOldRDN )
    MAY reqNewSuperior )
TheModRDNclass uses thereqNewRDNattribute to carry the new RDN of the request.ThereqDeleteOldRDNattribute is a Boolean value showingTRUEif the old RDN was deleted from the entry, orFALSEif the old RDN was preserved.ThereqNewSuperiorattribute carries the DN of the new parent entry if the request specifiedthe new parent.

( 1.3.6.1.4.1.4203.666.11.5.2.11
    NAME 'auditSearch'
    DESC 'Search operation'
    SUP auditReadObject STRUCTURAL
    MUST ( reqScope $ reqDerefAliases $ reqAttrsOnly )
    MAY ( reqFilter $ reqAttr $ reqEntries $ reqSizeLimit $
          reqTimeLimit ) )
For theSearchclass thereqScopeattribute contains the scope of the original search request, using thevalues specified for the LDAP URL format. I.e.base,one,sub,orsubord.ThereqDerefAliasesattribute is one ofnever,finding,searching,oralways,denoting how aliases will be processed during the search.ThereqAttrsOnlyattribute is a Boolean value showingTRUE if only attribute names were requested, orFALSEif attributes and their values were requested.ThereqFilterattribute carries the filter used in the search request.ThereqAttrattribute lists the requested attributes if specific attributes wererequested.ThereqEntriesattribute is the integer count of how many entries were returned bythis search request.ThereqSizeLimitandreqTimeLimitattributes indicate what limits were requested on the search operation.

( 1.3.6.1.4.1.4203.666.11.5.2.12
    NAME 'auditExtended'
    DESC 'Extended operation'
    SUP auditObject STRUCTURAL
    MAY reqData )
TheExtendedclass represents an LDAP Extended Operation. As noted above, the actual OID ofthe operation is included in thereqTypeattribute of the parent class. If any optional data was provided with therequest, it will be contained in thereqDataattribute as an uninterpreted octet string.

 

NOTES

The Access Log implemented by this overlay may be used for a variety ofother tasks, e.g. as a ChangeLog for a replication mechanism, as wellas for security/audit logging purposes.

 

FILES

/etc/openldap/slapd.conf
default slapd configuration file
 

SEE ALSO

slapd.conf(5).

 

ACKNOWLEDGEMENTS

This module was written in 2005 by Howard Chu of Symas Corporation.


 

Index

NAME
SYNOPSIS
DESCRIPTION
CONFIGURATION
EXAMPLES
SCHEMA
NOTES
FILES
SEE ALSO
ACKNOWLEDGEMENTS

This document was created byman2html,using the manual pages.