getauclassent(3)
NAME
getauclassent, getauclassnam, setauclass, endauclass − get audit_class entry
SYNOPSIS
cc [ flag ... ] file ... −lbsm −lsocket −lnsl −lintl [ library ... ]
#include <sys/param.h>
#include <bsm/libbsm.h>
struct au_class_ent ∗getauclassnam( const char ∗name);
struct au_class_ent ∗getauclassent( void);
void setauclass( void);
void endauclass( void);
AVAILABILITY
The functionality described in this man page is available only if the Basic Security Module (BSM) has been enabled. See bsmconv(1M) for more information.
DESCRIPTION
getauclassent() and getauclassnam() each return an audit_class entry.
getauclassnam() searches for an audit_class entry with a given class name name.
getauclassent() enumerates audit_class entries: successive calls to getauclassent() will return either successive audit_class entries or NULL.
setauclass() “rewinds” to the beginning of the enumeration of audit_class entries. Calls to getauclassnam() may leave the enumeration in an indeterminate state, so setauclass() should be called before the first getauclassent().
endauclass() may be called to indicate that audit_class processing is complete; the system may then close any open audit_class file, deallocate storage, and so forth.
The internal representation of an audit_user entry is an au_class_ent structure defined in <bsm/libbsm.h> with the following members:
char∗ac_name;
au_class_tac_class;
char∗ac_desc;
RETURN VALUES
getauclassnam() returns a pointer to a struct au_class_ent if it successfully locates the requested entry; otherwise it returns NULL.
getauclassent() returns a pointer to a struct au_class_ent if it successfully enumerates an entry; otherwise it returns NULL, indicating the end of the enumeration.
FILES
/etc/security/audit_class
SEE ALSO
bsmconv(1M), audit_class(4), audit_event(4)
NOTES
All information is contained in a static area, so it must be copied if it is to be saved.
Sun Microsystems — Last change: 6 May 1993