PreviousNext

dce_aud_print(3sec)

Formats an audit record into human-readable form.

Used by audit trail examination and analysis tools.

Synopsis

#include <dce/audit.h>

void dce_aud_print(
dce_aud_rec_t ard,
unsigned32 options,
char **buffer,
unsigned32 *status);

Parameters

Input

ard
An audit record descriptor. This descriptor can be obtained from an opened audit trail by calling dce_aud_next( ) or it can be a new record established by calling one of the dce_aud_start_*( ) functions.

options
The options governing the transformation of the binary audit record information into a character string. The value of the options parameter is the bitwise OR of any selected combination of the following option values:

aud_c_evt_all_info Includes all the optional information (that is, groups, address, and event specific information).
aud_c_evt_groups_info Includes the groups' information.
aud_c_evt_address_info Includes the address information.
aud_c_evt_specific_info Includes the event specific information.
Output

buffer
Returns the pointer to a character string converted from the audit record specified by ard.

status
The status code returned by this routine. This status code indicates whether the routine was completed successfully or not. If the routine was not completed successfully, the reason for the failure is given.

Description
The dce_aud_print( ) function transforms the audit record specified by ard into a character string and places it in a buffer. The buffer is allocated using malloc( ), and must later be freed by the caller. (This function allocates the memory to hold the human-readable text of the audit record and returns the address of this memory in the buffer parameter.)

The options parameter is set to the bitwise OR of flag values defined in the dce/audit.h header file. A value of 0 for options will result in default operation, that is, no group, address, and event-specific information is included in the output string.

Return Values
No value is returned.

Errors

The following describes a partial list of errors that might be returned. Refer to the OSF DCE Problem Determination Guide for complete descriptions of all error messages.

aud_s_invalid_record_descriptor
The audit record descriptor is invalid.

aud_s_cannot_allocate_memory
The malloc( ) call failed.

aud_s_ok
The call was successful.


Status codes passed from sec_login_get_current_context( ).

Status codes passed from sec_login_inquire_net_info( ).

Related Information
Functions:

dce_aud_open(3sec)

dce_aud_next(3sec)

dce_aud_start(3sec)

dce_aud_start_with_pac(3sec)

dce_aud_start_with_name(3sec)

dce_aud_start_with_server_binding(3sec)

dce_aud_put_ev_info(3sec)