/*
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
* Software is furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice (including the next
* paragraph) shall be included in all copies or substantial portions of the
* Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
* DEALINGS IN THE SOFTWARE.
*/
#ifndef _BSM_AUDITWRITE_H
#define _BSM_AUDITWRITE_H
#ifdef __cplusplus
extern "C" {
#endif
/*
* This file contains declarations and defines for use with
* auditwrite(3).
*/
/* Mandatory last arg on auditwrite(3) invocation line */
#define AW_END (0)
/* control commands */
/*
* Attribute commands. These tell audiwrite(3) what kind
* of data to expect.
*/
/*
* The next is the last and highest numbered valid command code; if more
* are added, remember to update AW_CMD_MAX in auditwrite.c.
*/
/*
* describe data specified with AW_DATA
*/
/*
* describe how to print data specified with AW_DATA
*/
/*
* auditwrite(3) error indicators
*/
#define AW_ERR_NO_ERROR (0)
#ifdef __STDC__
extern int auditwrite(int, ...); /* writes audit records */
extern int aw_errno; /* error number */
extern void aw_perror(const char *); /* print error */
extern void aw_perror_r(const int, const char *); /* print error for */
/* record descriptor */
extern int aw_geterrno(const int); /* get error for record descriptor */
extern char *aw_strerror(const int); /* format error into string */
#else
extern int auditwrite();
extern int aw_errno;
extern void aw_perror();
extern void aw_perror_r();
extern int aw_geterrno();
extern char *aw_strerror();
#endif /* __STDC__ */
#ifdef __cplusplus
}
#endif
#endif /* _BSM_AUDITWRITE_H */