AuthzInitializeObjectAccessAuditEvent function

The AuthzInitializeObjectAccessAuditEvent function initializes auditing for an object.

Syntax

AUTHZAPI BOOL AuthzInitializeObjectAccessAuditEvent(
  DWORD                         Flags,
  AUTHZ_AUDIT_EVENT_TYPE_HANDLE hAuditEventType,
  PWSTR                         szOperationType,
  PWSTR                         szObjectType,
  PWSTR                         szObjectName,
  PWSTR                         szAdditionalInfo,
  PAUTHZ_AUDIT_EVENT_HANDLE     phAuditEvent,
  DWORD                         dwAdditionalParameterCount,
  ...                           
);

Parameters

Flags

Modifies the audit. This parameter can be one of the following values.

Value Meaning
AUTHZ_NO_SUCCESS_AUDIT
Disable generation of success audits.
AUTHZ_NO_FAILURE_AUDIT
Disable generation of failure audits.
AUTHZ_NO_ALLOC_STRINGS
Use pointers to the passed strings instead of allocating memory and copying the strings. The calling application must ensure that the passed memory stays valid during access checks.

hAuditEventType

Reserved. This parameter should be set to NULL.

szOperationType

String that indicates the operation that is to be audited.

szObjectType

String that indicates the type of object being accessed.

szObjectName

String the indicates the name of the object being accessed.

szAdditionalInfo

String, defined by the Resource Manager, for additional audit information.

phAuditEvent

Pointer that receives an AUTHZ_AUDIT_EVENT_HANDLE structure.

dwAdditionalParameterCount

Must be set to zero.

...

Additional parameters.

Return value

If the function succeeds, it returns TRUE.

If the function fails, it returns FALSE. For extended error information, call GetLastError.

Requirements

   
Minimum supported client Windows XP [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Target Platform Windows
Header authz.h
Library Authz.lib
DLL Authz.dll
Redistributable Windows Server 2003 Administration Tools Pack on Windows XP

See also

AuthzAccessCheck

Basic Access Control Functions