1ca0716f5SRobert Watson.\"- 206edd2f1SRobert Watson.\" Copyright (c) 2008-2009 Apple Inc. 3ca0716f5SRobert Watson.\" Copyright (c) 2005 Robert N. M. Watson 4ca0716f5SRobert Watson.\" Copyright (c) 2005 Tom Rhodes 5ca0716f5SRobert Watson.\" Copyright (c) 2005 Wayne J. Salamon 6ca0716f5SRobert Watson.\" All rights reserved. 7ca0716f5SRobert Watson.\" 8ca0716f5SRobert Watson.\" Redistribution and use in source and binary forms, with or without 9ca0716f5SRobert Watson.\" modification, are permitted provided that the following conditions 10ca0716f5SRobert Watson.\" are met: 11ca0716f5SRobert Watson.\" 1. Redistributions of source code must retain the above copyright 12ca0716f5SRobert Watson.\" notice, this list of conditions and the following disclaimer. 13ca0716f5SRobert Watson.\" 2. Redistributions in binary form must reproduce the above copyright 14ca0716f5SRobert Watson.\" notice, this list of conditions and the following disclaimer in the 15ca0716f5SRobert Watson.\" documentation and/or other materials provided with the distribution. 16ca0716f5SRobert Watson.\" 17ca0716f5SRobert Watson.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND 18ca0716f5SRobert Watson.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 19ca0716f5SRobert Watson.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 20ca0716f5SRobert Watson.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 21ca0716f5SRobert Watson.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22ca0716f5SRobert Watson.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 23ca0716f5SRobert Watson.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 24ca0716f5SRobert Watson.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 25ca0716f5SRobert Watson.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26ca0716f5SRobert Watson.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27ca0716f5SRobert Watson.\" SUCH DAMAGE. 28ca0716f5SRobert Watson.\" 29*5e386598SRobert Watson.Dd April 7, 2016 30ca0716f5SRobert Watson.Dt AUDITON 2 31ca0716f5SRobert Watson.Os 32ca0716f5SRobert Watson.Sh NAME 33ca0716f5SRobert Watson.Nm auditon 34bc168a6cSRobert Watson.Nd "configure system audit parameters" 35ca0716f5SRobert Watson.Sh SYNOPSIS 36ca0716f5SRobert Watson.In bsm/audit.h 37ca0716f5SRobert Watson.Ft int 38ca0716f5SRobert Watson.Fn auditon "int cmd" "void *data" "u_int length" 39ca0716f5SRobert Watson.Sh DESCRIPTION 40ca0716f5SRobert WatsonThe 41bc168a6cSRobert Watson.Fn auditon 42ca0716f5SRobert Watsonsystem call is used to manipulate various audit control operations. 43bc168a6cSRobert WatsonThe 44bc168a6cSRobert Watson.Fa data 45bc168a6cSRobert Watsonargument 46ca0716f5SRobert Watsonshould point to a structure whose type depends on the command. 47bc168a6cSRobert WatsonThe 48bc168a6cSRobert Watson.Fa length 49bc168a6cSRobert Watsonargument 50bc168a6cSRobert Watsonspecifies the size of 51bc168a6cSRobert Watson.Fa *data 52ca0716f5SRobert Watsonin bytes. 53bc168a6cSRobert WatsonThe 54bc168a6cSRobert Watson.Fa cmd 55bc168a6cSRobert Watsonargument 56ca0716f5SRobert Watsonmay be any of the following: 57ca0716f5SRobert Watson.Bl -tag -width ".It Dv A_GETPINFO_ADDR" 58ca0716f5SRobert Watson.It Dv A_SETPOLICY 59ca0716f5SRobert WatsonSet audit policy flags. 60bc168a6cSRobert WatsonThe 61bc168a6cSRobert Watson.Fa data 62bc168a6cSRobert Watsonargument 63bc168a6cSRobert Watsonmust point to a 64c0020399SRobert Watson.Vt int 6552267f74SRobert Watsonvalue set to one or more the following audit 6652267f74SRobert Watsonpolicy control values bitwise OR'ed together: 6752267f74SRobert Watson.Dv AUDIT_CNT , 6852267f74SRobert Watson.Dv AUDIT_AHLT , 6952267f74SRobert Watson.Dv AUDIT_ARGV , 70ca0716f5SRobert Watsonand 7152267f74SRobert Watson.Dv AUDIT_ARGE . 7252267f74SRobert WatsonIf 7352267f74SRobert Watson.Dv AUDIT_CNT is set, the system will continue even if it becomes low 7452267f74SRobert Watsonon space and discontinue logging events until the low space condition is 7552267f74SRobert Watsonremedied. 7652267f74SRobert WatsonIf it is not set, audited events will block until the low space 7752267f74SRobert Watsoncondition is remedied. 7852267f74SRobert WatsonUnaudited events, however, are unaffected. 7952267f74SRobert WatsonIf 8052267f74SRobert Watson.Dv AUDIT_AHLT is set, a 81ca0716f5SRobert Watson.Xr panic 9 8252267f74SRobert Watsonif it cannot write an event to the global audit log file. 8352267f74SRobert WatsonIf 8452267f74SRobert Watson.Dv AUDIT_ARGV 8552267f74SRobert Watsonis set, then the argument list passed to the 8652267f74SRobert Watson.Xr execve 2 87*5e386598SRobert Watsonsystem call will be audited. 88*5e386598SRobert WatsonIf 8952267f74SRobert Watson.Dv AUDIT_ARGE 9052267f74SRobert Watsonis set, then the environment variables passed to the 9152267f74SRobert Watson.Xr execve 2 92*5e386598SRobert Watsonsystem call will be audited. 93*5e386598SRobert WatsonThe default policy is none of the audit policy 9452267f74SRobert Watsoncontrol flags set. 95ca0716f5SRobert Watson.It Dv A_SETKAUDIT 96c0020399SRobert WatsonSet the host information. 97c0020399SRobert WatsonThe 98c0020399SRobert Watson.Fa data 99c0020399SRobert Watsonargument 100c0020399SRobert Watsonmust point to a 101c0020399SRobert Watson.Vt auditinfo_addr_t 102c0020399SRobert Watsonstructure containing the host IP address information. 103c0020399SRobert WatsonAfter setting, audit records 104c0020399SRobert Watsonthat are created as a result of kernel events will contain 105c0020399SRobert Watsonthis information. 106ca0716f5SRobert Watson.It Dv A_SETKMASK 107ca0716f5SRobert WatsonSet the kernel preselection masks (success and failure). 108bc168a6cSRobert WatsonThe 109bc168a6cSRobert Watson.Fa data 110bc168a6cSRobert Watsonargument 111ca0716f5SRobert Watsonmust point to a 112bc168a6cSRobert Watson.Vt au_mask_t 11352267f74SRobert Watsonstructure containing the mask values as defined in 11452267f74SRobert Watson.In bsm/audit.h . 115ca0716f5SRobert WatsonThese masks are used for non-attributable audit event preselection. 11652267f74SRobert WatsonThe field 11752267f74SRobert Watson.Fa am_success 11852267f74SRobert Watsonspecifies which classes of successful audit events are to be logged to the 119*5e386598SRobert Watsonaudit trail. 120*5e386598SRobert WatsonThe field 12152267f74SRobert Watson.Fa am_failure 122*5e386598SRobert Watsonspecifies which classes of failed audit events are to be logged. 123*5e386598SRobert WatsonThe value of 12452267f74SRobert Watsonboth fields is the bitwise OR'ing of the audit event classes specified in 12552267f74SRobert Watson.Fa bsm/audit.h . 12652267f74SRobert WatsonThe various audit classes are described more fully in 12752267f74SRobert Watson.Xr audit_class 5 . 128ca0716f5SRobert Watson.It Dv A_SETQCTRL 129ca0716f5SRobert WatsonSet kernel audit queue parameters. 130bc168a6cSRobert WatsonThe 131bc168a6cSRobert Watson.Fa data 132bc168a6cSRobert Watsonargument 133ca0716f5SRobert Watsonmust point to a 134bc168a6cSRobert Watson.Vt au_qctrl_t 13552267f74SRobert Watsonstructure (defined in 13652267f74SRobert Watson.In bsm/audit.h ) 13752267f74SRobert Watsoncontaining the kernel audit queue control settings: 13852267f74SRobert Watson.Fa aq_hiwater , 13952267f74SRobert Watson.Fa aq_lowater , 14052267f74SRobert Watson.Fa aq_bufsz , 14152267f74SRobert Watson.Fa aq_delay , 142ca0716f5SRobert Watsonand 14352267f74SRobert Watson.Fa aq_minfree . 14452267f74SRobert WatsonThe field 14552267f74SRobert Watson.Fa aq_hiwater 14652267f74SRobert Watsondefines the maximum number of audit record entries in the queue used to store 14752267f74SRobert Watsonthe audit records ready for delivery to disk. 14852267f74SRobert WatsonNew records are inserted at the tail of the queue and removed from the head. 14952267f74SRobert WatsonFor new records which would exceed the 15052267f74SRobert Watsonhigh water mark, the calling thread is inserted into the wait queue, waiting 15152267f74SRobert Watsonfor the audit queue to have enough space available as defined with the field 15252267f74SRobert Watson.Fa aq_lowater . 15352267f74SRobert WatsonThe field 15452267f74SRobert Watson.Fa aq_bufsz 15552267f74SRobert Watsondefines the maximum length of the audit record that can be supplied with 15652267f74SRobert Watson.Xr audit 2 . 15752267f74SRobert WatsonThe field 15852267f74SRobert Watson.Fa aq_delay 15952267f74SRobert Watsonis unused. 16052267f74SRobert WatsonThe field 16152267f74SRobert Watson.Fa aq_minfree 16252267f74SRobert Watsonspecifies the minimum amount of free blocks on the disk device used to store 16352267f74SRobert Watsonaudit records. 16452267f74SRobert WatsonIf the value of free blocks falls below the configured 16552267f74SRobert Watsonminimum amount, the kernel informs the audit daemon about low disk space. 16652267f74SRobert WatsonThe value is to be specified in percent of free file system blocks. 16752267f74SRobert WatsonA value of 0 results in a disabling of the check. 168c0020399SRobert WatsonThe default and maximum values (default/maximum) for the 169c0020399SRobert Watsonaudit queue control parameters are: 170c0020399SRobert Watson.Pp 171c0020399SRobert Watson.Bl -column aq_hiwater -offset indent -compact 172c0020399SRobert Watson.It aq_hiwater Ta 100/10000 (audit records) 173c0020399SRobert Watson.It aq_lowater Ta 10/aq_hiwater (audit records) 174c0020399SRobert Watson.It aq_bufsz Ta 32767/1048576 (bytes) 175c0020399SRobert Watson.It aq_delay Ta (Not currently used.) 176c0020399SRobert Watson.El 177ca0716f5SRobert Watson.It Dv A_SETSTAT 178ca0716f5SRobert WatsonReturn 179ca0716f5SRobert Watson.Er ENOSYS . 18052267f74SRobert Watson(Not implemented.) 181ca0716f5SRobert Watson.It Dv A_SETUMASK 182ca0716f5SRobert WatsonReturn 183ca0716f5SRobert Watson.Er ENOSYS . 18452267f74SRobert Watson(Not implemented.) 185ca0716f5SRobert Watson.It Dv A_SETSMASK 186ca0716f5SRobert WatsonReturn 187ca0716f5SRobert Watson.Er ENOSYS . 18852267f74SRobert Watson(Not implemented.) 189ca0716f5SRobert Watson.It Dv A_SETCOND 190ca0716f5SRobert WatsonSet the current auditing condition. 191bc168a6cSRobert WatsonThe 192bc168a6cSRobert Watson.Fa data 193bc168a6cSRobert Watsonargument 194bc168a6cSRobert Watsonmust point to a 195c0020399SRobert Watson.Vt int 196bc168a6cSRobert Watsonvalue containing the new 197ca0716f5SRobert Watsonaudit condition, one of 198ca0716f5SRobert Watson.Dv AUC_AUDITING , 199ca0716f5SRobert Watson.Dv AUC_NOAUDIT , 200ca0716f5SRobert Watsonor 201ca0716f5SRobert Watson.Dv AUC_DISABLED . 20252267f74SRobert WatsonIf 20352267f74SRobert Watson.Dv AUC_NOAUDIT 204*5e386598SRobert Watsonis set, then auditing is temporarily suspended. 205*5e386598SRobert WatsonIf 20652267f74SRobert Watson.Dv AUC_AUDITING 207*5e386598SRobert Watsonis set, auditing is resumed. 208*5e386598SRobert WatsonIf 20952267f74SRobert Watson.Dv AUC_DISABLED 21052267f74SRobert Watsonis set, the auditing system will 21152267f74SRobert Watsonshutdown, draining all audit records and closing out the audit trail file. 212ca0716f5SRobert Watson.It Dv A_SETCLASS 213ca0716f5SRobert WatsonSet the event class preselection mask for an audit event. 214bc168a6cSRobert WatsonThe 215bc168a6cSRobert Watson.Fa data 216bc168a6cSRobert Watsonargument 217ca0716f5SRobert Watsonmust point to a 218bc168a6cSRobert Watson.Vt au_evclass_map_t 219ca0716f5SRobert Watsonstructure containing the audit event and mask. 22052267f74SRobert WatsonThe field 22152267f74SRobert Watson.Fa ec_number 22252267f74SRobert Watsonis the audit event and 22352267f74SRobert Watson.Fa ec_class 224*5e386598SRobert Watsonis the audit class mask. 225*5e386598SRobert WatsonSee 22652267f74SRobert Watson.Xr audit_event 5 22752267f74SRobert Watsonfor more information on audit event to class mapping. 228ca0716f5SRobert Watson.It Dv A_SETPMASK 229ca0716f5SRobert WatsonSet the preselection masks for a process. 230bc168a6cSRobert WatsonThe 231bc168a6cSRobert Watson.Fa data 232bc168a6cSRobert Watsonargument 233ca0716f5SRobert Watsonmust point to a 234bc168a6cSRobert Watson.Vt auditpinfo_t 235ca0716f5SRobert Watsonstructure that contains the given process's audit 236ca0716f5SRobert Watsonpreselection masks for both success and failure. 23752267f74SRobert WatsonThe field 23852267f74SRobert Watson.Fa ap_pid 23952267f74SRobert Watsonis the process id of the target process. 24052267f74SRobert WatsonThe field 24152267f74SRobert Watson.Fa ap_mask 24252267f74SRobert Watsonmust point to a 24352267f74SRobert Watson.Fa au_mask_t 24452267f74SRobert Watsonstructure which holds the preselection masks as described in the 245aa772005SRobert Watson.Dv A_SETKMASK 24652267f74SRobert Watsonsection above. 247ca0716f5SRobert Watson.It Dv A_SETFSIZE 248ca0716f5SRobert WatsonSet the maximum size of the audit log file. 249bc168a6cSRobert WatsonThe 250bc168a6cSRobert Watson.Fa data 251bc168a6cSRobert Watsonargument 252ca0716f5SRobert Watsonmust point to a 253bc168a6cSRobert Watson.Vt au_fstat_t 254ca0716f5SRobert Watsonstructure with the 255bc168a6cSRobert Watson.Va af_filesz 256bc168a6cSRobert Watsonfield set to the maximum audit log file size. 257bc168a6cSRobert WatsonA value of 0 258ca0716f5SRobert Watsonindicates no limit to the size. 259ca0716f5SRobert Watson.It Dv A_GETCLASS 260ca0716f5SRobert WatsonReturn the event to class mapping for the designated audit event. 261bc168a6cSRobert WatsonThe 262bc168a6cSRobert Watson.Fa data 263bc168a6cSRobert Watsonargument 264ca0716f5SRobert Watsonmust point to a 265bc168a6cSRobert Watson.Vt au_evclass_map_t 266*5e386598SRobert Watsonstructure. 267*5e386598SRobert WatsonSee the 26852267f74SRobert Watson.Dv A_SETCLASS 26952267f74SRobert Watsonsection above for more information. 270ca0716f5SRobert Watson.It Dv A_GETKAUDIT 271c0020399SRobert WatsonGet the current host information. 272c0020399SRobert WatsonThe 273c0020399SRobert Watson.Fa data 274c0020399SRobert Watsonargument 275c0020399SRobert Watsonmust point to a 276c0020399SRobert Watson.Vt auditinfo_addr_t 277c0020399SRobert Watsonstructure. 278ca0716f5SRobert Watson.It Dv A_GETPINFO 279ca0716f5SRobert WatsonReturn the audit settings for a process. 280bc168a6cSRobert WatsonThe 281bc168a6cSRobert Watson.Fa data 282bc168a6cSRobert Watsonargument 283ca0716f5SRobert Watsonmust point to a 284bc168a6cSRobert Watson.Vt auditpinfo_t 285ca0716f5SRobert Watsonstructure which will be set to contain 28652267f74SRobert Watson.Fa ap_auid 28752267f74SRobert Watson(the audit ID), 28852267f74SRobert Watson.Fa ap_mask 28952267f74SRobert Watson(the preselection mask), 29052267f74SRobert Watson.Fa ap_termid 29152267f74SRobert Watson(the terminal ID), and 29252267f74SRobert Watson.Fa ap_asid 29352267f74SRobert Watson(the audit session ID) 29452267f74SRobert Watsonof the given target process. 29552267f74SRobert WatsonThe process ID of the target process is passed 29652267f74SRobert Watsoninto the kernel using the 29752267f74SRobert Watson.Fa ap_pid 29852267f74SRobert Watsonfield. 29952267f74SRobert WatsonSee the section 30052267f74SRobert Watson.Dv A_SETPMASK 30152267f74SRobert Watsonabove and 30252267f74SRobert Watson.Xr getaudit 2 30352267f74SRobert Watsonfor more information. 304ca0716f5SRobert Watson.It Dv A_GETPINFO_ADDR 30552267f74SRobert WatsonReturn the extended audit settings for a process. 30652267f74SRobert WatsonThe 30752267f74SRobert Watson.Fa data 30852267f74SRobert Watsonargument 30952267f74SRobert Watsonmust point to a 31052267f74SRobert Watson.Vt auditpinfo_addr_t 31152267f74SRobert Watsonstructure which is similar to the 312*5e386598SRobert Watson.Vt auditpinfo_t 31352267f74SRobert Watsonstructure described above. 31452267f74SRobert WatsonThe exception is the 31552267f74SRobert Watson.Fa ap_termid 31652267f74SRobert Watson(the terminal ID) field which points to a 31752267f74SRobert Watson.Vt au_tid_addr_t 31852267f74SRobert Watsonstructure can hold much a larger terminal address and an address type. 31952267f74SRobert WatsonThe process ID of the target process is passed into the kernel using the 32052267f74SRobert Watson.Fa ap_pid 32152267f74SRobert Watsonfield. 32252267f74SRobert WatsonSee the section 32352267f74SRobert Watson.Dv A_SETPMASK 32452267f74SRobert Watsonabove and 32552267f74SRobert Watson.Xr getaudit 2 32652267f74SRobert Watsonfor more information. 327c0020399SRobert Watson.It Dv A_GETSINFO_ADDR 328c0020399SRobert WatsonReturn the extended audit settings for a session. 329c0020399SRobert WatsonThe 330c0020399SRobert Watson.Fa data 331c0020399SRobert Watsonargument 332c0020399SRobert Watsonmust point to a 333c0020399SRobert Watson.Vt auditinfo_addr_t 334c0020399SRobert Watsonstructure. 335c0020399SRobert WatsonThe audit session ID of the target session is passed 336c0020399SRobert Watsoninto the kernel using the 337c0020399SRobert Watson.Fa ai_asid 338*5e386598SRobert Watsonfield. 339*5e386598SRobert WatsonSee 340c0020399SRobert Watson.Xr getaudit_addr 2 341c0020399SRobert Watsonfor more information about the 342c0020399SRobert Watson.Vt auditinfo_addr_t 343c0020399SRobert Watsonstructure. 344ca0716f5SRobert Watson.It Dv A_GETKMASK 345ca0716f5SRobert WatsonReturn the current kernel preselection masks. 346bc168a6cSRobert WatsonThe 347bc168a6cSRobert Watson.Fa data 348bc168a6cSRobert Watsonargument 349ca0716f5SRobert Watsonmust point to a 350bc168a6cSRobert Watson.Vt au_mask_t 351ca0716f5SRobert Watsonstructure which will be set to 352ca0716f5SRobert Watsonthe current kernel preselection masks for non-attributable events. 353ca0716f5SRobert Watson.It Dv A_GETPOLICY 354ca0716f5SRobert WatsonReturn the current audit policy setting. 355bc168a6cSRobert WatsonThe 356bc168a6cSRobert Watson.Fa data 357bc168a6cSRobert Watsonargument 358bc168a6cSRobert Watsonmust point to a 359c0020399SRobert Watson.Vt int 360bc168a6cSRobert Watsonvalue which will be set to 361ca0716f5SRobert Watsonone of the current audit policy flags. 36252267f74SRobert WatsonThe audit policy flags are 36352267f74SRobert Watsondescribed in the 36452267f74SRobert Watson.Dv A_SETPOLICY 36552267f74SRobert Watsonsection above. 366ca0716f5SRobert Watson.It Dv A_GETQCTRL 367ca0716f5SRobert WatsonReturn the current kernel audit queue control parameters. 368bc168a6cSRobert WatsonThe 369bc168a6cSRobert Watson.Fa data 370bc168a6cSRobert Watsonargument 371ca0716f5SRobert Watsonmust point to a 372bc168a6cSRobert Watson.Vt au_qctrl_t 373ca0716f5SRobert Watsonstructure which will be set to the current 374ca0716f5SRobert Watsonkernel audit queue control parameters. 37552267f74SRobert WatsonSee the 37652267f74SRobert Watson.Dv A_SETQCTL 37752267f74SRobert Watsonsection above for more information. 378ca0716f5SRobert Watson.It Dv A_GETFSIZE 379ca0716f5SRobert WatsonReturns the maximum size of the audit log file. 380bc168a6cSRobert WatsonThe 381bc168a6cSRobert Watson.Fa data 382bc168a6cSRobert Watsonargument 383ca0716f5SRobert Watsonmust point to a 384bc168a6cSRobert Watson.Vt au_fstat_t 385bc168a6cSRobert Watsonstructure. 386bc168a6cSRobert WatsonThe 387bc168a6cSRobert Watson.Va af_filesz 38823bf6e20SRobert Watsonfield will be set to the maximum audit log file size. 38923bf6e20SRobert WatsonA value of 0 indicates no limit to the size. 390ca0716f5SRobert WatsonThe 391bc168a6cSRobert Watson.Va af_currsz 392bc168a6cSRobert Watsonfield 393ca0716f5SRobert Watsonwill be set to the current audit log file size. 394ca0716f5SRobert Watson.It Dv A_GETCWD 395ca0716f5SRobert Watson.\" [COMMENTED OUT]: Valid description, not yet implemented. 396ca0716f5SRobert Watson.\" Return the current working directory as stored in the audit subsystem. 397ca0716f5SRobert WatsonReturn 398ca0716f5SRobert Watson.Er ENOSYS . 39952267f74SRobert Watson(Not implemented.) 400ca0716f5SRobert Watson.It Dv A_GETCAR 401ca0716f5SRobert Watson.\" [COMMENTED OUT]: Valid description, not yet implemented. 402ca0716f5SRobert Watson.\"Stores and returns the current active root as stored in the audit 403ca0716f5SRobert Watson.\"subsystem. 404ca0716f5SRobert WatsonReturn 405ca0716f5SRobert Watson.Er ENOSYS . 40652267f74SRobert Watson(Not implemented.) 407ca0716f5SRobert Watson.It Dv A_GETSTAT 408ca0716f5SRobert Watson.\" [COMMENTED OUT]: Valid description, not yet implemented. 409ca0716f5SRobert Watson.\"Return the statistics stored in the audit system. 410ca0716f5SRobert WatsonReturn 411ca0716f5SRobert Watson.Er ENOSYS . 41252267f74SRobert Watson(Not implemented.) 413ca0716f5SRobert Watson.It Dv A_GETCOND 414ca0716f5SRobert WatsonReturn the current auditing condition. 415bc168a6cSRobert WatsonThe 416bc168a6cSRobert Watson.Fa data 417bc168a6cSRobert Watsonargument 418bc168a6cSRobert Watsonmust point to a 419c0020399SRobert Watson.Vt int 420bc168a6cSRobert Watsonvalue which will be set to 42152267f74SRobert Watsonthe current audit condition, one of 42252267f74SRobert Watson.Dv AUC_AUDITING , 42352267f74SRobert Watson.Dv AUC_NOAUDIT 424ca0716f5SRobert Watsonor 42552267f74SRobert Watson.Dv AUC_DISABLED . 42652267f74SRobert WatsonSee the 42752267f74SRobert Watson.Dv A_SETCOND 42852267f74SRobert Watsonsection above for more information. 429ca0716f5SRobert Watson.It Dv A_SENDTRIGGER 430ca0716f5SRobert WatsonSend a trigger to the audit daemon. 431bc168a6cSRobert WatsonThe 432bc168a6cSRobert Watson.Fa data 433bc168a6cSRobert Watsonargument 434bc168a6cSRobert Watsonmust point to a 435c0020399SRobert Watson.Vt int 436bc168a6cSRobert Watsonvalue set to one of the acceptable 437ca0716f5SRobert Watsontrigger values: 438ca0716f5SRobert Watson.Dv AUDIT_TRIGGER_LOW_SPACE 439ca0716f5SRobert Watson(low disk space where the audit log resides), 440ca0716f5SRobert Watson.Dv AUDIT_TRIGGER_OPEN_NEW 441ca0716f5SRobert Watson(open a new audit log file), 442ca0716f5SRobert Watson.Dv AUDIT_TRIGGER_READ_FILE 44323bf6e20SRobert Watson(read the 44423bf6e20SRobert Watson.Pa audit_control 44523bf6e20SRobert Watsonfile), 446ca0716f5SRobert Watson.Dv AUDIT_TRIGGER_CLOSE_AND_DIE 447ca0716f5SRobert Watson(close the current log file and exit), 448ca0716f5SRobert Watson.Dv AUDIT_TRIGGER_NO_SPACE 449ca0716f5SRobert Watson(no disk space left for audit log file). 45006edd2f1SRobert Watson.Dv AUDIT_TRIGGER_ROTATE_USER 45106edd2f1SRobert Watson(request audit log file rotation). 45206edd2f1SRobert Watson.Dv AUDIT_TRIGGER_INITIALIZE 45306edd2f1SRobert Watson(initialize audit subsystem for Mac OS X only). 45406edd2f1SRobert Watsonor 45506edd2f1SRobert Watson.Dv AUDIT_TRIGGER_EXPIRE_TRAILS 45606edd2f1SRobert Watson(request audit log file expiration). 457ca0716f5SRobert Watson.El 458ca0716f5SRobert Watson.Sh RETURN VALUES 459ca0716f5SRobert Watson.Rv -std 460ca0716f5SRobert Watson.Sh ERRORS 461ca0716f5SRobert WatsonThe 462ca0716f5SRobert Watson.Fn auditon 463ca0716f5SRobert Watsonfunction will fail if: 464ca0716f5SRobert Watson.Bl -tag -width Er 465ca0716f5SRobert Watson.It Bq Er ENOSYS 466ca0716f5SRobert WatsonReturned by options not yet implemented. 467ca0716f5SRobert Watson.It Bq Er EFAULT 468ca0716f5SRobert WatsonA failure occurred while data transferred to or from 469ca0716f5SRobert Watsonthe kernel failed. 470ca0716f5SRobert Watson.It Bq Er EINVAL 471ca0716f5SRobert WatsonIllegal argument was passed by a system call. 472ca0716f5SRobert Watson.It Bq Er EPERM 473ca0716f5SRobert WatsonThe process does not have sufficient permission to complete 474ca0716f5SRobert Watsonthe operation. 475ca0716f5SRobert Watson.El 476ca0716f5SRobert Watson.Pp 477ca0716f5SRobert WatsonThe 478ca0716f5SRobert Watson.Dv A_SENDTRIGGER 479ca0716f5SRobert Watsoncommand is specific to the 480ca0716f5SRobert Watson.Fx 481ca0716f5SRobert Watsonand Mac OS X implementations, and is not present in Solaris. 482ca0716f5SRobert Watson.Sh SEE ALSO 483ca0716f5SRobert Watson.Xr audit 2 , 484ca0716f5SRobert Watson.Xr auditctl 2 , 485ca0716f5SRobert Watson.Xr getaudit 2 , 486ca0716f5SRobert Watson.Xr getaudit_addr 2 , 487bc168a6cSRobert Watson.Xr getauid 2 , 488bc168a6cSRobert Watson.Xr setaudit 2 , 489ca0716f5SRobert Watson.Xr setaudit_addr 2 , 490bc168a6cSRobert Watson.Xr setauid 2 , 491ca0716f5SRobert Watson.Xr libbsm 3 492bc168a6cSRobert Watson.Sh HISTORY 493bc168a6cSRobert WatsonThe OpenBSM implementation was created by McAfee Research, the security 494bc168a6cSRobert Watsondivision of McAfee Inc., under contract to Apple Computer Inc.\& in 2004. 495bc168a6cSRobert WatsonIt was subsequently adopted by the TrustedBSD Project as the foundation for 496bc168a6cSRobert Watsonthe OpenBSM distribution. 497ca0716f5SRobert Watson.Sh AUTHORS 498bc168a6cSRobert Watson.An -nosplit 499ca0716f5SRobert WatsonThis software was created by McAfee Research, the security research division 500ca0716f5SRobert Watsonof McAfee, Inc., under contract to Apple Computer Inc. 501bc168a6cSRobert WatsonAdditional authors include 502bc168a6cSRobert Watson.An Wayne Salamon , 503bc168a6cSRobert Watson.An Robert Watson , 504bc168a6cSRobert Watsonand SPARTA Inc. 505ca0716f5SRobert Watson.Pp 506ca0716f5SRobert WatsonThe Basic Security Module (BSM) interface to audit records and audit event 507ca0716f5SRobert Watsonstream format were defined by Sun Microsystems. 508ca0716f5SRobert Watson.Pp 509ca0716f5SRobert WatsonThis manual page was written by 510ca0716f5SRobert Watson.An Tom Rhodes Aq trhodes@FreeBSD.org , 511ca0716f5SRobert Watson.An Robert Watson Aq rwatson@FreeBSD.org , 512ca0716f5SRobert Watsonand 513ca0716f5SRobert Watson.An Wayne Salamon Aq wsalamon@FreeBSD.org . 514