Sure there is such a scenario, Dan.

*
I have *PGMR authority and I know your library list.
*
I put a new ABCMONRG *PGM in a library higher in the list than the library where you keep your copy.

This was one of the first exploits in Unix ... put something naughty in a user's $PATH ahead of where they expect to find something of the same name.
One of the reasons no sophisticated Unix user has '.' in their $PATH.




________________________________
From: MIDRANGE-L <midrange-l-bounces@xxxxxxxxxxxxxxxxxx> on behalf of Dan Bale <dan.bale@xxxxxxxxxxxxxxxxxxxxx>
Sent: Tuesday, February 4, 2025 21:27
To: Midrange Systems Technical Discussion <midrange-l@xxxxxxxxxxxxxxxxxx>
Subject: Sanity check: RTVOBJD *LIBL/ABCMONRG RTNLIB(&LIBNAM), then CALL &LIBNAM/ABCMONRG???

Code snippet of a production CLP program I am currently modifying:

DCL VAR(&LIBNAM) TYPE(*CHAR) LEN(10)
RTVOBJD OBJ(ABCMONRG) OBJTYPE(*PGM) RTNLIB(&LIBNAM)
CALL PGM(&LIBNAM/ABCMONRG)

Is there *any* scenario where "CALL ABCMONRG" without the first two statements doesn't always call the program from the same library?

&LIBNAM is not used anywhere else in the program.
There are no intervening statements between the RTVOBJD and CALL commands.



Jack Woehr
Independent Consulting Programmer

303-847-8442

jack.woehr@xxxxxxxxxxx

www.procern.com

Stay Connected!

Not Just MSP, We Also MSSP.

 NON-DISCLOSURE NOTICE: This communication including any and all attachments is for the intended recipient(s) only and may contain confidential and privileged information. If you are not the intended recipient of this communication, any disclosure, copying further distribution or use of this communication is prohibited. If you received this communication in error, please contact the sender and delete/destroy all copies of this communication immediately.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.