4.8 Audit File Configuration Header

This topic discusses the audit file configuration header and how it controls the auditing on the associated volume or container.

4.8.1 Audit File Configuration Header Introduction

The audit file configuration header controls the auditing on the associated volume or container. Although configuration headers differ somewhat between volumes and containers, both contain the following key fields:

  • A set of audit flags that indicate the status of auditing for the object.
  • An event bitmap that determines which events are audited.
  • A count of the current number of events that have been recorded in the audit file.

Additional fields contain information about the state of the audit file. The NWConfigHeader structure contains the volume configuration header data.

The configuration header for NetWare® 4.11 is twice the size of that for previous versions of NetWare. This allows for more events to be audited.

Use the following functions to read from or write to the configuration headers:

In the case of volumes, you can also read or write just the event bitmap in the header. For more information see Audit File Configuration Header Event Bitmap.

Read or write operations affect the entire configuration header. When modifying a header, be sure to assign values to all the header’s data items.

4.8.2 Auditing Flags

Auditing flags can be read separately from other data in the audit file configuration header. The flags control several important aspects of the auditing process and are stored as a set of bit flags in a single-byte value. There are five flags:

  • If DiscardAuditRcdsOnErrorFlag is set, the auditing records are discarded if an error occurs.
  • If ConcurrentVolAuditorAccess is set more than one auditor can log into the object at a time.
  • If DualLevelPasswordsActive is set, dual level password security is in effect.
  • If BroadcastWarningsToAllUsers is set, audit warnings are broadcast to all users.
  • If LevelTwoPasswordSet is set, the level 2 password has been assigned a value. (This last flag is meaningful only if the dual level passwords flag is set.) Bits 0 through 3 can be set by the auditor.

NWADGetFlags returns the auditing flags for an object.

4.8.3 Audit File Configuration Header Event Bitmap

The event bitmap in the configuration header is the key to configuring the audit file. Each bit in the event bitmap represents an event to be audited. In its initial state, none of the bits in the event bitmap is set. It’s up to the auditor to access the audit file’s configuration header and set the bits that correspond to events the auditor wants audited.

The event bitmap for containers is a 32-bit value with 32 corresponding events. The event bitmap for volumes is 512 bits (64 bytes).

Events that can be audited fall into several categories:

  • NDS Events
  • Bindery Events
  • NetWare® Server Events
  • Queue Management Events
  • File System Events
  • User Object Events

You must use container auditing to audit NDS events. All other events must be audited on a volume basis. For each category there are many events you can audit. Setting the bit for an event results in an event record being added to the audit file every time that event occurs.

For related information, see:

Scope of Auditing Events

The event bitmap doesn’t single out specific users to be audited unless you are using NetWare® 4.11 and user restrictions is turned on using the Auditcon utility.

For previous versions of NetWare 4, once an event is set, every occurrence of the event is audited regardless of who performs it. For example, if you set the Delete Bindery Property Event bit, then an event record is generated every time a user deletes a property from an object. File events are an exception. You can configure file auditing to target specific files and users. For more information see Auditing File Events (NetWare 4.x and above).

If you are interested only in events involving specific items, you can filter the information you read from the audit file by searching specific fields in the event records. For example, you could search for all event records in which a particular user deleted properties from a particular object.

Auditing File Events (NetWare 4.x and above)

For NetWare 4 versions prior to 4.11, file events are the only category of events for which you can target specific files and users. To audit file events you must configure the files and the user objects in addition to setting the file event bit in the volume’s event bitmap. To target specific files you must set each file’s audit attribute. To target specific users you must add an audit property to each user’s bindery object. Both procedures are explained below.

User Audit Property

To audit a particular user’s file operations, you must assign an audit property to the user’s object by calling NWADChangeObjectProperty. The property doesn’t take a value. If the property is present, the specified user will be audited. You must specify the volume or container on which the user is being audited.

For related information, see File Events for Auditing.

Reading a Volume Event Bitmap

The volume event bitmap is a bit stream 512 bits long. Special functions are defined to simplify access to this bitmap.

File Events for Auditing

Once you set the audit attribute for specific files or add the audit property to specific users, the next step is to set the event bitmap for file operations you want to audit. Some file events are represented by three different bits in the event bitmap: a global bit, a union bit, and an intersection bit. (See the File Events.) Set the one appropriate for the events you are auditing.

Open File audit is an example of the choices presented by the three bits:

  • The Global Open File bit generates an event record every time a file is opened (regardless of which file is involved or who opens it).
  • The Union Open File bit generates an event record whenever an audited file is opened or an audited user opens a file.
  • The Intersection Open File bit generates an event record only when an audited user opens an audited file; other open file operations are ignored.

For related information, see User Audit Property.

Event Bitmap

The volume event bitmap is a bit stream 512 bits long. Special functions are defined to simplify access to this bitmap:

Message Events Table

The following table lists the bits defined in the message event bitmap.

A_EVENT_BROADCAST_TO_CONSOLE

207

A_EVENT_DISABLE_BROADCASTS

204

A_EVENT_ENABLE_BROADCASTS

206

A_EVENT_GET_BROADCAST_MESSAGE

205

A_EVENT_SEND_BROADCAST_MESSAGE

208

Accounting Events Table

The following table lists the bits defined in the accounting events bitmap.

Event Type ID

Event ID

A_EVENT_GET_CURRET_ACNT_STATS

200

A_EVENT_SUBMIT_ACCOUNT_CHARGE

201

A_EVENT_SUBMIT_ACCOUNT_HOLD

202

A_EVENT_SUBMIT_ACCOUNT_NOTE

203

File Events

The following table lists the bits defined in the File event bitmap.

Event Type ID

Event ID

A_EVENT_CREATE_DIRECTORY

75

A_EVENT_DELETE_DIRECTORY

76

A_EVENT_CLOSE_FILE

10

A_EVENT_CREATE_FILE

12

A_EVENT_DELETE_FILE

14

A_EVENT_OPEN_FILE

27

A_EVENT_PURGE_FILE

214

A_EVENT_READ_FILE

42

A_EVENT_RENAME_MOVE_FILE

44

A_EVENT_SALVAGE_FILE

46

A_EVENT_WRITE_FILE

57

A_EVENT_MODIFY_ENTRY

25

A_EVENT_SCAN_DELETED

215

A_EVENT_SCAN_VOL_USER_REST

238

A_EVENT_SET_COMP_FILE_SIZE

242

QMS Events Table

The following table lists the bits defined in the QMS event bitmap.

Event Type ID

Event ID

A_EVENT_Q_JOB_FROM_LIST

231

A_EVENT_Q_JOB_LIST

230

A_EVENT_Q_JOB_SIZE

229

A_EVENT_MOVE_Q_JOB

233

A_EVENT_Q_ATTACH_SERVER

28

A_EVENT_Q_CREATE

29

A_EVENT_Q_CREATE_JOB

30

A_EVENT_Q_DESTROY

31

A_EVENT_Q_DETACH_SERVER

32

A_EVENT_Q_EDIT_JOB

33

A_EVENT_Q_JOB_FINISH

34

A_EVENT_Q_JOB_SERVICE

35

A_EVENT_Q_JOB_SERVICE_ABORT

36

A_EVENT_Q_SWAP_RIGHTS

41

A_EVENT_Q_REMOVE_JOB

37

A_EVENT_Q_SET_JOB_PRIORITY

38

A_EVENT_Q_SET_STATUS

39

A_EVENT_Q_START_JOB

40

A_EVENT_READ_Q_JOB_ENTRY

232

A_EVENT_MOVE_Q_JOB

233

A_EVENT_READ_Q_STATUS

234

A_EVENT_READ_Q_SERVER_STATUS

235

A_EVENT_SET_Q_SERVER_STATUS

261

Server Events Table

The following table lists the bits defined in the server event bitmap.

Event Type ID

Event ID

A_EVENT_CHANGE_DATE_TIME

7

A_EVENT_CONVERT_PATH_TO_ENTRY

259

A_EVENT_DISABLE_LOGIN

243

A_EVENT_DISABLE_ TTS

245

A_EVENT_DOWN_SERVER

18

A_EVENT_ENABLE_LOGIN

244

A_EVENT_ENABLE_TTS

246

A_EVENT_GET_CONN_OPEN_FILES

250

A_EVENT_GET_CONN_SEMS

256

A_EVENT_GET_CONN_TASKS

249

A_EVENT_GET_CONN_USING_FILE

251

A_EVENT_GET_LOG_REC_INFO

255

A_EVENT_GET_LOG_REC_CONN

254

A_EVENT_GET_REMAIN_OBJ_DISK_SPC

248

A_EVENT_GET_PHYS_REC_LOCKS_CONN

252

A_EVENT_GET_PHYS_REC_LOCKS_FILE

253

A_EVENT_GET_SEM_INFO

257

A_EVENT_GET_DISK_UTILIZATION

240

A_EVENT_MAP_DIR_TO_PATH

258

A_EVENT_VOLUME_DISMOUNT

56

A_EVENT_VOLUME_MOUNT

55

A_EVENT_SEND_CONSOLE_BROADCAST

247

A_EVENT_CONSOLE_COMMAND

262

A_EVENT_DESTROY_SERVICE_CONN

260

A_EVENT_VERIFY_SERIAL

239

A_EVENT_VOLUME_DISMOUNT

56

A_EVENT_VOLUME_MOUNT

55

User Events Table

The following table lists the bits defined in the user event bitmap.

Event Type ID

Event ID

A_EVENT_DISABLE_ACCOUNT

17

A_EVENT_GRANT_TRUSTEE

19

A_EVENT_LOGIN_USER

21

A_EVENT_LOGOUT_USER

23

A_EVENT_REMOVE_TRUSTEE

43

A_EVENT_USER_SPACE_RESTRICTIONS

53

A_EVENT_USER_LOCKED

52

A_EVENT_USER_CHANGE_PASSWORD

51

A_EVENT_USER_UNLOCKED

54

A_EVENT_RENAME_USER

45

NDS Events Table

The following table lists the bits defined in the NDS event bitmap.

Event Type ID

Event ID

ADS_ADD_ENTRY

101

ADS_REMOVE_ENTRY

102

ADS_RENAME_OBJECT

103

ADS_MOVE_ENTRY

104

ADS_CHANGE_SECURITY_EQUIV

105

ADS_CHG_SECURITY_ALSO_EQUAL

106

ADS_CHANGE_ACL

107

ADS_CHG_STATION_RESTRICTION

108

ADS_LOGIN

109

ADS_LOGOUT

110

ADS_CHANGE_PASSWORD

111

ADS_USER_LOCKED

112

ADS_USER_UNLOCKED

113

ADS_USER_DISABLE

114

ADS_USER_ENABLE

115

ADS_CHANGE_INTRUDER_DETECT

116

ADS_ADD_PARTITION

117

ADS_REMOVE_PARTITION

118

ADS_ADD_REPLICA

119

ADS_REMOVE_REPLICA

120

ADS_SPLIT_PARTITION

121

ADS_JOIN_PARTITION

122

ADS_CHANGE_REPLICA_TYPE

123

ADS_REPAIR_TIME_STAMPS

124

ADS_MOVE_SUB_TREE

125

ADS_ABORT_PARTITION_OP

126

ADS_SEND_REPLICA_UPDATES

127

ADS_RECEIVE_REPLICA_UPDATES

128

Additional NDS Events (for NetWare 4.11 and above)

NDS has added many more events to support auditing and other functions. For information about these events, see NDS Event Services.

For related information, see Event Bits Tables.