1AUDITD.CONF:(5)         System Administration Utilities        AUDITD.CONF:(5)
2
3
4

NAME

6       auditd.conf - audit daemon configuration file
7

DESCRIPTION

9       The file /etc/audit/auditd.conf contains configuration information spe‐
10       cific to the audit daemon.  It should contain one configuration keyword
11       per line, an equal sign, and then followed by appropriate configuration
12       information.  The  keywords  recognized  are:   log_file,   log_format,
13       log_group,  priority_boost,  flush,  freq,  num_logs  , disp_qos , dis‐
14       patcher,  name_format  ,   name,   max_log_file,   max_log_file_action,
15       space_left,   action_mail_acct,   space_left_action,  admin_space_left,
16       admin_space_left_action, disk_full_action, disk_error_action,  tcp_lis‐
17       ten_port,      tcp_listen_queue,     tcp_max_per_addr,     use_libwrap,
18       tcp_client_ports, tcp_client_max_idle, enable_krb5, krb5_principal, and
19       krb5_key_file.  These keywords are described below.
20
21
22       log_file
23              This  keyword specifies the full path name to the log file where
24              audit records will be stored. It must be a regular file.
25
26       log_format
27              The log format describes how the information should be stored on
28              disk.  There  are  2 options: raw and nolog.  If set to RAW, the
29              audit records will be stored in a format exactly as  the  kernel
30              sends it. If this option is set to NOLOG then all audit informa‐
31              tion is discarded instead of writing to disk. This mode does not
32              affect data sent to the audit event dispatcher.
33
34       log_group
35              This  keyword  specifies  the  group  that is applied to the log
36              file's permissions. The default is root. The group name  can  be
37              either numeric or spelled out.
38
39       priority_boost
40              This  is  a  non-negative number that tells the audit daemon how
41              much of a priority boost it should take. The default  is  4.  No
42              change is 0.
43
44       flush  Valid  values are none, incremental, data,  and sync.  If set to
45              none, no special effort is made to flush the  audit  records  to
46              disk.  If set to incremental, Then the freq parameter is used to
47              determine how often an explicit flush to disk  is  issued.   The
48              data parameter tells the audit damon to keep the data portion of
49              the disk file sync'd at all times. The  sync  option  tells  the
50              audit  daemon  to  keep both the data and meta-data fully sync'd
51              with every write to disk.
52
53       freq   This is a non-negative number that tells  the  audit  damon  how
54              many  records  to write before issuing an explicit flush to disk
55              command. this value is only valid when the flush keyword is  set
56              to incremental.
57
58       num_logs
59              This keyword specifies the number of log files to keep if rotate
60              is given as the max_log_file_action.  If the number is < 2, logs
61              are not rotated. This number must be 99 or less.  The default is
62              0 - which means no rotation. As you increase the number  of  log
63              files  being  rotated, you may need to adjust the kernel backlog
64              setting upwards since it takes more time to  rotate  the  files.
65              This  is  typically done in /etc/audit/audit.rules. If log rota‐
66              tion is configured to occur, the daemon will  check  for  excess
67              logs and remove them in effort to keep disk space available. The
68              excess log check is only done on startup and when a  reconfigure
69              results in a space check.
70
71       disp_qos
72              This  option controls whether you want blocking/lossless or non-
73              blocking/lossy communication between the audit  daemon  and  the
74              dispatcher.  There is a 128k buffer between the audit daemon and
75              dispatcher. This is good enogh for most uses. If lossy  is  cho‐
76              sen,  incoming events going to the dispatcher are discarded when
77              this queue is  full.  (Events  are  still  written  to  disk  if
78              log_format  is not nolog.) Otherwise the auditd daemon will wait
79              for the queue to have an empty spot before logging to disk.  The
80              risk  is  that  while  the  daemon is waiting for network IO, an
81              event is not being recorded to disk. Valid values are: lossy and
82              lossless. Lossy is the default value.
83
84       dispatcher
85              The  dispatcher is a program that is started by the audit daemon
86              when it starts up. It will pass a copy of all  audit  events  to
87              that  application's  stdin.  Make sure you trust the application
88              that you add to this line since it runs with root privileges.
89
90       name_format
91              This option controls how computer node names are  inserted  into
92              the  audit  event  stream.  It  has the following choices: none,
93              hostname, fqd, numeric, and user.  None means that  no  computer
94              name  is  inserted  into  the audit event.  hostname is the name
95              returned by the gethostname syscall. The fqd means that it takes
96              the  hostname  and  resolves  it  with dns for a fully qualified
97              domain name of that machine.  Numeric is similar to  fqd  except
98              it  resolves the IP address of the machine. In order to use this
99              option, you might want to test that 'hostname -i' or 'domainname
100              -i'  returns  a numeric address. Also, this option is not recom‐
101              mended  if  dhcp  is  used  because  you  could  have  different
102              addresses  over  time  for  the  same machine.  User is an admin
103              defined string from the name option. The default value is none.
104
105       name   This is the admin defined string that identifies the machine  if
106              user is given as the name_format option.
107
108       max_log_file
109              This  keyword specifies the maximum file size in megabytes. When
110              this limit is reached, it will trigger  a  configurable  action.
111              The value given must be numeric.
112
113       max_log_file_action
114              This  parameter  tells  the  system what action to take when the
115              system has detected that  the  max  file  size  limit  has  been
116              reached.  Valid  values  are ignore, syslog, suspend, rotate and
117              keep_logs.  If set to ignore, the  audit  daemon  does  nothing.
118              syslog  means  that  it will issue a warning to syslog.  suspend
119              will cause the audit daemon to stop writing records to the disk.
120              The daemon will still be alive. The rotate option will cause the
121              audit daemon to rotate the logs. It should be  noted  that  logs
122              with higher numbers are older than logs with lower numbers. This
123              is the same  convention  used  by  the  logrotate  utility.  The
124              keep_logs option is similar to rotate except it does not use the
125              num_logs setting. This prevents audit logs from being  overwrit‐
126              ten.
127
128       action_mail_acct
129              This  option  should contain a valid email address or alias. The
130              default address is root. If the email address is  not  local  to
131              the  machine, you must make sure you have email properly config‐
132              ured on your machine and network.  Also,  this  option  requires
133              that /usr/lib/sendmail exists on the machine.
134
135       space_left
136              This is a numeric value in megabytes that tells the audit daemon
137              when to perform a configurable  action  because  the  system  is
138              starting to run low on disk space.
139
140       space_left_action
141              This  parameter  tells  the  system what action to take when the
142              system has detected that it is  starting  to  get  low  on  disk
143              space.   Valid  values are ignore, syslog, email, exec, suspend,
144              single, and halt.  If set to ignore, the audit daemon does noth‐
145              ing.   syslog  means  that  it  will  issue a warning to syslog.
146              Email means that it will send a warning  to  the  email  account
147              specified  in action_mail_acct as well as sending the message to
148              syslog.  exec /path-to-script will execute the script. You  can‐
149              not pass parameters to the script.  suspend will cause the audit
150              daemon to stop writing records to  the  disk.  The  daemon  will
151              still be alive. The single option will cause the audit daemon to
152              put the computer system in single user mode.  halt  option  will
153              cause the audit daemon to shutdown the computer system.
154
155       admin_space_left
156              This is a numeric value in megabytes that tells the audit daemon
157              when to perform a configurable action because the system is run‐
158              ning  low  on  disk  space.  This  should be considered the last
159              chance to do something before running out  of  disk  space.  The
160              numeric value for this parameter should be lower than the number
161              for space_left.
162
163       admin_space_left_action
164              This parameter tells the system what action  to  take  when  the
165              system  has detected that it is low on disk space.  Valid values
166              are ignore, syslog, email, exec, suspend, single, and halt.   If
167              set to ignore, the audit daemon does nothing.  Syslog means that
168              it will issue a warning to syslog.  Email  means  that  it  will
169              send   a   warning   to   the   email   account   specified   in
170              action_mail_acct as well as sending the message to syslog.  exec
171              /path-to-script will execute the script. You cannot pass parame‐
172              ters to the script.  Suspend will cause the audit daemon to stop
173              writing records to the disk. The daemon will still be alive. The
174              single option will cause the audit daemon to  put  the  computer
175              system in single user mode.  halt
176
177       disk_full_action
178              This  parameter  tells  the  system what action to take when the
179              system has detected that the partition to which  log  files  are
180              written  has become full. Valid values are ignore, syslog, exec,
181              suspend, single, and halt.  If set to ignore, the  audit  daemon
182              will  issue a syslog message but no other action is taken.  Sys‐
183              log means that it will issue a warning to syslog.   exec  /path-
184              to-script will execute the script. You cannot pass parameters to
185              the script.  Suspend will cause the audit daemon to stop writing
186              records  to the disk. The daemon will still be alive. The single
187              option will cause the audit daemon to put the computer system in
188              single  user  mode.   halt option will cause the audit daemon to
189              shutdown the computer system.
190
191       disk_error_action
192              This parameter tells the system what  action  to  take  whenever
193              there  is an error detected when writing audit events to disk or
194              rotating logs. Valid values are ignore, syslog,  exec,  suspend,
195              single, and halt.  If set to ignore, the audit daemon will issue
196              a syslog message but no other action  is  taken.   Syslog  means
197              that  it  will  issue a warning to syslog.  exec /path-to-script
198              will execute the script.  You  cannot  pass  parameters  to  the
199              script.   Suspend  will  cause  the audit daemon to stop writing
200              records to the disk. The daemon will still be alive. The  single
201              option will cause the audit daemon to put the computer system in
202              single user mode.  halt option will cause the  audit  daemon  to
203              shutdown the computer system.
204
205       tcp_listen_port
206              This  is  a numeric value in the range 1..65535 which, if speci‐
207              fied, causes auditd to listen on the corresponding TCP port  for
208              audit  records  from  remote  systems.  The  audit daemon may be
209              linked with tcp_wrappers. You may want to control access with an
210              entry in the hosts.allow and deny files.
211
212       tcp_listen_queue
213              This  is  a  numeric  value  which  indicates  how  many pending
214              (requested but unaccepted) connections are allowed.  The default
215              is  5.   Setting  this  too  small  may  cause connections to be
216              rejected if too many hosts start up at exactly  the  same  time,
217              such as after a power failure.
218
219       tcp_max_per_addr
220              This is a numeric value which indicates how many concurrent con‐
221              nections from one IP address is allowed.  The default is  1  and
222              the maximum is 16. Setting this too large may allow for a Denial
223              of Service attack on the logging server. The default  should  be
224              adequate  in  most cases unless a custom written recovery script
225              runs to forward unsent events. In this case you  would  increase
226              the number only large enough to let it in too.
227
228       use_libwrap
229              This  setting  determines  whether or not to use tcp_wrappers to
230              discern connection attempts  that  are  from  allowed  machines.
231              Legal values are either yes, or no The default value is yes.
232
233       tcp_client_ports
234              This parameter may be a single numeric value or two values sepa‐
235              rated by a dash (no spaces allowed).  It indicates which  client
236              ports  are  allowed for incoming connections.  If not specified,
237              any port is allowed.  Allowed values are 1..65535.  For example,
238              to require the client use a priviledged port, specify 1-1023 for
239              this parameter. You will also need to set the local_port  option
240              in  the  audisp-remote.conf  file. Making sure that clients send
241              from a privileged port is a  security  feature  to  prevent  log
242              injection attacks by untrusted users.
243
244       tcp_client_max_idle
245              This parameter indicates the number of seconds that a client may
246              be idle (i.e. no data from them at all) before auditd complains.
247              This is used to close inactive connections if the client machine
248              has a problem where it cannot shutdown the  connection  cleanly.
249              Note  that this is a global setting, and must be higher than any
250              individual client heartbeat_timeout  setting,  preferably  by  a
251              factor of two.  The default is zero, which disables this check.
252
253       enable_krb5
254              If  set to "yes", Kerberos 5 will be used for authentication and
255              encryption.  The default is "no".
256
257       krb5_principal
258              This is the principal for this server.  The default is "auditd".
259              Given  this  default,  the server will look for a key named like
260              auditd/hostname@EXAMPLE.COM stored  in  /etc/audit/audit.key  to
261              authenticate  itself,  where  hostname is the canonical name for
262              the server's host, as  returned  by  a  DNS  lookup  of  its  IP
263              address.
264
265       krb5_key_file
266              Location  of the key for this client's principal.  Note that the
267              key file must be owned by root and mode 0400.   The  default  is
268              /etc/audit/audit.key
269
270

NOTES

272       In  a CAPP environment, the audit trail is considered so important that
273       access to system resources must be denied if an audit trail  cannot  be
274       created. In this environment, it would be suggested that /var/log/audit
275       be on its own partition. This is to  ensure  that  space  detection  is
276       accurate and that no other process comes along and consumes part of it.
277
278       The flush parameter should be set to sync or data.
279
280       Max_log_file  and num_logs need to be adjusted so that you get complete
281       use of your partition. It should be noted that the more files that have
282       to  be  rotated,  the  longer  it  takes to get back to receiving audit
283       events. Max_log_file_action should be set to keep_logs.
284
285       Space_left should be set to a number that gives the admin  enough  time
286       to  react  to any alert message and perform some maintenance to free up
287       disk space. This would typically involve running the aureport -t report
288       and  moving the oldest logs to an archive area. The value of space_left
289       is site dependant since the rate at which events are  generated  varies
290       with each deployment. The space_left_action is recommended to be set to
291       email. If you need something like an snmp trap, you can  use  the  exec
292       option to send one.
293
294       Admin_space_left should be set to the amount of disk space on the audit
295       partition    needed    for    admin    actions    to    be    recorded.
296       Admin_space_left_action  would  be  set  to  single  so that use of the
297       machine is restricted to just the console.
298
299       The disk_full_action is triggered when no more room exists on the  par‐
300       tition.  All access should be terminated since no more audit capability
301       exists. This can be set to either single or halt.
302
303       The disk_error_action should be set to syslog, single, or halt  depend‐
304       ing on your local policies regarding handling of hardware malfunctions.
305
306       Specifying  a  single allowed client port may make it difficult for the
307       client to restart their audit subsystem, as it will be unable to recre‐
308       ate  a connection with the same host addresses and ports until the con‐
309       nection closure TIME_WAIT state times out.
310
311

FILES

313       /etc/audit/auditd.conf
314              Audit daemon configuration file
315
316

SEE ALSO

318       auditd(8), audisp-remote.conf(5).
319
320

AUTHOR

322       Steve Grubb
323
324
325
326Red Hat                            Dec 2008                    AUDITD.CONF:(5)
Impressum