On 15-Sep-2014 12:53 -0500, Jack wrote:
>
> I have a user with LMTCPB(*YES) who is able to perform an ENDJOB on
> any sessions on our AS/400 (V7R1). I set his user profile to be
> audited with the following command: CHGUSRAUD USRPRF(MYUSER)
> OBJAUD(*ALL) AUDLVL(*CMD).
>
> I can now track his actions with the DSPAUDJRNE command. There is
> one weird thing I see when he performs the ENDJOB command. Below is
> what I see from the command DSPAUDJRNE ENTTYP(CD) USRPRF(MYUSER)
> FROMTIME(091514 111111) OUTPUT(*). To make it easier to read, each
> line is the equivalent of a column on the screen.
>
> ENTRY TYPE: C
> USER PROFILE: MYUSER
> OBJECT NAME: ENDJOB
> LIBRARY NAME: *SYSTEM
> CL PGM: N
> JOB NAME: MYJOB
> JOB USER: MYUSER
> JOB NUMBER: 008787
> TIME STAMP: 2014-09-15-11.11.11.111111
> COMMAND STRING: X: *SYSTEM/ENDJOB JOB(008787/RYLACROIX/LINE04)
>
> As I understand it, the command is issued from the command line for
> the job number 008787. All other commands (not shown here) are under
> the job number 008787, excluding the fact that this could have been
> issued via RMTCMD or ODBC.
>
> I do not understand as well the *SYSTEM library name.
>
> And, most of all, I don't understand the "X:" in the command string.
> How did it get there?
The "*SYSTEM" library qualification is an alias for the system
library which [in the /native/ environment] is the library QSYS. The
typical unqualified reference uses the library qualification of "*LIBL".
Yet another library qualification available is "*NLVLIBL" to search
the QSYS29## library\libraries before the library QSYS.
Features shipped by IBM, e.g. MENU options, are [mostly] explicitly
qualified with either *NLVLIBL or *SYSTEM to prevent being affected by
Trojan Horse variants of a command of the same name found in *LIBL; i.e.
whereby an equivalent command name might exist in a library that was
placed in a position prior to QSYS using either Change System Library
List (CHGSYSLIBL) or the System Library List (SYSLIBL) entry of the
subsystem. These specifications are intended to avoid negative effects
of even legitimate\intended Trojans that might have unintended effects
for work initiated by the system or a request by a user for an intended
effect advertised by the system; in this case, the End Job (ENDJOB) was
requested via a option from a list\menu.
As to the X:, I do not know for sure [because I do not recall ever
seeing any such prefix ever appear in the output], but I believe that
the "X:" indicates that the command utilized was actually a Proxy
Command (PRX); seems odd though, given the *SYSTEM qualification.? I
would expect the QSYS/ENDJOB to be a *CMD object without the Proxy
attribute.
I suppose the typical\standard /native/ environment command
invocations may appear with no designation [no prefix in the command
string data], but if they are similarly prefixed, the typical value
would be a C: instead, meaning "Command Run [without substitution by an
API invocation]". Refer to the following IBM i 7.2 [v7r2] documentation
which has a Change Bar for the T-CD (Command String) audit entry [as the
"Entry Type" entry-specific information]:
<
http://www.ibm.com/support/knowledgecenter/ssw_ibm_i_72/rzarl/rzarlf10.htm>
--
Regards, Chuck