Hi,
I am trying to extract fields from security audit events. The problem comes when dealing with entry specific data field. This field contains lot of info which varies according to the entry type. Is there any API which returns information present in the entry specific data portion in a convenient format? Any suggestions or pointers would be very helpful.
Regards,
P.Prasad
Software/Hardware used:
ASKED:
August 4, 2005 11:15 AM
UPDATED:
October 31, 2010 11:12 AM
I want to do this from within the exit program which is registered using the RCVJRNE command. I get the entries currently in RJNE0200 format and have no problem with the fixed part of the entry. Only problem is with the variable length field particularly “entry specific data”. Currently I can get to the Entry specific data portion of the entry, decode the data according to the entry type but this becomes very cumbersome. There are around 80 entry types within journal code T and each entry type has a different layout for the entry specific data. I am looking out for some API which when given a pointer to the Entry specific data and also the journal entry type would itself decode the data present in the entry specific data, return the fields as say name/value pairs. I know this is a bit too much to ask but to code the layout for around 80 entry types would be too time-consuming and boring, so looking out for the remote possibility of such an API existing. If it’s not there, then the only way is take the layouts for each entry type’s entry specific data, create a corresponding structure(in C) for all the 80 entry types, and cast the pointer to the appropriate structure type.
P.Prasad
The formats are generally available as “model files” supplied by IBM with every AS/400. Enter this command to see examples on your system:
==> wrkf QASY*
Help text for DSPJRN parameters OUTPUT(), OUTFILFMT() and OUTFILE() provides some introduction though not specifically for individual entry types in the audit journal.
All of the entery types, file names and format names are documented in the Security Reference manual.
Note that file formats for the audit journal can, and often do, change from one OS/400 release to the next.
Tom
There is also the CPYAUDJRNE. This command creates seperate output files depending on the Journal code.
There is also the CPYAUDJRNE.
Neither CPYAUDJRNE nor DSPAUDJRNE help with the problem. They cannot be used with RCVJRNE nor with the RTVJRNE command or the Retrieve Journal Entries (QjoRetrieveJournalEntries) API.
Journal entries would be received with RCVJRNE to provide near real-time processing of journal entries. The formats must be decoded by the receiving program. The model files may be used as a basis for declaring data structures and saving some time in defining each field. But output to files is always historical rather than as events are logged.
Tom