saf-audit.c File Reference

ES ESF Manager Auditing. More...

Functions

struct TEventData SafEventData (int type, const void *data, int length)
 Construct a TEventData structure.
mf_uns32 SafInitAuditing (struct SafInit *init)
 ESF Auditing Initialization.
SafRet SafRaiseAuditEvent (int eventid, int category, int numdata,...)
 Raise a general audit event.
SafRet SafRaiseAuditEventA (int eventid, int category, int numdata, struct TEventData *data[])
 Raise a general audit event, with data supplied as an array.

Detailed Description

ES ESF Manager Auditing.

This module handles audit message processing for ESF Manager. Audit messages are sent to the COBOL Audit Facility.


Function Documentation

struct TEventData SafEventData ( int  type,
const void *  data,
int  length 
) [read]

Construct a TEventData structure.

Return a TEventData structure constructed from the input parameters.

Note:
Returned struct types are rvalues, not lvalues. It's valid to pass them as parameters to SafRaiseAuditEvent(), as far as I can tell, which is how this function is currently used; it's valid to assign the return value of this function to a (non-const) struct TEventData variable; and so forth. What doesn't work is eg "SafEventData(a,b,c) = foo".
Parameters:
[in] type Event type
[in] data Pointer to event data
[in] length Length of event data
Returns:
A TEventData structure.

Referenced by SafAdmin(), SafAuth(), SafUpdate(), SafVerify(), and SafXauth().

mf_uns32 SafInitAuditing ( struct SafInit init  ) 

ESF Auditing Initialization.

This function is invoked by the ESF Manager Initialization routine to set the processing environment.

Parameters:
[in] init ESF Manager initialization area (see SafInit).
Returns:
Zero for success or a SafInitRet value for failure.

References SafInit::Config, SafGetEnvFunc(), SafINIT_ENVFUNC, and SafINIT_EXTERNAL.

Referenced by safmgr().

SafRet SafRaiseAuditEvent ( int  eventid,
int  category,
int  numdata,
  ... 
)

Raise a general audit event.

Raise an audit event with the specified ID, category, and optional data.

Parameters:
[in] eventid Event ID
[in] category Event category
[in] numdata Number of TEventData structures that follow
[in] ... TEventData structures containing event data
Returns:
Zero for success or a SafRet value for failure.

References SafLog(), SafMsgCRIT, SafR_EXFAIL, SafR_INTERNAL, SafR_OK, and SafR_RESOURCE.

Referenced by SafAdmin(), SafAuth(), safmgr(), safterm(), SafUpdate(), SafVerify(), and SafXauth().

SafRet SafRaiseAuditEventA ( int  eventid,
int  category,
int  numdata,
struct TEventData *  data[] 
)

Raise a general audit event, with data supplied as an array.

Raise an audit event with the specified ID, category, and optional data supplied as an array rather than variadic parameters.

Parameters:
[in] eventid Event ID
[in] category Event category
[in] numdata Number of TEventData structures that follow
[in] data Array of TEventData structure pointerss containing event data
Returns:
Zero for success or a SafRet value for failure.

References SafR_OK.