AuthzReportSecurityEvent function

The AuthzReportSecurityEvent function generates a security audit for a registered security event source.

Auditing for the object access event category must be enabled for the AuthzReportSecurityEvent function to generate a security audit. The available audit types are defined in the AUDIT_PARAM_TYPE enumeration.

Syntax

AUTHZAPI BOOL AuthzReportSecurityEvent(
  DWORD                                dwFlags,
  AUTHZ_SECURITY_EVENT_PROVIDER_HANDLE hEventProvider,
  DWORD                                dwAuditId,
  PSID                                 pUserSid,
  DWORD                                dwCount,
  ...                                  
);

Parameters

dwFlags

Flags that specify the type of audit generated. The following table shows the possible values.

Value Meaning
APF_AuditFailure
0x00000000
Failure audits are generated.
APF_AuditSuccess
0x00000001
Success audits are generated.

hEventProvider

A handle to the registered security event source to use for the audit.

dwAuditId

The identifier of the audit.

pUserSid

A pointer to the security identifier (SID) that will be listed as the source of the audit in the event log.

dwCount

The number of AuditParamFlag type/value pairs that appear in the variable arguments section that follows this parameter.

arg6

A list of AuditParamFlag type/value pairs that provide additional information about the event.

Return Value

If the function succeeds, the function returns TRUE.

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

Requirements

   
Minimum supported client None supported
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

AuthzRegisterSecurityEventSource

AuthzReportSecurityEventFromParams