Page 1 of 1

How to know LINKLIST order?

Posted: Mon Jul 09, 2018 12:20 pm
by Priya
Hi,

When we execute a program, how do we know where it was invoked from? I did research around it and got to know that there is a concept of LINKLIST. How to know LINKLIST order when a program is executed? Can some one please help.

Re: How to know LINKLIST order?

Posted: Mon Jul 09, 2018 5:00 pm
by Robert Sample
When a batch program is executed and there is no JOBLIB / STEPLIB to locate the data set, the LINKLIST is searched. The LINKLIST is searched in order, from first data set to the last, and the first occurrence of the program in a LINKLIST load library will stop the search and that program will be loaded and executed. The LINKLIST order is established by parameters in SYS1.PARMLIB (different members for static and dynamic link lists). If you use ISRDDN LINKLIST under TSO (ISPF command line TSO ISRDDN LINKLIST), you can see the order of the LINKLIST. If you are wanting to know where a program is loading from, you may also have to research the LPA (link pack area) as well as the LINKLIST.

Re: How to know LINKLIST order?

Posted: Wed Jul 18, 2018 6:03 am
by Priya
The LINKLIST order is established by parameters in SYS1.PARMLIB (different members for static and dynamic link lists).
When I tried to locate that dataset, I got the message that, "No data set names found"! Why would that happen?

Re: How to know LINKLIST order?

Posted: Wed Jul 18, 2018 6:10 am
by Priya
Robert Sample wrote: Mon Jul 09, 2018 5:00 pm If you use ISRDDN LINKLIST under TSO (ISPF command line TSO ISRDDN LINKLIST), you can see the order of the LINKLIST.
This command worked but when I treid to search the member, it showed me this:

Code: Select all

 	Œ¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹œ 
 	4 	                  *** WARNING ***                    	4 
 	4 	                  *** WARNING ***                    	4 
 	4 	                                                     	4 
 	4 	   This function may search Linklist, LPA, Parmlib   	4 
 	4 	   or APF libraries.  At some sites this may lead    	4 
 	4 	   to security violations. To allow scanning of      	4 
 	4 	   these libraries enter YES below:                  	4 
 	4 	   PF3 to exit from this panel.                      	4 
 	4 	                                                     	4 
 	4 	   Type 	YES 	to proceed . . . 	NO   	                   	4 
 	4 	     (Enter 	SKIP 	to proceed and to skip              	4 
 	4 	      this panel in the future.)                     	4 
 	4 	                                                     	4 
 	4 	                                                     	4 
 	4 	                                                     	4 
 	4 	                                                     	4 
 	4 	                                                     	4 
 	‹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹¹› 
I said no and came out but why just searching a library can be security issue?

Re: How to know LINKLIST order?

Posted: Wed Jul 18, 2018 7:09 am
by Robert Sample
How did you attempt to locate SYS1.PARMLIB? Depending upon the method you used, you may need to put single quote marks (tic marks) around the data set name to prevent TSO from prefixing your user id to the name. It is also possible that your site has renamed SYS1.PARMLIB to something else. As long as SYSx.IPLPARM has the data set name, it does not have to be SYS1.PARMLIB. And while SYSx.IPLPARM is often cataloged, it is not required to be since it is accessed extremely early in the IPL process (before the catalog is available).

Searching a library can be a security violation depending upon how the site's security is set up (sites have such variation that few, if any, general statements apply everywhere). Such sites do not want any random person looking at how their system is set up. Looking at SYS1.PARMLIB, for example, can tell someone the authorized (secured) programs and the libraries those programs are in -- and LINKLIST has a number of authorized libraries included. A malicious person could attempt to replace an authorized program with their own version (which is why searching for the name is important), potentially elevating a malicious program to allow it to do things it normally could not do.

Re: How to know LINKLIST order?

Posted: Wed Jul 18, 2018 9:36 am
by Priya
Hi Robert,

I tried it locating using ISPF and 3.4 option. but it showed me like in the screen shot:
SYS1.PARMLIB.jpg
With SYS*.PARMLIB also I got the same error.

Re: How to know LINKLIST order?

Posted: Wed Jul 18, 2018 9:57 am
by Priya
Robert Sample wrote: Wed Jul 18, 2018 7:09 amSearching a library can be a security violation depending upon how the site's security is set up
By "searching" and finding where the member is, what can we do? I mean If they don't give the authority to view/edit it's ok but browsing should not be banned.

Re: How to know LINKLIST order?

Posted: Wed Jul 18, 2018 4:27 pm
by nicc
By browsing you can still cut and paste data which can thn be transported elsewhere by someone wanting to steal information.

Re: How to know LINKLIST order?

Posted: Wed Jul 18, 2018 9:37 pm
by Robert Sample
You could try putting **.PARMLIB in the ISPF 3.4 panel, but that searches all catalogs on the system, which can require a considerable amount of time. You could also try SYS*.**.PARMLIB, which will find it if the data set has one or more intermediate levels in the DSNAME. SYS*.PARMLIB would not find SYS1.CPAC.PARMLIB, for example -- nor any other data set where there is an additional level between the SYS? and PARMLIB.